public class RestEncoder extends Object implements Encoder<ServiceResponse,RestResponse>
Modifier and Type | Field and Description |
---|---|
protected Constants |
bindingConstants |
private Set<EncoderKey> |
ENCODER_KEYS |
private static org.slf4j.Logger |
LOGGER |
Constructor and Description |
---|
RestEncoder() |
Modifier and Type | Method and Description |
---|---|
void |
addNamespacePrefixToMap(Map<String,String> nameSpacePrefixMap)
|
ServiceResponse |
encode(RestResponse restResponse)
Encodes the specified object.
|
ServiceResponse |
encode(RestResponse objectToEncode,
Map<SosConstants.HelperValues,String> iGNOREDadditionalValues)
Encodes the specified object with the specified SosConstants.HelperValues
.
|
Set<String> |
getConformanceClasses() |
MediaType |
getContentType() |
Set<EncoderKey> |
getEncoderKeyType() |
private ResourceEncoder |
getRestEncoderForBindingResponse(RestResponse restResponse) |
Set<SchemaLocation> |
getSchemaLocations() |
Map<ServiceConstants.SupportedTypeKey,Set<String>> |
getSupportedTypes()
|
protected boolean |
isFeatureResponse(RestResponse restResponse) |
private boolean |
isObservationsGetResponse(RestResponse restResponse) |
private boolean |
isOfferingsGetResponse(RestResponse restResponse) |
private boolean |
isSensorsGetResponse(RestResponse restResponse) |
protected Constants bindingConstants
private static final org.slf4j.Logger LOGGER
private final Set<EncoderKey> ENCODER_KEYS
public ServiceResponse encode(RestResponse restResponse) throws OwsExceptionReport
Encoder
encode
in interface Encoder<ServiceResponse,RestResponse>
restResponse
- the object to encodeOwsExceptionReport
- if an error occursUnsupportedEncoderInputException
- if the supplied object (or any of it's contents) is not
supported by this encoderprivate ResourceEncoder getRestEncoderForBindingResponse(RestResponse restResponse) throws OwsExceptionReport
OwsExceptionReport
protected boolean isFeatureResponse(RestResponse restResponse)
private boolean isObservationsGetResponse(RestResponse restResponse)
private boolean isSensorsGetResponse(RestResponse restResponse)
private boolean isOfferingsGetResponse(RestResponse restResponse)
public ServiceResponse encode(RestResponse objectToEncode, Map<SosConstants.HelperValues,String> iGNOREDadditionalValues) throws OwsExceptionReport
Encoder
encode
in interface Encoder<ServiceResponse,RestResponse>
objectToEncode
- the object to encodeiGNOREDadditionalValues
- the helper valuesOwsExceptionReport
- if an error occursUnsupportedEncoderInputException
- if the supplied object (or any of it's contents) is not
supported by this encoderpublic Set<String> getConformanceClasses()
getConformanceClasses
in interface ConformanceClass
public Set<EncoderKey> getEncoderKeyType()
getEncoderKeyType
in interface Encoder<ServiceResponse,RestResponse>
EncoderKey
)public void addNamespacePrefixToMap(Map<String,String> nameSpacePrefixMap)
Encoder
addNamespacePrefixToMap
in interface Encoder<ServiceResponse,RestResponse>
public Map<ServiceConstants.SupportedTypeKey,Set<String>> getSupportedTypes()
Encoder
getSupportedTypes
in interface Encoder<ServiceResponse,RestResponse>
public MediaType getContentType()
getContentType
in interface Encoder<ServiceResponse,RestResponse>
public Set<SchemaLocation> getSchemaLocations()
getSchemaLocations
in interface Encoder<ServiceResponse,RestResponse>
Copyright © 2012-2015 52north.org. All Rights Reserved.