Beispiel #1
0
 private KeywordPlanAdGroupKeywordServiceSettings(KeywordPlanAdGroupKeywordServiceSettings existing) : base(existing)
 {
     gax::GaxPreconditions.CheckNotNull(existing, nameof(existing));
     GetKeywordPlanAdGroupKeywordSettings     = existing.GetKeywordPlanAdGroupKeywordSettings;
     MutateKeywordPlanAdGroupKeywordsSettings = existing.MutateKeywordPlanAdGroupKeywordsSettings;
     OnCopy(existing);
 }
Beispiel #2
0
        /// <summary>
        /// Constructs a client wrapper for the KeywordPlanAdGroupKeywordService service, with the specified gRPC client
        /// and settings.
        /// </summary>
        /// <param name="grpcClient">The underlying gRPC client.</param>
        /// <param name="settings">
        /// The base <see cref="KeywordPlanAdGroupKeywordServiceSettings"/> used within this client.
        /// </param>
        public KeywordPlanAdGroupKeywordServiceClientImpl(KeywordPlanAdGroupKeywordService.KeywordPlanAdGroupKeywordServiceClient grpcClient, KeywordPlanAdGroupKeywordServiceSettings settings)
        {
            GrpcClient = grpcClient;
            KeywordPlanAdGroupKeywordServiceSettings effectiveSettings = settings ?? KeywordPlanAdGroupKeywordServiceSettings.GetDefault();
            gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings);

            _callGetKeywordPlanAdGroupKeyword = clientHelper.BuildApiCall <GetKeywordPlanAdGroupKeywordRequest, gagvr::KeywordPlanAdGroupKeyword>(grpcClient.GetKeywordPlanAdGroupKeywordAsync, grpcClient.GetKeywordPlanAdGroupKeyword, effectiveSettings.GetKeywordPlanAdGroupKeywordSettings).WithGoogleRequestParam("resource_name", request => request.ResourceName);
            Modify_ApiCall(ref _callGetKeywordPlanAdGroupKeyword);
            Modify_GetKeywordPlanAdGroupKeywordApiCall(ref _callGetKeywordPlanAdGroupKeyword);
            _callMutateKeywordPlanAdGroupKeywords = clientHelper.BuildApiCall <MutateKeywordPlanAdGroupKeywordsRequest, MutateKeywordPlanAdGroupKeywordsResponse>(grpcClient.MutateKeywordPlanAdGroupKeywordsAsync, grpcClient.MutateKeywordPlanAdGroupKeywords, effectiveSettings.MutateKeywordPlanAdGroupKeywordsSettings).WithGoogleRequestParam("customer_id", request => request.CustomerId);
            Modify_ApiCall(ref _callMutateKeywordPlanAdGroupKeywords);
            Modify_MutateKeywordPlanAdGroupKeywordsApiCall(ref _callMutateKeywordPlanAdGroupKeywords);
            OnConstruction(grpcClient, effectiveSettings, clientHelper);
        }
Beispiel #3
0
 partial void OnCopy(KeywordPlanAdGroupKeywordServiceSettings existing);
Beispiel #4
0
 partial void OnConstruction(KeywordPlanAdGroupKeywordService.KeywordPlanAdGroupKeywordServiceClient grpcClient, KeywordPlanAdGroupKeywordServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper);
Beispiel #5
0
        /// <summary>
        /// Creates a <see cref="KeywordPlanAdGroupKeywordServiceClient"/> which uses the specified call invoker for
        /// remote operations.
        /// </summary>
        /// <param name="callInvoker">
        /// The <see cref="grpccore::CallInvoker"/> for remote operations. Must not be null.
        /// </param>
        /// <param name="settings">Optional <see cref="KeywordPlanAdGroupKeywordServiceSettings"/>.</param>
        /// <returns>The created <see cref="KeywordPlanAdGroupKeywordServiceClient"/>.</returns>
        internal static KeywordPlanAdGroupKeywordServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanAdGroupKeywordServiceSettings settings = null)
        {
            gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker));
            grpcinter::Interceptor interceptor = settings?.Interceptor;

            if (interceptor != null)
            {
                callInvoker = grpcinter::CallInvokerExtensions.Intercept(callInvoker, interceptor);
            }
            KeywordPlanAdGroupKeywordService.KeywordPlanAdGroupKeywordServiceClient grpcClient = new KeywordPlanAdGroupKeywordService.KeywordPlanAdGroupKeywordServiceClient(callInvoker);
            return(new KeywordPlanAdGroupKeywordServiceClientImpl(grpcClient, settings));
        }