/// <summary>
        /// Constructs a client wrapper for the DomainMappings service, with the specified gRPC client and settings.
        /// </summary>
        /// <param name="grpcClient">The underlying gRPC client.</param>
        /// <param name="settings">The base <see cref="DomainMappingsSettings"/> used within this client.</param>
        public DomainMappingsClientImpl(DomainMappings.DomainMappingsClient grpcClient, DomainMappingsSettings settings)
        {
            GrpcClient = grpcClient;
            DomainMappingsSettings effectiveSettings = settings ?? DomainMappingsSettings.GetDefault();
            gaxgrpc::ClientHelper  clientHelper      = new gaxgrpc::ClientHelper(effectiveSettings);

            CreateDomainMappingOperationsClient = new lro::OperationsClientImpl(grpcClient.CreateOperationsClient(), effectiveSettings.CreateDomainMappingOperationsSettings);
            UpdateDomainMappingOperationsClient = new lro::OperationsClientImpl(grpcClient.CreateOperationsClient(), effectiveSettings.UpdateDomainMappingOperationsSettings);
            DeleteDomainMappingOperationsClient = new lro::OperationsClientImpl(grpcClient.CreateOperationsClient(), effectiveSettings.DeleteDomainMappingOperationsSettings);
            _callListDomainMappings             = clientHelper.BuildApiCall <ListDomainMappingsRequest, ListDomainMappingsResponse>(grpcClient.ListDomainMappingsAsync, grpcClient.ListDomainMappings, effectiveSettings.ListDomainMappingsSettings).WithGoogleRequestParam("parent", request => request.Parent);
            Modify_ApiCall(ref _callListDomainMappings);
            Modify_ListDomainMappingsApiCall(ref _callListDomainMappings);
            _callGetDomainMapping = clientHelper.BuildApiCall <GetDomainMappingRequest, DomainMapping>(grpcClient.GetDomainMappingAsync, grpcClient.GetDomainMapping, effectiveSettings.GetDomainMappingSettings).WithGoogleRequestParam("name", request => request.Name);
            Modify_ApiCall(ref _callGetDomainMapping);
            Modify_GetDomainMappingApiCall(ref _callGetDomainMapping);
            _callCreateDomainMapping = clientHelper.BuildApiCall <CreateDomainMappingRequest, lro::Operation>(grpcClient.CreateDomainMappingAsync, grpcClient.CreateDomainMapping, effectiveSettings.CreateDomainMappingSettings).WithGoogleRequestParam("parent", request => request.Parent);
            Modify_ApiCall(ref _callCreateDomainMapping);
            Modify_CreateDomainMappingApiCall(ref _callCreateDomainMapping);
            _callUpdateDomainMapping = clientHelper.BuildApiCall <UpdateDomainMappingRequest, lro::Operation>(grpcClient.UpdateDomainMappingAsync, grpcClient.UpdateDomainMapping, effectiveSettings.UpdateDomainMappingSettings).WithGoogleRequestParam("name", request => request.Name);
            Modify_ApiCall(ref _callUpdateDomainMapping);
            Modify_UpdateDomainMappingApiCall(ref _callUpdateDomainMapping);
            _callDeleteDomainMapping = clientHelper.BuildApiCall <DeleteDomainMappingRequest, lro::Operation>(grpcClient.DeleteDomainMappingAsync, grpcClient.DeleteDomainMapping, effectiveSettings.DeleteDomainMappingSettings).WithGoogleRequestParam("name", request => request.Name);
            Modify_ApiCall(ref _callDeleteDomainMapping);
            Modify_DeleteDomainMappingApiCall(ref _callDeleteDomainMapping);
            OnConstruction(grpcClient, effectiveSettings, clientHelper);
        }
 private DomainMappingsSettings(DomainMappingsSettings existing) : base(existing)
 {
     gax::GaxPreconditions.CheckNotNull(existing, nameof(existing));
     ListDomainMappingsSettings            = existing.ListDomainMappingsSettings;
     GetDomainMappingSettings              = existing.GetDomainMappingSettings;
     CreateDomainMappingSettings           = existing.CreateDomainMappingSettings;
     CreateDomainMappingOperationsSettings = existing.CreateDomainMappingOperationsSettings.Clone();
     UpdateDomainMappingSettings           = existing.UpdateDomainMappingSettings;
     UpdateDomainMappingOperationsSettings = existing.UpdateDomainMappingOperationsSettings.Clone();
     DeleteDomainMappingSettings           = existing.DeleteDomainMappingSettings;
     DeleteDomainMappingOperationsSettings = existing.DeleteDomainMappingOperationsSettings.Clone();
     OnCopy(existing);
 }
 partial void OnConstruction(DomainMappings.DomainMappingsClient grpcClient, DomainMappingsSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper);
 partial void OnCopy(DomainMappingsSettings existing);
        /// <summary>
        /// Creates a <see cref="DomainMappingsClient"/> 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="DomainMappingsSettings"/>.</param>
        /// <returns>The created <see cref="DomainMappingsClient"/>.</returns>
        internal static DomainMappingsClient Create(grpccore::CallInvoker callInvoker, DomainMappingsSettings settings = null)
        {
            gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker));
            grpcinter::Interceptor interceptor = settings?.Interceptor;

            if (interceptor != null)
            {
                callInvoker = grpcinter::CallInvokerExtensions.Intercept(callInvoker, interceptor);
            }
            DomainMappings.DomainMappingsClient grpcClient = new DomainMappings.DomainMappingsClient(callInvoker);
            return(new DomainMappingsClientImpl(grpcClient, settings));
        }