public static interface SocketBindingManager.NamedManagedBindingRegistry extends ManagedBindingRegistry
Modifier and Type | Method and Description |
---|---|
ManagedBinding |
getManagedBinding(String name)
Gets the binding registered under the given name.
|
boolean |
isRegistered(String name)
Gets whether there is a binding registered under the given name.
|
void |
registerBinding(ManagedBinding binding)
Register a managed binding.
|
Closeable |
registerChannel(String name,
DatagramChannel channel)
Registers a binding under the given name based on the given channel.
|
Closeable |
registerChannel(String name,
ServerSocketChannel channel)
Registers a binding under the given name based on the given channel.
|
Closeable |
registerChannel(String name,
SocketChannel channel)
Registers a binding under the given name based on the given channel.
|
Closeable |
registerSocket(String name,
DatagramSocket socket)
Registers a binding under the given name based on the given socket.
|
Closeable |
registerSocket(String name,
ServerSocket socket)
Registers a binding under the given name based on the given socket.
|
Closeable |
registerSocket(String name,
Socket socket)
Registers a binding under the given name based on the given socket.
|
void |
unregisterBinding(ManagedBinding binding)
Unregister a managed binding.
|
void |
unregisterBinding(String name)
Unregisters the binding with the given name.
|
listActiveBindings
ManagedBinding getManagedBinding(String name)
name
- the namenull
if there is no binding registered with that nameboolean isRegistered(String name)
name
- the nametrue
if there is a binding under that nameCloseable registerSocket(String name, Socket socket)
name
- the name. Cannot be null
socket
- the socket. Cannot be null
Closeable
that will unregister the binding if close()
is calledCloseable registerSocket(String name, ServerSocket socket)
name
- the name. Cannot be null
socket
- the socket. Cannot be null
Closeable
that will unregister the binding if close()
is calledCloseable registerSocket(String name, DatagramSocket socket)
name
- the name. Cannot be null
socket
- the socket. Cannot be null
Closeable
that will unregister the binding if close()
is calledCloseable registerChannel(String name, SocketChannel channel)
name
- the name. Cannot be null
channel
- the channel. Cannot be null
Closeable
that will unregister the binding if close()
is calledCloseable registerChannel(String name, ServerSocketChannel channel)
name
- the name. Cannot be null
channel
- the channel. Cannot be null
Closeable
that will unregister the binding if close()
is calledCloseable registerChannel(String name, DatagramChannel channel)
name
- the name. Cannot be null
channel
- the channel. Cannot be null
Closeable
that will unregister the binding if close()
is calledvoid unregisterBinding(String name)
name
- the namevoid registerBinding(ManagedBinding binding)
registerBinding
in interface ManagedBindingRegistry
binding
- the managed bindingIllegalStateException
- if ManagedBinding.getSocketBindingName()
returns null
void unregisterBinding(ManagedBinding binding)
unregisterBinding
in interface ManagedBindingRegistry
binding
- the managed bindingIllegalStateException
- if ManagedBinding.getSocketBindingName()
returns null
Copyright © 2023 JBoss by Red Hat. All rights reserved.