Package org.ldaptive.transport
Class MessageFunctional<Q extends Request,S extends Result>
- java.lang.Object
-
- org.ldaptive.AbstractFreezable
-
- org.ldaptive.transport.MessageFunctional<Q,S>
-
- Type Parameters:
Q
- type of requestS
- type of result
- All Implemented Interfaces:
Freezable
- Direct Known Subclasses:
MessageFunctional.BiConsumer
,MessageFunctional.Consumer
,MessageFunctional.Function
public abstract class MessageFunctional<Q extends Request,S extends Result> extends AbstractFreezable
Base class for processing a message that is initialized with properties from the handle.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
MessageFunctional.BiConsumer<Q extends Request,S extends Result,T,U>
Marker class to inject handle properties.static class
MessageFunctional.Consumer<Q extends Request,S extends Result,T>
Marker class to inject handle properties.static class
MessageFunctional.Function<Q extends Request,S extends Result,T,R>
Marker class to inject handle properties.
-
Field Summary
Fields Modifier and Type Field Description private Connection
connection
Connection the request occurred on.private OperationHandle<Q,S>
handle
Operation handle that sent the request.private Q
request
Request that produced the message.
-
Constructor Summary
Constructors Constructor Description MessageFunctional()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Connection
getConnection()
OperationHandle<Q,S>
getHandle()
Q
getRequest()
abstract MessageFunctional<Q,S>
newInstance()
Create a new instance of this message functional.void
setConnection(Connection conn)
void
setHandle(OperationHandle<Q,S> h)
void
setRequest(Q req)
-
Methods inherited from class org.ldaptive.AbstractFreezable
assertMutable, freeze, freeze, freeze, isFrozen
-
-
-
-
Field Detail
-
connection
private Connection connection
Connection the request occurred on.
-
handle
private OperationHandle<Q extends Request,S extends Result> handle
Operation handle that sent the request.
-
-
Method Detail
-
getConnection
public Connection getConnection()
-
setConnection
public void setConnection(Connection conn)
-
getRequest
public Q getRequest()
-
setRequest
public void setRequest(Q req)
-
getHandle
public OperationHandle<Q,S> getHandle()
-
setHandle
public void setHandle(OperationHandle<Q,S> h)
-
newInstance
public abstract MessageFunctional<Q,S> newInstance()
Create a new instance of this message functional.- Returns:
- new instance of this message functional
-
-