Class SocketOptions.Builder
java.lang.Object
io.helidon.common.socket.SocketOptions.BuilderBase<SocketOptions.Builder, SocketOptions>
io.helidon.common.socket.SocketOptions.Builder
- All Implemented Interfaces:
Prototype.Builder<SocketOptions.Builder, SocketOptions>, Builder<SocketOptions.Builder, SocketOptions>, ConfigBuilderSupport.ConfiguredBuilder<SocketOptions.Builder, SocketOptions>, Supplier<SocketOptions>
- Enclosing interface:
SocketOptions
public static class SocketOptions.Builder
extends SocketOptions.BuilderBase<SocketOptions.Builder, SocketOptions>
implements Builder<SocketOptions.Builder, SocketOptions>
Fluent API builder for
SocketOptions.-
Nested Class Summary
Nested classes/interfaces inherited from class SocketOptions.BuilderBase
SocketOptions.BuilderBase.SocketOptionsImplModifier and TypeClassDescriptionprotected static classGenerated implementation of the prototype, can be extended by descendant prototype implementations. -
Method Summary
Modifier and TypeMethodDescriptionbuild()Create an instance from this builder.Create an instance of the prototype.Methods inherited from class SocketOptions.BuilderBase
addSocketOptions, clearSocketReceiveBufferSize, clearSocketSendBufferSize, config, config, connectTimeout, connectTimeout, from, from, preBuildPrototype, putSocketOption, readTimeout, readTimeout, socketKeepAlive, socketKeepAlive, socketOptions, socketOptions, socketReceiveBufferSize, socketReceiveBufferSize, socketReuseAddress, socketReuseAddress, socketSendBufferSize, socketSendBufferSize, tcpNoDelay, tcpNoDelay, toString, validatePrototypeModifier and TypeMethodDescriptionaddSocketOptions(Map<SocketOption<?>, ?> socketOptions) Arbitrary socket options.Clear existing value of socketReceiveBufferSize.Clear existing value of socketSendBufferSize.config()Configuration used to configure this instance.Update builder from configuration (node of this type).Socket connect timeout.connectTimeout(Duration connectTimeout) Socket connect timeout.from(SocketOptions prototype) Update this builder from an existing prototype instance.from(SocketOptions.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.protected voidHandles providers and decorators.<TYPE> SocketOptions.BuilderputSocketOption(SocketOption<TYPE> key, TYPE socketOption) Arbitrary socket options.Socket read timeout.readTimeout(Duration readTimeout) Socket read timeout.booleanConfigure socket keep alive.socketKeepAlive(boolean socketKeepAlive) Configure socket keep alive.Map<SocketOption<?>, Object> Arbitrary socket options.socketOptions(Map<SocketOption<?>, ?> socketOptions) Arbitrary socket options.Socket receive buffer size.socketReceiveBufferSize(int socketReceiveBufferSize) Socket receive buffer size.booleanSocket reuse address.socketReuseAddress(boolean socketReuseAddress) Socket reuse address.Socket send buffer size.socketSendBufferSize(int socketSendBufferSize) Socket send buffer size.booleanThis option may improve performance on some systems.tcpNoDelay(boolean tcpNoDelay) This option may improve performance on some systems.toString()protected voidValidates required properties.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface Builder
get, identity, updateModifier and TypeMethodDescriptiondefault SocketOptionsget()default SocketOptions.Builderidentity()Instance of this builder as the correct type.default SocketOptions.Builderupdate(Consumer<SocketOptions.Builder> consumer) Update the builder in a fluent API way.Methods inherited from interface Prototype.Builder
selfModifier and TypeMethodDescriptiondefault SocketOptions.Builderself()Instance of this builder as the correct type.
-
Method Details
-
buildPrototype
Create an instance of the prototype. Calling this method may update this builder from providers and decorators, so repeated calls may have side effects.- Specified by:
buildPrototypein interfacePrototype.Builder<SocketOptions.Builder, SocketOptions>- Returns:
- an instance of the setup object created from this builder
-
build
Create an instance from this builder. Calling this method may update this builder from providers and decorators, so repeated calls may have side effects.- Specified by:
buildin interfaceBuilder<SocketOptions.Builder, SocketOptions>- Returns:
- instance of the built type
-