public abstract class AbstractObservationResponseEncoder<T extends AbstractObservationResponse> extends AbstractSosResponseEncoder<T>
Constructor and Description |
---|
AbstractObservationResponseEncoder(String operation,
Class<T> responseType) |
Modifier and Type | Method and Description |
---|---|
protected org.apache.xmlbeans.XmlObject |
create(T response)
Create an
XmlObject from the AbstractServiceResponse
object |
protected void |
create(T response,
OutputStream outputStream,
EncodingValues encodingValues)
Override this method in concrete response encoder if streaming is
supported for this operations.
|
protected abstract org.apache.xmlbeans.XmlObject |
createResponse(ObservationEncoder<org.apache.xmlbeans.XmlObject,OmObservation> encoder,
T response)
Create a response using the provided O&M2 compatible observation encoder.
|
protected void |
createResponse(ObservationEncoder<org.apache.xmlbeans.XmlObject,OmObservation> encoder,
T response,
OutputStream outputStream,
EncodingValues encodingValues)
Override this method in concrete response encoder if streaming is
supported for this operations.
|
private ObservationEncoder<org.apache.xmlbeans.XmlObject,OmObservation> |
findObservationEncoder(String responseFormat)
Finds a O&Mv2 compatible
ObservationEncoder |
private Encoder<org.apache.xmlbeans.XmlObject,T> |
findResponseEncoder(String responseFormat)
Finds a compatible response encoder to delegate to.
|
encodeFes, encodeFes, encodeGml, encodeGml, encodeOws, encodeOws, encodeSwe, encodeSwe, getActiveProfile, getSchemaLocations
addNamespacePrefixToMap, encode, encode, encode, encode, forceStreaming, getConcreteSchemaLocations, getEncoderKeyType, getResponseType, getXmlOptions, writeIndent
getConformanceClasses, getContentType, getSupportedTypes
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getContentType, getSupportedTypes
getConformanceClasses
private ObservationEncoder<org.apache.xmlbeans.XmlObject,OmObservation> findObservationEncoder(String responseFormat) throws OwsExceptionReport
ObservationEncoder
responseFormat
- the response formatnull
if none is foundOwsExceptionReport
- if the found encoder is not a ObservationEncoderprivate Encoder<org.apache.xmlbeans.XmlObject,T> findResponseEncoder(String responseFormat)
responseFormat
- the response formatnull
if no encoder was foundprotected org.apache.xmlbeans.XmlObject create(T response) throws OwsExceptionReport
AbstractResponseEncoder
XmlObject
from the AbstractServiceResponse
objectcreate
in class AbstractResponseEncoder<T extends AbstractObservationResponse>
response
- AbstractServiceResponse
to encodeAbstractServiceResponse
OwsExceptionReport
- If an error occurs during the encodingprotected void create(T response, OutputStream outputStream, EncodingValues encodingValues) throws OwsExceptionReport
AbstractResponseEncoder
create
in class AbstractResponseEncoder<T extends AbstractObservationResponse>
response
- Implementation of AbstractServiceResponse
outputStream
- OutputStream
to writeencodingValues
- EncodingValues
with additional indicators for encodingOwsExceptionReport
- If an error occurs during encoding/writing to streamprotected abstract org.apache.xmlbeans.XmlObject createResponse(ObservationEncoder<org.apache.xmlbeans.XmlObject,OmObservation> encoder, T response) throws OwsExceptionReport
encoder
- the encoderresponse
- the responseOwsExceptionReport
- if an error occursprotected void createResponse(ObservationEncoder<org.apache.xmlbeans.XmlObject,OmObservation> encoder, T response, OutputStream outputStream, EncodingValues encodingValues) throws OwsExceptionReport
encoder
- response
- outputStream
- encodingValues
- OwsExceptionReport
Copyright © 2012-2015 52north.org. All Rights Reserved.