Package com.luciad.ogc.common
Class TLcdServletUtil
java.lang.Object
com.luciad.ogc.common.TLcdServletUtil
Utility functions for servlets.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisKVPRequest(ILcdRequest aRequest) This methods tests whether a request is a KVP based request.static booleanisXMLRequest(ILcdRequest aRequest) This methods tests whether a request is an XML based request.static StringresolveServerURI(ILcdRequest aRequest) Extracts the server URL from the given request, i.e. the servlet URL minus the application (servlet) path itself.static StringresolveServletURI(ILcdRequest aRequest) Extracts the full servlet URL from the given request.
-
Constructor Details
-
TLcdServletUtil
public TLcdServletUtil()
-
-
Method Details
-
isXMLRequest
This methods tests whether a request is an XML based request.The method returns
truewhen the content type starts with one of the following.- text/xml
- application/xml
- application/vnd.ogc.request+xml
- Parameters:
aRequest- the request.- Returns:
trueif the request is recognized as a XML request,falseotherwise.- Since:
- 2017.0
-
isKVPRequest
This methods tests whether a request is a KVP based request.The method returns
truewhen the content type has one of the following values.- application/x-www-form-urlencoded
NULL
- Parameters:
aRequest- the request.- Returns:
trueif the request is recognized as a KVP request,falseotherwise.- Since:
- 2017.0
-
resolveServletURI
Extracts the full servlet URL from the given request.- Parameters:
aRequest- AnILcdRequest.- Returns:
- the extracted servlet URL
-
resolveServerURI
Extracts the server URL from the given request, i.e. the servlet URL minus the application (servlet) path itself.- Parameters:
aRequest- AnILcdRequest.- Returns:
- the extracted server URL
-