Package org.serviceconnector.net.req
Class RequestAdapter
java.lang.Object
org.serviceconnector.net.req.RequestAdapter
- All Implemented Interfaces:
IRequest
- Direct Known Subclasses:
NettyHttpRequest,NettyTcpRequest
The Class RequestAdapter. Provides basic functionality for requests.
- Author:
- JTraber
-
Constructor Summary
ConstructorsConstructorDescriptionRequestAdapter(InetSocketAddress localAddress, InetSocketAddress remoteAddress) Instantiates a new request adapter. -
Method Summary
Modifier and TypeMethodDescriptiongetKey()Gets the message type.Gets the socket address.Gets the message.Gets the remote socket address.voidsetMessage(SCMPMessage message) Sets the scmp message in the request.
-
Constructor Details
-
RequestAdapter
Instantiates a new request adapter.- Parameters:
localAddress- the local addressremoteAddress- the remote address
-
-
Method Details
-
getMessage
Gets the message.- Specified by:
getMessagein interfaceIRequest- Returns:
- the message
-
setMessage
Sets the scmp message in the request.- Specified by:
setMessagein interfaceIRequest- Parameters:
message- the new scmp message
-
getLocalSocketAddress
Gets the socket address.- Specified by:
getLocalSocketAddressin interfaceIRequest- Returns:
- the socket address
-
getRemoteSocketAddress
Gets the remote socket address.- Specified by:
getRemoteSocketAddressin interfaceIRequest- Returns:
- the remote socket address
-
getKey
Gets the message type.
-