Package org.refcodes.rest
Class RestResponseImpl
- java.lang.Object
-
- org.refcodes.net.HttpResponseImpl
-
- org.refcodes.net.HttpClientResponseImpl
-
- org.refcodes.rest.RestResponseImpl
-
- All Implemented Interfaces:
org.refcodes.mixin.Dumpable
,org.refcodes.net.HeaderFieldsAccessor<org.refcodes.net.ResponseHeaderFields>
,org.refcodes.net.HttpBodyAccessor
,org.refcodes.net.HttpClientResponse
,org.refcodes.net.HttpInputStreamAccessor
,org.refcodes.net.HttpResponse
,org.refcodes.net.HttpStatusCodeAccessor
,org.refcodes.net.LocalAddressAccessor
,org.refcodes.net.RemoteAddressAccessor
,RestResponse
- Direct Known Subclasses:
RestResponseEventImpl
public class RestResponseImpl extends org.refcodes.net.HttpClientResponseImpl implements RestResponse
Implementation of theRestResponseEvent
interface as good old POJO for use by differentRestClient
implementations.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.refcodes.net.HeaderFieldsAccessor
org.refcodes.net.HeaderFieldsAccessor.HeaderFieldsBuilder<T extends org.refcodes.net.HeaderFields<?,?>,B extends org.refcodes.net.HeaderFieldsAccessor.HeaderFieldsBuilder<T,B>>, org.refcodes.net.HeaderFieldsAccessor.HeaderFieldsMutator<T extends org.refcodes.net.HeaderFields<?,?>>, org.refcodes.net.HeaderFieldsAccessor.HeaderFieldsProperty<T extends org.refcodes.net.HeaderFields<?,?>>
-
Nested classes/interfaces inherited from interface org.refcodes.net.HttpBodyAccessor
org.refcodes.net.HttpBodyAccessor.HttpBodyBuilder<B extends org.refcodes.net.HttpBodyAccessor.HttpBodyBuilder<B>>, org.refcodes.net.HttpBodyAccessor.HttpBodyMutator, org.refcodes.net.HttpBodyAccessor.HttpBodyProperty, org.refcodes.net.HttpBodyAccessor.HttpBodyProvider<EXC extends java.lang.Exception>
-
Nested classes/interfaces inherited from interface org.refcodes.net.HttpInputStreamAccessor
org.refcodes.net.HttpInputStreamAccessor.HttpInputStreamBuilder<B extends org.refcodes.net.HttpInputStreamAccessor.HttpInputStreamBuilder<B>>, org.refcodes.net.HttpInputStreamAccessor.HttpInputStreamMutator, org.refcodes.net.HttpInputStreamAccessor.HttpInputStreamProperty, org.refcodes.net.HttpInputStreamAccessor.HttpInputStreamProvider<EXC extends java.lang.Exception>
-
Nested classes/interfaces inherited from interface org.refcodes.net.HttpStatusCodeAccessor
org.refcodes.net.HttpStatusCodeAccessor.HttpStatusCodeBuilder<B extends org.refcodes.net.HttpStatusCodeAccessor.HttpStatusCodeBuilder<B>>, org.refcodes.net.HttpStatusCodeAccessor.HttpStatusCodeMutator, org.refcodes.net.HttpStatusCodeAccessor.HttpStatusCodeProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.LocalAddressAccessor
org.refcodes.net.LocalAddressAccessor.LocalAddressBuilder<B extends org.refcodes.net.LocalAddressAccessor.LocalAddressBuilder<B>>, org.refcodes.net.LocalAddressAccessor.LocalAddressMutator, org.refcodes.net.LocalAddressAccessor.LocalAddressProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.RemoteAddressAccessor
org.refcodes.net.RemoteAddressAccessor.RemoteAddressBuilder<B extends org.refcodes.net.RemoteAddressAccessor.RemoteAddressBuilder<B>>, org.refcodes.net.RemoteAddressAccessor.RemoteAddressMutator, org.refcodes.net.RemoteAddressAccessor.RemoteAddressProperty
-
-
Constructor Summary
Constructors Constructor Description RestResponseImpl(java.net.InetSocketAddress aLocalAddress, java.net.InetSocketAddress aRemoteAddress, org.refcodes.net.HttpStatusCode aHttpStatusCode, org.refcodes.net.ResponseHeaderFields aHeaderFields, java.io.InputStream aHttpInputStream, org.refcodes.net.MediaTypeFactoryLookup aMediaTypeFactoryLookup)
Constructs aRestResponseEvent
with all required attributes.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.net.InetSocketAddress
getLocalAddress()
java.net.InetSocketAddress
getRemoteAddress()
-
-
-
Constructor Detail
-
RestResponseImpl
public RestResponseImpl(java.net.InetSocketAddress aLocalAddress, java.net.InetSocketAddress aRemoteAddress, org.refcodes.net.HttpStatusCode aHttpStatusCode, org.refcodes.net.ResponseHeaderFields aHeaderFields, java.io.InputStream aHttpInputStream, org.refcodes.net.MediaTypeFactoryLookup aMediaTypeFactoryLookup)
Constructs aRestResponseEvent
with all required attributes.- Parameters:
aLocalAddress
- The local address where the event is being received.aRemoteAddress
- The remote address from which the request originates.aHttpStatusCode
- TheHttpStatusCode
of the response.aHeaderFields
- TheResponseHeaderFields
sent by the response.aHttpInputStream
- TheInputStream
representing the request's HTTP body.aMediaTypeFactoryLookup
- The system firing the event.
-
-
Method Detail
-
getRemoteAddress
public java.net.InetSocketAddress getRemoteAddress()
- Specified by:
getRemoteAddress
in interfaceorg.refcodes.net.RemoteAddressAccessor
-
getLocalAddress
public java.net.InetSocketAddress getLocalAddress()
- Specified by:
getLocalAddress
in interfaceorg.refcodes.net.LocalAddressAccessor
-
-