/** * Constructs an instance of GrpcSessionsStub, using the given settings. This is protected so that * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. */ protected GrpcSessionsStub( SessionsStubSettings settings, ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; GrpcCallSettings<DetectIntentRequest, DetectIntentResponse> detectIntentTransportSettings = GrpcCallSettings.<DetectIntentRequest, DetectIntentResponse>newBuilder() .setMethodDescriptor(detectIntentMethodDescriptor) .build(); GrpcCallSettings<StreamingDetectIntentRequest, StreamingDetectIntentResponse> streamingDetectIntentTransportSettings = GrpcCallSettings .<StreamingDetectIntentRequest, StreamingDetectIntentResponse>newBuilder() .setMethodDescriptor(streamingDetectIntentMethodDescriptor) .build(); this.detectIntentCallable = callableFactory.createUnaryCallable( detectIntentTransportSettings, settings.detectIntentSettings(), clientContext); this.streamingDetectIntentCallable = callableFactory.createBidiStreamingCallable( streamingDetectIntentTransportSettings, settings.streamingDetectIntentSettings(), clientContext); backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); }
/** * Constructs an instance of GrpcSessionsStub, using the given settings. This is protected so that * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. */ protected GrpcSessionsStub( SessionsStubSettings settings, ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; GrpcCallSettings<DetectIntentRequest, DetectIntentResponse> detectIntentTransportSettings = GrpcCallSettings.<DetectIntentRequest, DetectIntentResponse>newBuilder() .setMethodDescriptor(detectIntentMethodDescriptor) .build(); GrpcCallSettings<StreamingDetectIntentRequest, StreamingDetectIntentResponse> streamingDetectIntentTransportSettings = GrpcCallSettings .<StreamingDetectIntentRequest, StreamingDetectIntentResponse>newBuilder() .setMethodDescriptor(streamingDetectIntentMethodDescriptor) .build(); this.detectIntentCallable = callableFactory.createUnaryCallable( detectIntentTransportSettings, settings.detectIntentSettings(), clientContext); this.streamingDetectIntentCallable = callableFactory.createBidiStreamingCallable( streamingDetectIntentTransportSettings, settings.streamingDetectIntentSettings(), clientContext); backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); }
this.operationsStub); this.streamingRecognizeCallable = callableFactory.createBidiStreamingCallable( streamingRecognizeTransportSettings, settings.streamingRecognizeSettings(),
this.operationsStub); this.streamingRecognizeCallable = callableFactory.createBidiStreamingCallable( streamingRecognizeTransportSettings, settings.streamingRecognizeSettings(),
runQueryTransportSettings, settings.runQuerySettings(), clientContext); this.writeCallable = callableFactory.createBidiStreamingCallable( writeTransportSettings, settings.writeSettings(), clientContext); this.listenCallable = callableFactory.createBidiStreamingCallable( listenTransportSettings, settings.listenSettings(), clientContext); this.listCollectionIdsCallable =
runQueryTransportSettings, settings.runQuerySettings(), clientContext); this.writeCallable = callableFactory.createBidiStreamingCallable( writeTransportSettings, settings.writeSettings(), clientContext); this.listenCallable = callableFactory.createBidiStreamingCallable( listenTransportSettings, settings.listenSettings(), clientContext); this.listCollectionIdsCallable =
pullTransportSettings, settings.pullSettings(), clientContext); this.streamingPullCallable = callableFactory.createBidiStreamingCallable( streamingPullTransportSettings, settings.streamingPullSettings(), clientContext); this.modifyPushConfigCallable =
/** * Constructs an instance of GrpcSessionsStub, using the given settings. This is protected so that * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. */ protected GrpcSessionsStub( SessionsStubSettings settings, ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; GrpcCallSettings<DetectIntentRequest, DetectIntentResponse> detectIntentTransportSettings = GrpcCallSettings.<DetectIntentRequest, DetectIntentResponse>newBuilder() .setMethodDescriptor(detectIntentMethodDescriptor) .build(); GrpcCallSettings<StreamingDetectIntentRequest, StreamingDetectIntentResponse> streamingDetectIntentTransportSettings = GrpcCallSettings .<StreamingDetectIntentRequest, StreamingDetectIntentResponse>newBuilder() .setMethodDescriptor(streamingDetectIntentMethodDescriptor) .build(); this.detectIntentCallable = callableFactory.createUnaryCallable( detectIntentTransportSettings, settings.detectIntentSettings(), clientContext); this.streamingDetectIntentCallable = callableFactory.createBidiStreamingCallable( streamingDetectIntentTransportSettings, settings.streamingDetectIntentSettings(), clientContext); backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); }
/** * Constructs an instance of GrpcSessionsStub, using the given settings. This is protected so that * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. */ protected GrpcSessionsStub( SessionsStubSettings settings, ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; GrpcCallSettings<DetectIntentRequest, DetectIntentResponse> detectIntentTransportSettings = GrpcCallSettings.<DetectIntentRequest, DetectIntentResponse>newBuilder() .setMethodDescriptor(detectIntentMethodDescriptor) .build(); GrpcCallSettings<StreamingDetectIntentRequest, StreamingDetectIntentResponse> streamingDetectIntentTransportSettings = GrpcCallSettings .<StreamingDetectIntentRequest, StreamingDetectIntentResponse>newBuilder() .setMethodDescriptor(streamingDetectIntentMethodDescriptor) .build(); this.detectIntentCallable = callableFactory.createUnaryCallable( detectIntentTransportSettings, settings.detectIntentSettings(), clientContext); this.streamingDetectIntentCallable = callableFactory.createBidiStreamingCallable( streamingDetectIntentTransportSettings, settings.streamingDetectIntentSettings(), clientContext); backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); }
runQueryTransportSettings, settings.runQuerySettings(), clientContext); this.writeCallable = callableFactory.createBidiStreamingCallable( writeTransportSettings, settings.writeSettings(), clientContext); this.listenCallable = callableFactory.createBidiStreamingCallable( listenTransportSettings, settings.listenSettings(), clientContext); this.listCollectionIdsCallable =