Package com.luciad.ogc.common
Class TLcdServletUtil
java.lang.Object
com.luciad.ogc.common.TLcdServletUtil
Utility functions for servlets.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
isKVPRequest
(ILcdRequest aRequest) This methods tests whether a request is a KVP based request.static boolean
isXMLRequest
(ILcdRequest aRequest) This methods tests whether a request is an XML based request.static String
resolveServerURI
(ILcdRequest aRequest) Extracts the server URL from the given request, i.e. the servlet URL minus the application (servlet) path itself.static String
resolveServletURI
(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
true
when the content type starts with one of the following.- text/xml
- application/xml
- application/vnd.ogc.request+xml
- Parameters:
aRequest
- the request.- Returns:
true
if the request is recognized as a XML request,false
otherwise.- Since:
- 2017.0
-
isKVPRequest
This methods tests whether a request is a KVP based request.The method returns
true
when the content type has one of the following values.- application/x-www-form-urlencoded
NULL
- Parameters:
aRequest
- the request.- Returns:
true
if the request is recognized as a KVP request,false
otherwise.- 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
-