/// <summary>Snippet for SetUrlMap</summary>
        public void SetUrlMap()
        {
            // Snippet: SetUrlMap(string, string, UrlMapReference, CallSettings)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
            // Initialize request argument(s)
            string          project                 = "";
            string          targetHttpProxy         = "";
            UrlMapReference urlMapReferenceResource = new UrlMapReference();
            // Make the request
            lro::Operation <Operation, Operation> response = targetHttpProxiesClient.SetUrlMap(project, targetHttpProxy, urlMapReferenceResource);

            // Poll until the returned long-running operation is complete
            lro::Operation <Operation, Operation> completedResponse = response.PollUntilCompleted();
            // Retrieve the operation result
            Operation result = completedResponse.Result;

            // Or get the name of the operation
            string operationName = response.Name;
            // This name can be stored, then the long-running operation retrieved later by name
            lro::Operation <Operation, Operation> retrievedResponse = targetHttpProxiesClient.PollOnceSetUrlMap(operationName);

            // Check if the retrieved long-running operation has completed
            if (retrievedResponse.IsCompleted)
            {
                // If it has completed, then access the result
                Operation retrievedResult = retrievedResponse.Result;
            }
            // End snippet
        }
        /// <summary>Snippet for PatchAsync</summary>
        public async Task PatchAsync()
        {
            // Snippet: PatchAsync(string, string, TargetHttpProxy, CallSettings)
            // Additional: PatchAsync(string, string, TargetHttpProxy, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            string          project                 = "";
            string          targetHttpProxy         = "";
            TargetHttpProxy targetHttpProxyResource = new TargetHttpProxy();
            // Make the request
            lro::Operation <Operation, Operation> response = await targetHttpProxiesClient.PatchAsync(project, targetHttpProxy, targetHttpProxyResource);

            // Poll until the returned long-running operation is complete
            lro::Operation <Operation, Operation> completedResponse = await response.PollUntilCompletedAsync();

            // Retrieve the operation result
            Operation result = completedResponse.Result;

            // Or get the name of the operation
            string operationName = response.Name;
            // This name can be stored, then the long-running operation retrieved later by name
            lro::Operation <Operation, Operation> retrievedResponse = await targetHttpProxiesClient.PollOncePatchAsync(operationName);

            // Check if the retrieved long-running operation has completed
            if (retrievedResponse.IsCompleted)
            {
                // If it has completed, then access the result
                Operation retrievedResult = retrievedResponse.Result;
            }
            // End snippet
        }
        /// <summary>Snippet for Patch</summary>
        public void PatchRequestObject()
        {
            // Snippet: Patch(PatchTargetHttpProxyRequest, CallSettings)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
            // Initialize request argument(s)
            PatchTargetHttpProxyRequest request = new PatchTargetHttpProxyRequest
            {
                TargetHttpProxyResource = new TargetHttpProxy(),
                RequestId       = "",
                TargetHttpProxy = "",
                Project         = "",
            };
            // Make the request
            lro::Operation <Operation, Operation> response = targetHttpProxiesClient.Patch(request);

            // Poll until the returned long-running operation is complete
            lro::Operation <Operation, Operation> completedResponse = response.PollUntilCompleted();
            // Retrieve the operation result
            Operation result = completedResponse.Result;

            // Or get the name of the operation
            string operationName = response.Name;
            // This name can be stored, then the long-running operation retrieved later by name
            lro::Operation <Operation, Operation> retrievedResponse = targetHttpProxiesClient.PollOncePatch(operationName);

            // Check if the retrieved long-running operation has completed
            if (retrievedResponse.IsCompleted)
            {
                // If it has completed, then access the result
                Operation retrievedResult = retrievedResponse.Result;
            }
            // End snippet
        }
Exemple #4
0
 /// <summary>Snippet for AggregatedList</summary>
 public void AggregatedList()
 {
     // Snippet: AggregatedList(string, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     string project = "";
     // Make the request
     TargetHttpProxyAggregatedList response = targetHttpProxiesClient.AggregatedList(project);
     // End snippet
 }
Exemple #5
0
 /// <summary>Snippet for Insert</summary>
 public void Insert()
 {
     // Snippet: Insert(string, TargetHttpProxy, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     string          project = "";
     TargetHttpProxy targetHttpProxyResource = new TargetHttpProxy();
     // Make the request
     Operation response = targetHttpProxiesClient.Insert(project, targetHttpProxyResource);
     // End snippet
 }
Exemple #6
0
 /// <summary>Snippet for Get</summary>
 public void Get()
 {
     // Snippet: Get(string, string, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     string project         = "";
     string targetHttpProxy = "";
     // Make the request
     TargetHttpProxy response = targetHttpProxiesClient.Get(project, targetHttpProxy);
     // End snippet
 }
        /// <summary>Snippet for AggregatedListAsync</summary>
        public async Task AggregatedListRequestObjectAsync()
        {
            // Snippet: AggregatedListAsync(AggregatedListTargetHttpProxiesRequest, CallSettings)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            AggregatedListTargetHttpProxiesRequest request = new AggregatedListTargetHttpProxiesRequest
            {
                OrderBy              = "",
                Project              = "",
                Filter               = "",
                IncludeAllScopes     = false,
                ReturnPartialSuccess = false,
            };
            // Make the request
            PagedAsyncEnumerable <TargetHttpProxyAggregatedList, KeyValuePair <string, TargetHttpProxiesScopedList> > response = targetHttpProxiesClient.AggregatedListAsync(request);

            // Iterate over all response items, lazily performing RPCs as required
            await response.ForEachAsync((KeyValuePair <string, TargetHttpProxiesScopedList> item) =>
            {
                // Do something with each item
                Console.WriteLine(item);
            });

            // Or iterate over pages (of server-defined size), performing one RPC per page
            await response.AsRawResponses().ForEachAsync((TargetHttpProxyAggregatedList page) =>
            {
                // Do something with each page of items
                Console.WriteLine("A page of results:");
                foreach (KeyValuePair <string, TargetHttpProxiesScopedList> item in page)
                {
                    // Do something with each item
                    Console.WriteLine(item);
                }
            });

            // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
            int pageSize = 10;
            Page <KeyValuePair <string, TargetHttpProxiesScopedList> > singlePage = await response.ReadPageAsync(pageSize);

            // Do something with the page of items
            Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
            foreach (KeyValuePair <string, TargetHttpProxiesScopedList> item in singlePage)
            {
                // Do something with each item
                Console.WriteLine(item);
            }
            // Store the pageToken, for when the next page is required.
            string nextPageToken = singlePage.NextPageToken;
            // End snippet
        }
Exemple #8
0
 /// <summary>Snippet for SetUrlMap</summary>
 public void SetUrlMap()
 {
     // Snippet: SetUrlMap(string, string, UrlMapReference, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     string          project                 = "";
     string          targetHttpProxy         = "";
     UrlMapReference urlMapReferenceResource = new UrlMapReference();
     // Make the request
     Operation response = targetHttpProxiesClient.SetUrlMap(project, targetHttpProxy, urlMapReferenceResource);
     // End snippet
 }
        /// <summary>Snippet for List</summary>
        public void ListRequestObject()
        {
            // Snippet: List(ListTargetHttpProxiesRequest, CallSettings)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
            // Initialize request argument(s)
            ListTargetHttpProxiesRequest request = new ListTargetHttpProxiesRequest
            {
                OrderBy = "",
                Project = "",
                Filter  = "",
                ReturnPartialSuccess = false,
            };
            // Make the request
            PagedEnumerable <TargetHttpProxyList, TargetHttpProxy> response = targetHttpProxiesClient.List(request);

            // Iterate over all response items, lazily performing RPCs as required
            foreach (TargetHttpProxy item in response)
            {
                // Do something with each item
                Console.WriteLine(item);
            }

            // Or iterate over pages (of server-defined size), performing one RPC per page
            foreach (TargetHttpProxyList page in response.AsRawResponses())
            {
                // Do something with each page of items
                Console.WriteLine("A page of results:");
                foreach (TargetHttpProxy item in page)
                {
                    // Do something with each item
                    Console.WriteLine(item);
                }
            }

            // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
            int pageSize = 10;
            Page <TargetHttpProxy> singlePage = response.ReadPage(pageSize);

            // Do something with the page of items
            Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
            foreach (TargetHttpProxy item in singlePage)
            {
                // Do something with each item
                Console.WriteLine(item);
            }
            // Store the pageToken, for when the next page is required.
            string nextPageToken = singlePage.NextPageToken;
            // End snippet
        }
Exemple #10
0
        /// <summary>Snippet for AggregatedListAsync</summary>
        public async Task AggregatedListAsync()
        {
            // Snippet: AggregatedListAsync(string, CallSettings)
            // Additional: AggregatedListAsync(string, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            string project = "";
            // Make the request
            TargetHttpProxyAggregatedList response = await targetHttpProxiesClient.AggregatedListAsync(project);

            // End snippet
        }
Exemple #11
0
 /// <summary>Snippet for Get</summary>
 public void GetRequestObject()
 {
     // Snippet: Get(GetTargetHttpProxyRequest, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     GetTargetHttpProxyRequest request = new GetTargetHttpProxyRequest
     {
         TargetHttpProxy = "",
         Project         = "",
     };
     // Make the request
     TargetHttpProxy response = targetHttpProxiesClient.Get(request);
     // End snippet
 }
Exemple #12
0
        /// <summary>Snippet for GetAsync</summary>
        public async Task GetAsync()
        {
            // Snippet: GetAsync(string, string, CallSettings)
            // Additional: GetAsync(string, string, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            string project         = "";
            string targetHttpProxy = "";
            // Make the request
            TargetHttpProxy response = await targetHttpProxiesClient.GetAsync(project, targetHttpProxy);

            // End snippet
        }
Exemple #13
0
        /// <summary>Snippet for InsertAsync</summary>
        public async Task InsertAsync()
        {
            // Snippet: InsertAsync(string, TargetHttpProxy, CallSettings)
            // Additional: InsertAsync(string, TargetHttpProxy, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            string          project = "";
            TargetHttpProxy targetHttpProxyResource = new TargetHttpProxy();
            // Make the request
            Operation response = await targetHttpProxiesClient.InsertAsync(project, targetHttpProxyResource);

            // End snippet
        }
Exemple #14
0
        /// <summary>Snippet for SetUrlMapAsync</summary>
        public async Task SetUrlMapAsync()
        {
            // Snippet: SetUrlMapAsync(string, string, UrlMapReference, CallSettings)
            // Additional: SetUrlMapAsync(string, string, UrlMapReference, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            string          project                 = "";
            string          targetHttpProxy         = "";
            UrlMapReference urlMapReferenceResource = new UrlMapReference();
            // Make the request
            Operation response = await targetHttpProxiesClient.SetUrlMapAsync(project, targetHttpProxy, urlMapReferenceResource);

            // End snippet
        }
Exemple #15
0
 /// <summary>Snippet for Delete</summary>
 public void DeleteRequestObject()
 {
     // Snippet: Delete(DeleteTargetHttpProxyRequest, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     DeleteTargetHttpProxyRequest request = new DeleteTargetHttpProxyRequest
     {
         RequestId       = "",
         TargetHttpProxy = "",
         Project         = "",
     };
     // Make the request
     Operation response = targetHttpProxiesClient.Delete(request);
     // End snippet
 }
Exemple #16
0
 /// <summary>Snippet for Insert</summary>
 public void InsertRequestObject()
 {
     // Snippet: Insert(InsertTargetHttpProxyRequest, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     InsertTargetHttpProxyRequest request = new InsertTargetHttpProxyRequest
     {
         TargetHttpProxyResource = new TargetHttpProxy(),
         RequestId = "",
         Project   = "",
     };
     // Make the request
     Operation response = targetHttpProxiesClient.Insert(request);
     // End snippet
 }
Exemple #17
0
 /// <summary>Snippet for SetUrlMap</summary>
 public void SetUrlMapRequestObject()
 {
     // Snippet: SetUrlMap(SetUrlMapTargetHttpProxyRequest, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     SetUrlMapTargetHttpProxyRequest request = new SetUrlMapTargetHttpProxyRequest
     {
         RequestId               = "",
         TargetHttpProxy         = "",
         Project                 = "",
         UrlMapReferenceResource = new UrlMapReference(),
     };
     // Make the request
     Operation response = targetHttpProxiesClient.SetUrlMap(request);
     // End snippet
 }
        /// <summary>Snippet for ListAsync</summary>
        public async Task ListAsync()
        {
            // Snippet: ListAsync(string, string, int?, CallSettings)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            string project = "";
            // Make the request
            PagedAsyncEnumerable <TargetHttpProxyList, TargetHttpProxy> response = targetHttpProxiesClient.ListAsync(project);

            // Iterate over all response items, lazily performing RPCs as required
            await response.ForEachAsync((TargetHttpProxy item) =>
            {
                // Do something with each item
                Console.WriteLine(item);
            });

            // Or iterate over pages (of server-defined size), performing one RPC per page
            await response.AsRawResponses().ForEachAsync((TargetHttpProxyList page) =>
            {
                // Do something with each page of items
                Console.WriteLine("A page of results:");
                foreach (TargetHttpProxy item in page)
                {
                    // Do something with each item
                    Console.WriteLine(item);
                }
            });

            // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
            int pageSize = 10;
            Page <TargetHttpProxy> singlePage = await response.ReadPageAsync(pageSize);

            // Do something with the page of items
            Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
            foreach (TargetHttpProxy item in singlePage)
            {
                // Do something with each item
                Console.WriteLine(item);
            }
            // Store the pageToken, for when the next page is required.
            string nextPageToken = singlePage.NextPageToken;
            // End snippet
        }
Exemple #19
0
        /// <summary>Snippet for GetAsync</summary>
        public async Task GetRequestObjectAsync()
        {
            // Snippet: GetAsync(GetTargetHttpProxyRequest, CallSettings)
            // Additional: GetAsync(GetTargetHttpProxyRequest, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            GetTargetHttpProxyRequest request = new GetTargetHttpProxyRequest
            {
                TargetHttpProxy = "",
                Project         = "",
            };
            // Make the request
            TargetHttpProxy response = await targetHttpProxiesClient.GetAsync(request);

            // End snippet
        }
        /// <summary>Snippet for AggregatedList</summary>
        public void AggregatedList()
        {
            // Snippet: AggregatedList(string, string, int?, CallSettings)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
            // Initialize request argument(s)
            string project = "";
            // Make the request
            PagedEnumerable <TargetHttpProxyAggregatedList, KeyValuePair <string, TargetHttpProxiesScopedList> > response = targetHttpProxiesClient.AggregatedList(project);

            // Iterate over all response items, lazily performing RPCs as required
            foreach (KeyValuePair <string, TargetHttpProxiesScopedList> item in response)
            {
                // Do something with each item
                Console.WriteLine(item);
            }

            // Or iterate over pages (of server-defined size), performing one RPC per page
            foreach (TargetHttpProxyAggregatedList page in response.AsRawResponses())
            {
                // Do something with each page of items
                Console.WriteLine("A page of results:");
                foreach (KeyValuePair <string, TargetHttpProxiesScopedList> item in page)
                {
                    // Do something with each item
                    Console.WriteLine(item);
                }
            }

            // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
            int pageSize = 10;
            Page <KeyValuePair <string, TargetHttpProxiesScopedList> > singlePage = response.ReadPage(pageSize);

            // Do something with the page of items
            Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
            foreach (KeyValuePair <string, TargetHttpProxiesScopedList> item in singlePage)
            {
                // Do something with each item
                Console.WriteLine(item);
            }
            // Store the pageToken, for when the next page is required.
            string nextPageToken = singlePage.NextPageToken;
            // End snippet
        }
Exemple #21
0
 /// <summary>Snippet for List</summary>
 public void ListRequestObject()
 {
     // Snippet: List(ListTargetHttpProxiesRequest, CallSettings)
     // Create client
     TargetHttpProxiesClient targetHttpProxiesClient = TargetHttpProxiesClient.Create();
     // Initialize request argument(s)
     ListTargetHttpProxiesRequest request = new ListTargetHttpProxiesRequest
     {
         PageToken            = "",
         MaxResults           = 0U,
         OrderBy              = "",
         Project              = "",
         Filter               = "",
         ReturnPartialSuccess = false,
     };
     // Make the request
     TargetHttpProxyList response = targetHttpProxiesClient.List(request);
     // End snippet
 }
Exemple #22
0
        /// <summary>Snippet for InsertAsync</summary>
        public async Task InsertRequestObjectAsync()
        {
            // Snippet: InsertAsync(InsertTargetHttpProxyRequest, CallSettings)
            // Additional: InsertAsync(InsertTargetHttpProxyRequest, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            InsertTargetHttpProxyRequest request = new InsertTargetHttpProxyRequest
            {
                TargetHttpProxyResource = new TargetHttpProxy(),
                RequestId = "",
                Project   = "",
            };
            // Make the request
            Operation response = await targetHttpProxiesClient.InsertAsync(request);

            // End snippet
        }
Exemple #23
0
        /// <summary>Snippet for DeleteAsync</summary>
        public async Task DeleteRequestObjectAsync()
        {
            // Snippet: DeleteAsync(DeleteTargetHttpProxyRequest, CallSettings)
            // Additional: DeleteAsync(DeleteTargetHttpProxyRequest, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            DeleteTargetHttpProxyRequest request = new DeleteTargetHttpProxyRequest
            {
                RequestId       = "",
                TargetHttpProxy = "",
                Project         = "",
            };
            // Make the request
            Operation response = await targetHttpProxiesClient.DeleteAsync(request);

            // End snippet
        }
Exemple #24
0
        /// <summary>Snippet for SetUrlMapAsync</summary>
        public async Task SetUrlMapRequestObjectAsync()
        {
            // Snippet: SetUrlMapAsync(SetUrlMapTargetHttpProxyRequest, CallSettings)
            // Additional: SetUrlMapAsync(SetUrlMapTargetHttpProxyRequest, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            SetUrlMapTargetHttpProxyRequest request = new SetUrlMapTargetHttpProxyRequest
            {
                RequestId               = "",
                TargetHttpProxy         = "",
                Project                 = "",
                UrlMapReferenceResource = new UrlMapReference(),
            };
            // Make the request
            Operation response = await targetHttpProxiesClient.SetUrlMapAsync(request);

            // End snippet
        }
Exemple #25
0
        /// <summary>Snippet for ListAsync</summary>
        public async Task ListRequestObjectAsync()
        {
            // Snippet: ListAsync(ListTargetHttpProxiesRequest, CallSettings)
            // Additional: ListAsync(ListTargetHttpProxiesRequest, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            ListTargetHttpProxiesRequest request = new ListTargetHttpProxiesRequest
            {
                PageToken            = "",
                MaxResults           = 0U,
                OrderBy              = "",
                Project              = "",
                Filter               = "",
                ReturnPartialSuccess = false,
            };
            // Make the request
            TargetHttpProxyList response = await targetHttpProxiesClient.ListAsync(request);

            // End snippet
        }
        /// <summary>Snippet for SetUrlMapAsync</summary>
        public async Task SetUrlMapRequestObjectAsync()
        {
            // Snippet: SetUrlMapAsync(SetUrlMapTargetHttpProxyRequest, CallSettings)
            // Additional: SetUrlMapAsync(SetUrlMapTargetHttpProxyRequest, CancellationToken)
            // Create client
            TargetHttpProxiesClient targetHttpProxiesClient = await TargetHttpProxiesClient.CreateAsync();

            // Initialize request argument(s)
            SetUrlMapTargetHttpProxyRequest request = new SetUrlMapTargetHttpProxyRequest
            {
                RequestId               = "",
                TargetHttpProxy         = "",
                Project                 = "",
                UrlMapReferenceResource = new UrlMapReference(),
            };
            // Make the request
            lro::Operation <Operation, Operation> response = await targetHttpProxiesClient.SetUrlMapAsync(request);

            // Poll until the returned long-running operation is complete
            lro::Operation <Operation, Operation> completedResponse = await response.PollUntilCompletedAsync();

            // Retrieve the operation result
            Operation result = completedResponse.Result;

            // Or get the name of the operation
            string operationName = response.Name;
            // This name can be stored, then the long-running operation retrieved later by name
            lro::Operation <Operation, Operation> retrievedResponse = await targetHttpProxiesClient.PollOnceSetUrlMapAsync(operationName);

            // Check if the retrieved long-running operation has completed
            if (retrievedResponse.IsCompleted)
            {
                // If it has completed, then access the result
                Operation retrievedResult = retrievedResponse.Result;
            }
            // End snippet
        }