Class GrpcSecurityHandlerConfig.BuilderBase<BUILDER extends GrpcSecurityHandlerConfig.BuilderBase<BUILDER, PROTOTYPE>, PROTOTYPE extends GrpcSecurityHandlerConfig>
java.lang.Object
io.helidon.webserver.grpc.security.GrpcSecurityHandlerConfig.BuilderBase<BUILDER, PROTOTYPE>
- Type Parameters:
BUILDER- type of the builder extending this abstract builderPROTOTYPE- type of the prototype interface that would be built byPrototype.Builder.buildPrototype()
- All Implemented Interfaces:
Prototype.Builder<BUILDER, PROTOTYPE>, ConfigBuilderSupport.ConfiguredBuilder<BUILDER, PROTOTYPE>
- Direct Known Subclasses:
GrpcSecurityHandlerConfig.Builder
- Enclosing interface:
GrpcSecurityHandlerConfig
public abstract static class GrpcSecurityHandlerConfig.BuilderBase<BUILDER extends GrpcSecurityHandlerConfig.BuilderBase<BUILDER, PROTOTYPE>, PROTOTYPE extends GrpcSecurityHandlerConfig>
extends Object
implements ConfigBuilderSupport.ConfiguredBuilder<BUILDER, PROTOTYPE>
Fluent API builder base for
GrpcSecurityHandlerConfig.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classGenerated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionRegister a custom object for security request(s).Register a custom object for security request(s).addRoleAllowed(String roleAllowed) An array of allowed roles for this gRPC method.addRolesAllowed(Set<String> rolesAllowed) An array of allowed roles for this gRPC method.addSecurityLevel(SecurityLevel securityLevel) Security levels discovered from endpoint annotations.Security levels discovered from endpoint annotations.addSecurityLevels(List<? extends SecurityLevel> securityLevels) Security levels discovered from endpoint annotations.audit()Whether to audit this request.audit(boolean audit) Whether to audit this request.Severity to use for failed requests.auditErrorSeverity(AuditEvent.AuditSeverity auditErrorSeverity) Severity to use for failed requests.Override for audit event type.auditEventType(String auditEventType) Override for audit event type.Override for audit message format.auditMessageFormat(String auditMessageFormat) Override for audit message format.Severity to use for successful requests.auditOkSeverity(AuditEvent.AuditSeverity auditOkSeverity) Severity to use for successful requests.Whether to authenticate this request.authenticate(boolean authenticate) Whether to authenticate this request.Whether authentication failure should continue as anonymous.authenticationOptional(boolean authenticationOptional) Whether authentication failure should continue as anonymous.Use a named authenticator.authenticator(String authenticator) Use a named authenticator.Whether to authorize this request.authorize(boolean authorize) Whether to authorize this request.Use a named authorizer.authorizer(String authorizer) Use a named authorizer.Clear existing value of audit.Clear existing value of auditErrorSeverity.Clear existing value of auditEventType.Clear existing value of auditMessageFormat.Clear existing value of auditOkSeverity.Clear existing value of authenticate.Clear existing value of authenticationOptional.Clear existing value of authenticator.Clear existing value of authorize.Clear existing value of authorizer.Clear existing value of customObjects.booleanWhether to clear an authenticator inherited from service defaults.clearInheritedAuthenticator(boolean clearInheritedAuthenticator) Whether to clear an authenticator inherited from service defaults.booleanWhether to clear an authorizer inherited from service defaults.clearInheritedAuthorizer(boolean clearInheritedAuthorizer) Whether to clear an authorizer inherited from service defaults.booleanWhether to clear roles inherited from service defaults.clearInheritedRolesAllowed(boolean clearInheritedRolesAllowed) Whether to clear roles inherited from service defaults.Clear all rolesAllowed.Clear all securityLevels.config()Configuration associated with this security handler.Update builder from configuration (node of this type).A store of custom objects, that can be used to customize specific security providers.customObjects(ClassToInstanceStore<Object> customObjects) A store of custom objects, that can be used to customize specific security providers.from(GrpcSecurityHandlerConfig prototype) Update this builder from an existing prototype instance.from(GrpcSecurityHandlerConfig.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.protected voidHandles providers and decorators.An array of allowed roles for this gRPC method.rolesAllowed(Set<String> rolesAllowed) An array of allowed roles for this gRPC method.Security levels discovered from endpoint annotations.securityLevels(List<? extends SecurityLevel> securityLevels) Security levels discovered from endpoint annotations.toString()protected voidValidates required properties.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface Prototype.Builder
buildPrototype, self
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
Update this builder from an existing prototype instance. This method disables automatic service discovery.- Parameters:
prototype- existing prototype to update this builder from- Returns:
- updated builder instance
-
from
Update this builder from an existing prototype builder instance.- Parameters:
builder- existing builder prototype to update this builder from- Returns:
- updated builder instance
-
addObject
-
addObject
-
config
Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Specified by:
configin interfaceConfigBuilderSupport.ConfiguredBuilder<BUILDER extends GrpcSecurityHandlerConfig.BuilderBase<BUILDER, PROTOTYPE>, PROTOTYPE extends GrpcSecurityHandlerConfig>- Parameters:
config- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
clearRolesAllowed
Clear all rolesAllowed.- Returns:
- updated builder instance
- See Also:
-
rolesAllowed
-
addRolesAllowed
-
addRoleAllowed
-
clearInheritedRolesAllowed
Whether to clear roles inherited from service defaults.- Parameters:
clearInheritedRolesAllowed- whether to clear inherited roles- Returns:
- updated builder instance
- See Also:
-
clearSecurityLevels
Clear all securityLevels.- Returns:
- updated builder instance
- See Also:
-
securityLevels
Security levels discovered from endpoint annotations.- Parameters:
securityLevels- security levels- Returns:
- updated builder instance
- See Also:
-
addSecurityLevels
Security levels discovered from endpoint annotations.- Parameters:
securityLevels- security levels- Returns:
- updated builder instance
- See Also:
-
addSecurityLevel
Security levels discovered from endpoint annotations.- Parameters:
securityLevel- add single security levels- Returns:
- updated builder instance
- See Also:
-
addSecurityLevel
Security levels discovered from endpoint annotations.- Parameters:
consumer- consumer of builder for security levels- Returns:
- updated builder instance
- See Also:
-
clearAuthenticator
Clear existing value of authenticator.- Returns:
- updated builder instance
- See Also:
-
authenticator
-
clearInheritedAuthenticator
Whether to clear an authenticator inherited from service defaults.- Parameters:
clearInheritedAuthenticator- whether to clear the inherited authenticator- Returns:
- updated builder instance
- See Also:
-
clearAuthorizer
Clear existing value of authorizer.- Returns:
- updated builder instance
- See Also:
-
authorizer
-
clearInheritedAuthorizer
Whether to clear an authorizer inherited from service defaults.- Parameters:
clearInheritedAuthorizer- whether to clear the inherited authorizer- Returns:
- updated builder instance
- See Also:
-
clearAuthenticate
Clear existing value of authenticate.- Returns:
- updated builder instance
- See Also:
-
authenticate
Whether to authenticate this request.- Parameters:
authenticate- whether to authenticate- Returns:
- updated builder instance
- See Also:
-
clearAuthenticationOptional
Clear existing value of authenticationOptional.- Returns:
- updated builder instance
- See Also:
-
authenticationOptional
Whether authentication failure should continue as anonymous.- Parameters:
authenticationOptional- whether authentication is optional- Returns:
- updated builder instance
- See Also:
-
clearAudit
Clear existing value of audit.- Returns:
- updated builder instance
- See Also:
-
audit
Whether to audit this request.- Parameters:
audit- whether to audit- Returns:
- updated builder instance
- See Also:
-
clearAuthorize
Clear existing value of authorize.- Returns:
- updated builder instance
- See Also:
-
authorize
Whether to authorize this request.- Parameters:
authorize- whether to authorize- Returns:
- updated builder instance
- See Also:
-
clearAuditEventType
Clear existing value of auditEventType.- Returns:
- updated builder instance
- See Also:
-
auditEventType
-
clearAuditMessageFormat
Clear existing value of auditMessageFormat.- Returns:
- updated builder instance
- See Also:
-
auditMessageFormat
-
clearAuditOkSeverity
Clear existing value of auditOkSeverity.- Returns:
- updated builder instance
- See Also:
-
auditOkSeverity
Severity to use for successful requests.- Parameters:
auditOkSeverity- successful request audit severity- Returns:
- updated builder instance
- See Also:
-
clearAuditErrorSeverity
Clear existing value of auditErrorSeverity.- Returns:
- updated builder instance
- See Also:
-
auditErrorSeverity
Severity to use for failed requests.- Parameters:
auditErrorSeverity- failed request audit severity- Returns:
- updated builder instance
- See Also:
-
clearCustomObjects
Clear existing value of customObjects.- Returns:
- updated builder instance
- See Also:
-
customObjects
A store of custom objects, that can be used to customize specific security providers.- Parameters:
customObjects- custom objects- Returns:
- updated builder instance
- See Also:
-
rolesAllowed
-
clearInheritedRolesAllowed
public boolean clearInheritedRolesAllowed()Whether to clear roles inherited from service defaults.- Returns:
- whether to clear inherited roles
-
securityLevels
Security levels discovered from endpoint annotations.- Returns:
- security levels
-
authenticator
-
clearInheritedAuthenticator
public boolean clearInheritedAuthenticator()Whether to clear an authenticator inherited from service defaults.- Returns:
- whether to clear the inherited authenticator
-
authorizer
-
clearInheritedAuthorizer
public boolean clearInheritedAuthorizer()Whether to clear an authorizer inherited from service defaults.- Returns:
- whether to clear the inherited authorizer
-
authenticate
-
authenticationOptional
-
audit
-
authorize
-
auditEventType
-
auditMessageFormat
-
auditOkSeverity
Severity to use for successful requests.- Returns:
- successful request audit severity
-
auditErrorSeverity
Severity to use for failed requests.- Returns:
- failed request audit severity
-
customObjects
A store of custom objects, that can be used to customize specific security providers.- Returns:
- custom objects
-
config
-
toString
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties.
-