private FeaturestoreOnlineServingServiceSettings(FeaturestoreOnlineServingServiceSettings existing) : base(existing) { gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); ReadFeatureValuesSettings = existing.ReadFeatureValuesSettings; StreamingReadFeatureValuesSettings = existing.StreamingReadFeatureValuesSettings; OnCopy(existing); }
/// <summary> /// Constructs a client wrapper for the FeaturestoreOnlineServingService service, with the specified gRPC client /// and settings. /// </summary> /// <param name="grpcClient">The underlying gRPC client.</param> /// <param name="settings"> /// The base <see cref="FeaturestoreOnlineServingServiceSettings"/> used within this client. /// </param> public FeaturestoreOnlineServingServiceClientImpl(FeaturestoreOnlineServingService.FeaturestoreOnlineServingServiceClient grpcClient, FeaturestoreOnlineServingServiceSettings settings) { GrpcClient = grpcClient; FeaturestoreOnlineServingServiceSettings effectiveSettings = settings ?? FeaturestoreOnlineServingServiceSettings.GetDefault(); gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); _callReadFeatureValues = clientHelper.BuildApiCall <ReadFeatureValuesRequest, ReadFeatureValuesResponse>(grpcClient.ReadFeatureValuesAsync, grpcClient.ReadFeatureValues, effectiveSettings.ReadFeatureValuesSettings).WithGoogleRequestParam("entity_type", request => request.EntityType); Modify_ApiCall(ref _callReadFeatureValues); Modify_ReadFeatureValuesApiCall(ref _callReadFeatureValues); _callStreamingReadFeatureValues = clientHelper.BuildApiCall <StreamingReadFeatureValuesRequest, ReadFeatureValuesResponse>(grpcClient.StreamingReadFeatureValues, effectiveSettings.StreamingReadFeatureValuesSettings).WithGoogleRequestParam("entity_type", request => request.EntityType); Modify_ApiCall(ref _callStreamingReadFeatureValues); Modify_StreamingReadFeatureValuesApiCall(ref _callStreamingReadFeatureValues); OnConstruction(grpcClient, effectiveSettings, clientHelper); }
partial void OnCopy(FeaturestoreOnlineServingServiceSettings existing);
partial void OnConstruction(FeaturestoreOnlineServingService.FeaturestoreOnlineServingServiceClient grpcClient, FeaturestoreOnlineServingServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper);
/// <summary> /// Creates a <see cref="FeaturestoreOnlineServingServiceClient"/> 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="FeaturestoreOnlineServingServiceSettings"/>.</param> /// <returns>The created <see cref="FeaturestoreOnlineServingServiceClient"/>.</returns> internal static FeaturestoreOnlineServingServiceClient Create(grpccore::CallInvoker callInvoker, FeaturestoreOnlineServingServiceSettings settings = null) { gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); grpcinter::Interceptor interceptor = settings?.Interceptor; if (interceptor != null) { callInvoker = grpcinter::CallInvokerExtensions.Intercept(callInvoker, interceptor); } FeaturestoreOnlineServingService.FeaturestoreOnlineServingServiceClient grpcClient = new FeaturestoreOnlineServingService.FeaturestoreOnlineServingServiceClient(callInvoker); return(new FeaturestoreOnlineServingServiceClientImpl(grpcClient, settings)); }