Class GrpcServiceBuilder
java.lang.Object
io.helidon.microprofile.grpc.core.AbstractServiceBuilder
io.helidon.microprofile.grpc.server.GrpcServiceBuilder
- All Implemented Interfaces:
Builder<GrpcServiceBuilder,
,ServiceDescriptor> Supplier<ServiceDescriptor>
public class GrpcServiceBuilder
extends AbstractServiceBuilder
implements Builder<GrpcServiceBuilder,ServiceDescriptor>
A builder for constructing a
ServiceDescriptor
instances from an annotated POJOs.-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Create aServiceDescriptor.Builder
introspected class.static GrpcServiceBuilder
create
(Class<?> serviceClass, BeanManager beanManager) Create a new introspection modeller for a given gRPC service class.static GrpcServiceBuilder
create
(Class<?> serviceClass, Supplier<?> instance, BeanManager beanManager) Create aGrpcServiceBuilder
for a given gRPC service class.static GrpcServiceBuilder
create
(Object service, BeanManager beanManager) Create a new introspection modeller for a given gRPC service.Methods inherited from class io.helidon.microprofile.grpc.core.AbstractServiceBuilder
annotatedServiceClass, checkForNonPublicMethodIssues, createInstanceSupplier, determineMethodName, determineServiceName, getAllDeclaredMethods, getMarshallerSupplier, handlerSuppliers, instanceSupplier, isAnnotatedService, serviceClass
-
Method Details
-
create
Create a new introspection modeller for a given gRPC service.- Parameters:
service
- the service to call gRPC handler methods onbeanManager
- theBeanManager
to use to look-up CDI beans.- Returns:
- a
GrpcServiceBuilder
- Throws:
NullPointerException
- if the service is null
-
create
Create a new introspection modeller for a given gRPC service class.- Parameters:
serviceClass
- gRPC service (handler) class.beanManager
- theBeanManager
to use to look-up CDI beans.- Returns:
- a
GrpcServiceBuilder
- Throws:
NullPointerException
- if the service class is null
-
create
public static GrpcServiceBuilder create(Class<?> serviceClass, Supplier<?> instance, BeanManager beanManager) Create aGrpcServiceBuilder
for a given gRPC service class.- Parameters:
serviceClass
- gRPC service (handler) class.instance
- the target instance to call gRPC handler methods onbeanManager
- theBeanManager
to use to look-up CDI beans.- Returns:
- a
GrpcServiceBuilder
- Throws:
NullPointerException
- if the service or instance parameters are null
-
build
Create aServiceDescriptor.Builder
introspected class.- Specified by:
build
in interfaceBuilder<GrpcServiceBuilder,
ServiceDescriptor> - Returns:
- a
ServiceDescriptor.Builder
for the introspected class.
-