Package org.n52.iceland.binding
Class SimpleBinding
java.lang.Object
org.n52.iceland.binding.SimpleBinding
- All Implemented Interfaces:
Binding,EncodingExceptionHandler,Component<BindingKey>,Keyed<BindingKey>
- Direct Known Subclasses:
AbstractXmlBinding,EXIBinding,JSONBinding,KvpBinding
TODO JavaDoc
- Since:
- 1.0.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected MediaTypechooseResponseContentType(OwsServiceResponse response, List<MediaType> acceptHeader, MediaType defaultContentType) protected MediaTypechooseResponseContentTypeForExceptionReport(List<MediaType> acceptHeader, MediaType defaultContentType) protected ObjectencodeOwsExceptionReport(OwsExceptionReport oer, MediaType contentType) protected ObjectencodeResponse(OwsServiceResponse response, MediaType contentType) protected <F,T> Decoder <F, T> getDecoder(DecoderKey key) protected abstract MediaTypeprotected <F,T> Encoder <F, T> getEncoder(EncoderKey key) protected OwsServiceRequestContextgetRequestContext(jakarta.servlet.http.HttpServletRequest req) protected ServiceOperatorprotected ServiceOperatorgetServiceOperator(OwsServiceRequest request) handleEncodingException(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, EncodingException ex) protected booleanhasDecoder(OwsOperationKey key, MediaType mediaType) protected booleanhasDecoder(DecoderKey key) protected booleanhasEncoder(OwsOperationKey key, MediaType mediaType) protected booleanhasEncoder(OwsServiceResponse response, MediaType mediaType) protected booleanhasEncoder(EncoderKey key) protected booleanisServiceSupported(String service) protected abstract booleanprotected booleanisVersionSupported(String service, String acceptVersion) voidsetDecoderRepository(DecoderRepository decoderRepository) voidsetEncoderRepository(EncoderRepository encoderRepository) voidsetEventBus(EventBus eventBus) voidsetHttpUtils(HttpUtils httpUtils) voidprotected voidwriteOwsExceptionReport(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, OwsExceptionReport oer) protected voidwriteResponse(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, OwsServiceResponse serviceResponse) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.n52.iceland.binding.Binding
checkOperationHttpDeleteSupported, checkOperationHttpGetSupported, checkOperationHttpOptionsSupported, checkOperationHttpPostSupported, checkOperationHttpPutSupported, doDeleteOperation, doGetOperation, doOptionsOperation, doPostOperation, doPutOperation
-
Constructor Details
-
SimpleBinding
public SimpleBinding()
-
-
Method Details
-
getHttpUtils
-
setHttpUtils
-
setEventBus
-
getEventBus
-
setServiceOperatorRepository
-
getServiceOperatorRepository
-
setEncoderRepository
-
getEncoderRepository
-
setDecoderRepository
-
getDecoderRepository
-
handleEncodingException
public Object handleEncodingException(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, EncodingException ex) throws HTTPException - Specified by:
handleEncodingExceptionin interfaceEncodingExceptionHandler- Throws:
HTTPException
-
isUseHttpResponseCodes
protected abstract boolean isUseHttpResponseCodes() -
getRequestContext
-
isVersionSupported
-
isServiceSupported
-
getDecoder
-
getEncoder
-
hasDecoder
-
hasDecoder
-
hasEncoder
-
hasEncoder
-
hasEncoder
-
chooseResponseContentType
protected MediaType chooseResponseContentType(OwsServiceResponse response, List<MediaType> acceptHeader, MediaType defaultContentType) throws HTTPException - Throws:
HTTPException
-
chooseResponseContentTypeForExceptionReport
protected MediaType chooseResponseContentTypeForExceptionReport(List<MediaType> acceptHeader, MediaType defaultContentType) throws HTTPException - Throws:
HTTPException
-
getServiceOperator
-
getServiceOperator
- Throws:
OwsExceptionReport
-
checkServiceOperatorKeyTypes
- Throws:
OwsExceptionReport
-
writeResponse
protected void writeResponse(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, OwsServiceResponse serviceResponse) throws HTTPException, IOException - Throws:
HTTPExceptionIOException
-
encodeResponse
protected Object encodeResponse(OwsServiceResponse response, MediaType contentType) throws OwsExceptionReport - Throws:
OwsExceptionReport
-
writeOwsExceptionReport
protected void writeOwsExceptionReport(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, OwsExceptionReport oer) throws HTTPException - Throws:
HTTPException
-
getDefaultContentType
-
encodeOwsExceptionReport
protected Object encodeOwsExceptionReport(OwsExceptionReport oer, MediaType contentType) throws OwsExceptionReport, HTTPException - Throws:
OwsExceptionReportHTTPException
-