public interface BindableService
It is used by service's abstract class generated by compiler (eg.: RouteGuideGrpc.RouteGuideImplBase for RouteGuide service) and lets implementation classes to be bind to server.
class RouteGuideService extends RouteGuideGrpc.RouteGuideImplBase {
// ...
}
Server server = ServerBuilder.forPort(1234).addService(new RouteGuideService()).build();
Modifier and Type | Method and Description |
---|---|
ServerServiceDefinition |
bindService()
Creates
ServerServiceDefinition object for current instance of service implementation. |
ServerServiceDefinition bindService()
ServerServiceDefinition
object for current instance of service implementation.