Interface BlockingService (3.19.4)

public interface BlockingService

Blocking equivalent to Service.

Methods

callBlockingMethod(Descriptors.MethodDescriptor method, RpcController controller, Message request)

public abstract Message callBlockingMethod(Descriptors.MethodDescriptor method, RpcController controller, Message request)

Equivalent to Service#callMethod, except that callBlockingMethod() returns the result of the RPC or throws a ServiceException if there is a failure, rather than passing the information to a callback.

Parameters
Name Description
method Descriptors.MethodDescriptor
controller RpcController
request Message
Returns
Type Description
Message
Exceptions
Type Description
ServiceException

getDescriptorForType()

public abstract Descriptors.ServiceDescriptor getDescriptorForType()
Returns
Type Description
Descriptors.ServiceDescriptor

getRequestPrototype(Descriptors.MethodDescriptor method)

public abstract Message getRequestPrototype(Descriptors.MethodDescriptor method)
Parameter
Name Description
method Descriptors.MethodDescriptor
Returns
Type Description
Message

getResponsePrototype(Descriptors.MethodDescriptor method)

public abstract Message getResponsePrototype(Descriptors.MethodDescriptor method)
Parameter
Name Description
method Descriptors.MethodDescriptor
Returns
Type Description
Message