Package io.servicetalk.transport.api
Interface ConnectionAcceptor
- All Superinterfaces:
AsyncCloseable
- All Known Subinterfaces:
InfluencerConnectionAcceptor
- All Known Implementing Classes:
DelegatingConnectionAcceptor
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Deprecated.
A contract that defines the connection acceptance criterion.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final ConnectionAcceptor
Deprecated.ACCEPT all connections. -
Method Summary
Modifier and TypeMethodDescriptionaccept
(ConnectionContext context) Deprecated.Evaluate the passedConnectionContext
to accept or reject.default ConnectionAcceptor
append
(ConnectionAcceptor after) Deprecated.Returns a composedConnectionAcceptor
that first appliesthis
ConnectionAcceptor
, and if this is successful then appliesafter
ConnectionAcceptor
.default Completable
Deprecated.Used to close/shutdown a resource.Methods inherited from interface io.servicetalk.concurrent.api.AsyncCloseable
closeAsyncGracefully
-
Field Details
-
ACCEPT_ALL
Deprecated.ACCEPT all connections.
-
-
Method Details
-
accept
Deprecated.Evaluate the passedConnectionContext
to accept or reject. If the returnedCompletable
terminates successfully then the passedConnectionContext
will be accepted, otherwise rejected.- Parameters:
context
- theConnectionContext
to evaluate.- Returns:
Completable
, which when terminated successfully, the passedConnectionContext
is accepted, otherwise rejected.
-
append
Deprecated.Returns a composedConnectionAcceptor
that first appliesthis
ConnectionAcceptor
, and if this is successful then appliesafter
ConnectionAcceptor
.The order of execution of these filters are in order of append. If 3 filters are added as follows:
this.append(filter1).append(filter2).append(filter3)
accepting a connection by a filter wrapped by this filter chain, the order of invocation of these filters will be:this ⇒ filter1 ⇒ filter2 ⇒ filter3
- Parameters:
after
- theConnectionAcceptor
to apply afterthis
ConnectionAcceptor
is applied- Returns:
- a composed
ConnectionAcceptor
that first appliesthis
ConnectionAcceptor
, and if this is successful then appliesafter
ConnectionAcceptor
.
-
closeAsync
Deprecated.Description copied from interface:AsyncCloseable
Used to close/shutdown a resource.- Specified by:
closeAsync
in interfaceAsyncCloseable
- Returns:
- A
Completable
that is notified once the close is complete.
-
LateConnectionAcceptor
instead.