Package org.n52.svalbard.encode
Class AbstractSoapEncoder<T,S>
- java.lang.Object
-
- org.n52.svalbard.encode.AbstractDelegatingEncoder<T,S>
-
- org.n52.svalbard.encode.AbstractXmlEncoder<T,S>
-
- org.n52.svalbard.encode.AbstractSoapEncoder<T,S>
-
- All Implemented Interfaces:
Component<EncoderKey>,Keyed<EncoderKey>,Encoder<T,S>,SchemaAwareEncoder<T,S>
- Direct Known Subclasses:
Soap11Encoder,Soap12Encoder
public abstract class AbstractSoapEncoder<T,S> extends AbstractXmlEncoder<T,S>
- Since:
- 1.0.0
-
-
Field Summary
Fields Modifier and Type Field Description static StringDEFAULT_FAULT_REASONstatic StringMISSING_EXCEPTION_DETAIL_TEXTstatic StringMISSING_RESPONSE_DETAIL_TEXT
-
Constructor Summary
Constructors Constructor Description AbstractSoapEncoder(String namespace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tencode(S response)protected org.apache.xmlbeans.XmlObjectgetBodyContent(AbstractSoap<?> soap)Get the content for the SOAPBody asXmlObjectMediaTypegetContentType()protected StringgetExceptionActionURI(ExceptionCode exceptionCode)Get SOAP action URI depending on Exception codeSet<EncoderKey>getKeys()protected StringgetSoapFaultReasonText(ExceptionCode exceptionCode)Get the reason for a SOAP fault from Exception code-
Methods inherited from class org.n52.svalbard.encode.AbstractXmlEncoder
encodeObjectToXml, encodeObjectToXml, encodeObjectToXmlDocument, encodeObjectToXmlDocument, encodeObjectToXmlPropertyType, encodeObjectToXmlPropertyType, encodeObjectToXmlText, encodeObjectToXmlText, getAndCheck, getDocumentEncoder, getDocumentEncoder, getDocumentEncoderKey, getDocumentEncoderKey, getEncoder, getEncoder, getEncoderKey, getEncoderKey, getPropertyTypeEncoder, getPropertyTypeEncoder, getPropertyTypeEncoderKey, getPropertyTypeEncoderKey, getXmlOptions, setXmlOptions, substitute
-
Methods inherited from class org.n52.svalbard.encode.AbstractDelegatingEncoder
getEncoder, getEncoderRepository, setEncoderRepository
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.n52.svalbard.encode.Encoder
encode, getSupportedTypes
-
Methods inherited from interface org.n52.svalbard.encode.SchemaAwareEncoder
addNamespacePrefixToMap, getSchemaLocations
-
-
-
-
Field Detail
-
DEFAULT_FAULT_REASON
public static final String DEFAULT_FAULT_REASON
- See Also:
- Constant Field Values
-
MISSING_RESPONSE_DETAIL_TEXT
public static final String MISSING_RESPONSE_DETAIL_TEXT
- See Also:
- Constant Field Values
-
MISSING_EXCEPTION_DETAIL_TEXT
public static final String MISSING_EXCEPTION_DETAIL_TEXT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
AbstractSoapEncoder
public AbstractSoapEncoder(String namespace)
-
-
Method Detail
-
getKeys
public Set<EncoderKey> getKeys()
-
getContentType
public MediaType getContentType()
- Specified by:
getContentTypein interfaceEncoder<T,S>- Overrides:
getContentTypein classAbstractXmlEncoder<T,S>
-
encode
public T encode(S response) throws EncodingException
- Specified by:
encodein interfaceEncoder<T,S>- Overrides:
encodein classAbstractXmlEncoder<T,S>- Throws:
EncodingException
-
getBodyContent
protected org.apache.xmlbeans.XmlObject getBodyContent(AbstractSoap<?> soap) throws EncodingException
Get the content for the SOAPBody asXmlObject- Parameters:
soap- SOAP response- Returns:
- SOAPBody content as
XmlObject - Throws:
EncodingException- If no encoder is available, the object to encode is not supported or an error occurs during the encoding
-
getExceptionActionURI
protected String getExceptionActionURI(ExceptionCode exceptionCode)
Get SOAP action URI depending on Exception code- Parameters:
exceptionCode- Exception code- Returns:
- SOAP action URI
-
getSoapFaultReasonText
protected String getSoapFaultReasonText(ExceptionCode exceptionCode)
Get the reason for a SOAP fault from Exception code- Parameters:
exceptionCode- OWS exception code to get reason for.- Returns:
- Text for SOAP fault reason
-
-