AbstractBootstrap is a helper class that makes it easy to bootstrap a Channel. It support
method-chaining to provide an easy way to configure the AbstractBootstrap.
When not used in a ServerBootstrap context, the bind() methods are useful for connectionless
transports such as datagram (UDP).
| Modifier and Type | Class and Description |
|---|---|
| pack-priv static class |
| Modifier and Type | Field and Description |
|---|---|
| private final Map | |
| private volatile ChannelFactory | channelFactory
Deprecated
as a consequence of
ChannelFactory being deprecated.
|
| private static final Map. | |
| private static final Map. | |
| private volatile ClassLoader | |
| pack-priv volatile EventLoopGroup | |
| private volatile ChannelHandler | |
| private volatile SocketAddress | |
| private final Map |
| Access | Constructor and Description |
|---|---|
| pack-priv | |
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public <T> B | attr(AttributeKey<T> key, T value)
Allow to specify an initial attribute of the newly created |
| pack-priv final Map | |
| pack-priv final Map | |
| public ChannelFuture | |
| public ChannelFuture | |
| public ChannelFuture | |
| public ChannelFuture | |
| public ChannelFuture | |
| public B | |
| public B | channelFactory(ChannelFactory<? extends C> channelFactory)
Deprecated
Use
channelFactory(io. instead.
|
| public B | channelFactory(ChannelFactory<? extends C> channelFactory)
Deprecated
as a consequence of
ChannelFactory being deprecated.
io. which is used to create Channel instances from
when calling bind().
|
| pack-priv final ChannelFactory | |
| public abstract B | clone()
Overrides java. |
| public abstract AbstractBootstrapConfig | config()
Returns the |
| pack-priv static <K, V> Map | |
| private ChannelFuture | |
| private static void | doBind0(final ChannelFuture regFuture, final Channel channel, final SocketAddress localAddress, final ChannelPromise promise)
|
| public B | Returns: This bootstrap.The class loader to use for loading classLoader)ChannelInitializerExtensions.Load |
| pack-priv Collection | |
| public B | group(EventLoopGroup group)
The |
| public final EventLoopGroup | group()
Deprecated
Use
Returns the configured config() instead.
EventLoopGroup or null if non is configured yet.
|
| public B | |
| pack-priv final ChannelHandler | |
| pack-priv abstract void | |
| pack-priv final ChannelFuture | |
| public B | |
| public B | |
| public B | |
| public B | |
| pack-priv final SocketAddress | |
| pack-priv final Map. | |
| pack-priv static Map. | |
| pack-priv final Map. | |
| pack-priv static Map. | |
| public <T> B | option(ChannelOption<T> option, T value)
Allow to specify a |
| pack-priv final Map | |
| pack-priv final Map | |
| public ChannelFuture | |
| private B | |
| pack-priv static void | |
| private static void | |
| pack-priv static void | setChannelOptions(Channel channel, Map.
|
| public String | |
| public B |
| attrs | back to summary |
|---|---|
| private final Map<AttributeKey<?>, Object> attrs | |
| channelFactory | back to summary |
|---|---|
| private volatile ChannelFactory<? extends C> channelFactory
Deprecated as a consequence of
| |
| EMPTY_ATTRIBUTE_ARRAY | back to summary |
|---|---|
private static final Map.
| |
| EMPTY_OPTION_ARRAY | back to summary |
|---|---|
private static final Map.
| |
| extensionsClassLoader | back to summary |
|---|---|
| private volatile ClassLoader extensionsClassLoader | |
| group | back to summary |
|---|---|
| pack-priv volatile EventLoopGroup group | |
| handler | back to summary |
|---|---|
| private volatile ChannelHandler handler | |
| localAddress | back to summary |
|---|---|
| private volatile SocketAddress localAddress | |
| options | back to summary |
|---|---|
| private final Map<ChannelOption<?>, Object> options | |
| AbstractBootstrap | back to summary |
|---|---|
| pack-priv AbstractBootstrap() | |
| AbstractBootstrap | back to summary |
|---|---|
| pack-priv AbstractBootstrap(AbstractBootstrap<B, C> bootstrap) | |
| attr | back to summary |
|---|---|
| public <T> B attr(AttributeKey<T> key, T value) Allow to specify an initial attribute of the newly created | |
| attrs | back to summary |
|---|---|
| pack-priv final Map | |
| attrs0 | back to summary |
|---|---|
| pack-priv final Map | |
| bind | back to summary |
|---|---|
| public ChannelFuture bind() Create a new | |
| bind | back to summary |
|---|---|
| public ChannelFuture bind(int inetPort) Create a new | |
| bind | back to summary |
|---|---|
| public ChannelFuture bind(String inetHost, int inetPort) Create a new | |
| bind | back to summary |
|---|---|
| public ChannelFuture bind(InetAddress inetHost, int inetPort) Create a new | |
| bind | back to summary |
|---|---|
| public ChannelFuture bind(SocketAddress localAddress) Create a new | |
| channel | back to summary |
|---|---|
| public B channel(Class<? extends C> channelClass) The | |
| channelFactory | back to summary |
|---|---|
| public B channelFactory(ChannelFactory<? extends C> channelFactory)
Deprecated Use
| |
| channelFactory | back to summary |
|---|---|
| public B channelFactory(ChannelFactory<? extends C> channelFactory)
Deprecated as a consequence of
| |
| channelFactory | back to summary |
|---|---|
| pack-priv final ChannelFactory Deprecated as a consequence of
| |
| clone | back to summary |
|---|---|
| public abstract B clone() Overrides java. Returns a deep clone of this bootstrap which has the identical configuration. This method is useful when making
multiple
| |
| config | back to summary |
|---|---|
| public abstract AbstractBootstrapConfig Returns the | |
| copiedMap | back to summary |
|---|---|
| pack-priv static <K, V> Map | |
| doBind | back to summary |
|---|---|
| private ChannelFuture doBind(final SocketAddress localAddress) | |
| doBind0 | back to summary |
|---|---|
| private static void doBind0(final ChannelFuture regFuture, final Channel channel, final SocketAddress localAddress, final ChannelPromise promise) | |
| extensionsClassLoader | back to summary |
|---|---|
| public B extensionsClassLoader(ClassLoader classLoader) Load By default, the extensions will be loaded by the same class loader that loaded this bootstrap class.
| |
| getInitializerExtensions | back to summary |
|---|---|
| pack-priv Collection | |
| group | back to summary |
|---|---|
| public B group(EventLoopGroup group) The | |
| group | back to summary |
|---|---|
| public final EventLoopGroup group()
Deprecated Use Returns the configured
| |
| handler | back to summary |
|---|---|
| public B handler(ChannelHandler handler) the | |
| handler | back to summary |
|---|---|
| pack-priv final ChannelHandler handler() | |
| init | back to summary |
|---|---|
| pack-priv abstract void init(Channel channel) throws Exception | |
| initAndRegister | back to summary |
|---|---|
| pack-priv final ChannelFuture initAndRegister() | |
| localAddress | back to summary |
|---|---|
| public B localAddress(SocketAddress localAddress) The | |
| localAddress | back to summary |
|---|---|
public B localAddress(int inetPort)
| |
| localAddress | back to summary |
|---|---|
public B localAddress(String inetHost, int inetPort)
| |
| localAddress | back to summary |
|---|---|
public B localAddress(InetAddress inetHost, int inetPort)
| |
| localAddress | back to summary |
|---|---|
| pack-priv final SocketAddress localAddress() | |
| newAttributesArray | back to summary |
|---|---|
| pack-priv final Map. | |
| newAttributesArray | back to summary |
|---|---|
| pack-priv static Map. | |
| newOptionsArray | back to summary |
|---|---|
| pack-priv final Map. | |
| newOptionsArray | back to summary |
|---|---|
| pack-priv static Map. | |
| option | back to summary |
|---|---|
| public <T> B option(ChannelOption<T> option, T value) Allow to specify a | |
| options | back to summary |
|---|---|
| pack-priv final Map | |
| options0 | back to summary |
|---|---|
| pack-priv final Map | |
| register | back to summary |
|---|---|
| public ChannelFuture register() | |
| self | back to summary |
|---|---|
private B self()
| |
| setAttributes | back to summary |
|---|---|
| pack-priv static void setAttributes(Channel channel, Map. | |
| setChannelOption | back to summary |
|---|---|
private static void setChannelOption(Channel channel, ChannelOption<?> option, Object value, InternalLogger logger)
| |
| setChannelOptions | back to summary |
|---|---|
| pack-priv static void setChannelOptions(Channel channel, Map. | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object. | |
| validate | back to summary |
|---|---|
| public B validate() Validate all the parameters. Sub-classes may override this, but should call the super method in that case. | |
| Modifier and Type | Field and Description |
|---|---|
| private volatile boolean |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| protected EventExecutor | executor()
Get the executor used to notify listeners when this promise is complete.
|
| pack-priv void |
| registered | back to summary |
|---|---|
| private volatile boolean registered | |
| PendingRegistrationPromise | back to summary |
|---|---|
| pack-priv PendingRegistrationPromise(Channel channel) | |
| executor | back to summary |
|---|---|
| protected EventExecutor executor() Overrides io. Doc from io. Get the executor used to notify listeners when this promise is complete.
It is assumed this executor will protect against
| |
| registered | back to summary |
|---|---|
| pack-priv void registered() | |