Class SokletConfig
java.lang.Object
com.soklet.SokletConfig
Defines how a Soklet system is configured.
Threadsafe instances can be acquired via the withServer(Server) builder factory method.
- Author:
- Mark Allen
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilder used to construct instances ofSokletConfig.static final classBuilder used to copy instances ofSokletConfig. -
Method Summary
Modifier and TypeMethodDescriptioncopy()Vends a mutable copy of this instance's configuration, suitable for building new instances.How Soklet handles Cross-Origin Resource Sharing (CORS).How Soklet will perform instance creation.How Soklet will perform custom behavior during server and request lifecycle events.How Soklet will marshal request bodies to Java types.How Soklet performs Resource Method parameter injection (experts only!)How Soklet performs Resource Method resolution (experts only!)The server managed by Soklet.The SSE server managed by Soklet, if configured.static SokletConfig.BuilderwithServer(Server server) Vends a configuration builder, primed with the givenServer.
-
Method Details
-
withServer
Vends a configuration builder, primed with the givenServer.- Parameters:
server- the server necessary for construction- Returns:
- a builder for
SokletConfiginstances
-
copy
Vends a mutable copy of this instance's configuration, suitable for building new instances.- Returns:
- a mutable copy of this instance's configuration
-
getInstanceProvider
How Soklet will perform instance creation.- Returns:
- the instance responsible for instance creation
-
getValueConverterRegistry
- Returns:
- the instance responsible for value conversions
-
getRequestBodyMarshaler
How Soklet will marshal request bodies to Java types.- Returns:
- the instance responsible for request body marshaling
-
getResourceMethodResolver
How Soklet performs Resource Method resolution (experts only!)- Returns:
- the instance responsible for Resource Method resolution
-
getResourceMethodParameterProvider
How Soklet performs Resource Method parameter injection (experts only!)- Returns:
- the instance responsible for Resource Method parameter injection
-
getResponseMarshaler
- Returns:
- the instance responsible for response body marshaling
-
getLifecycleInterceptor
How Soklet will perform custom behavior during server and request lifecycle events.- Returns:
- the instance responsible for performing lifecycle event customization
-
getCorsAuthorizer
How Soklet handles Cross-Origin Resource Sharing (CORS).- Returns:
- the instance responsible for CORS-related processing
-
getServer
-
getServerSentEventServer
The SSE server managed by Soklet, if configured.- Returns:
- the SSE server instance, or
Optional.empty()is none was configured
-