Package io.grpc.netty
Class NettyServerProvider
- java.lang.Object
-
- io.grpc.ServerProvider
-
- io.grpc.netty.NettyServerProvider
-
@Internal public final class NettyServerProvider extends ServerProvider
Provider forNettyServerBuilderinstances.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class io.grpc.ServerProvider
ServerProvider.NewServerBuilderResult
-
-
Constructor Summary
Constructors Constructor Description NettyServerProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected NettyServerBuilderbuilderForPort(int port)Creates a new builder with the given port.protected booleanisAvailable()Whether this provider is available for use, taking the current environment into consideration.protected ServerProvider.NewServerBuilderResultnewServerBuilderForPort(int port, ServerCredentials creds)Creates a new builder with the given port and credentials.protected intpriority()A priority, from 0 to 10 that this provider should be used, taking the current environment into consideration.-
Methods inherited from class io.grpc.ServerProvider
provider
-
-
-
-
Method Detail
-
isAvailable
protected boolean isAvailable()
Description copied from class:ServerProviderWhether this provider is available for use, taking the current environment into consideration. Iffalse, no other methods are safe to be called.- Specified by:
isAvailablein classServerProvider
-
priority
protected int priority()
Description copied from class:ServerProviderA priority, from 0 to 10 that this provider should be used, taking the current environment into consideration. 5 should be considered the default, and then tweaked based on environment detection. A priority of 0 does not imply that the provider wouldn't work; just that it should be last in line.- Specified by:
priorityin classServerProvider
-
builderForPort
protected NettyServerBuilder builderForPort(int port)
Description copied from class:ServerProviderCreates a new builder with the given port.- Specified by:
builderForPortin classServerProvider
-
newServerBuilderForPort
protected ServerProvider.NewServerBuilderResult newServerBuilderForPort(int port, ServerCredentials creds)
Description copied from class:ServerProviderCreates a new builder with the given port and credentials. Returns an error-string result if unable to understand the credentials.- Overrides:
newServerBuilderForPortin classServerProvider
-
-