Class FeatureParameterValidator111
- java.lang.Object
-
- com.supermap.services.wms.request.WMSParameterValidator
-
- com.supermap.services.wms.request.MapParameterValidator111
-
- com.supermap.services.wms.request.FeatureParameterValidator111
-
- All Implemented Interfaces:
- Validator
public class FeatureParameterValidator111 extends MapParameterValidator111
The parameter verifier of the WMS 1.1.1 GetFeatureInfo operation.
-
-
Field Summary
-
Fields inherited from class com.supermap.services.wms.request.WMSParameterValidator
capabilities, EXCEPTION_CODE_INVALIDBBOX, MSG_KEY_INVALIDBBOX, resource, validator
-
-
Constructor Summary
Constructors Constructor and Description FeatureParameterValidator111(WMSCapabilities capabilities)Construct a FeatureParameterValidator111 object according to WMS meta data information.
-
Method Summary
Methods Modifier and Type Method and Description protected OGCParameterExceptioncreateOGCException(ValidateResult checkResult, java.lang.String format)Verify the result and exception format according to the WMS 1.1.1 GetFeatureInfo request parameter, and create the OGCParameterException exception object.protected java.util.Map<java.lang.String,java.util.regex.Pattern>initDefinePattern()Create a regular expression for verifying the parameters of an operation definition.protected java.util.Map<java.lang.String,OptionalParameter>initOptionalPattern()Create the description information of optional parameters.protected java.util.Map<java.lang.String,java.util.regex.Pattern>initRequiredPattern()Create a regular expression for verifying the necessary parameters.voidvalidate(java.util.Map<java.lang.String,java.lang.String> paramMap)Verify the parameter in keyword-value format of the WMS 1.1.1 GetFeatureInfo request.-
Methods inherited from class com.supermap.services.wms.request.MapParameterValidator111
createSRSPattern
-
Methods inherited from class com.supermap.services.wms.request.WMSParameterValidator
createBBOXPattern, createBooleanPattern, createColorPattern, createElevationPattern, createLayerPattern, createPositiveIntegerPattern, createStringArrayPattern, createStylesPattern, createTimePattern, splitString, validateBBOX, validateFormat, validateStyles
-
-
-
-
Constructor Detail
-
FeatureParameterValidator111
public FeatureParameterValidator111(WMSCapabilities capabilities)
Construct a FeatureParameterValidator111 object according to WMS meta data information.
- Parameters:
capabilities- WMS meta information.
-
-
Method Detail
-
initDefinePattern
protected java.util.Map<java.lang.String,java.util.regex.Pattern> initDefinePattern()
Create a regular expression for verifying the parameters of an operation definition.
Verify for the operation definition parameters in
WMSServlet, it returns null.- Overrides:
initDefinePatternin classMapParameterValidator111- Returns:
- returns null.
-
initOptionalPattern
protected java.util.Map<java.lang.String,OptionalParameter> initOptionalPattern()
Create the description information of optional parameters.
It includes the optional parameters like FEATURE_COUNT and INFO_FORMAT besides the contained parameters in
MapParameterValidator111.initOptionalPattern().- Overrides:
initOptionalPatternin classMapParameterValidator111- Returns:
- java.util.Map object, which indicates the name and description of optional parameter, where the key is the parameter name, and the value is the description object (
OptionalParameter).
-
initRequiredPattern
protected java.util.Map<java.lang.String,java.util.regex.Pattern> initRequiredPattern()
Create a regular expression for verifying the necessary parameters.
It includes the parameters like QUERY_LAYERS, X, and Y besides the contained parameters in
MapParameterValidator111.initRequiredPattern().- Overrides:
initRequiredPatternin classMapParameterValidator111- Returns:
- java.util.Map object, which indicates the name and regular expression of the necessary parameter where the key is the parameter name, and the value is the relevant regular expression.
-
validate
public void validate(java.util.Map<java.lang.String,java.lang.String> paramMap) throws OGCParameterExceptionVerify the parameter in keyword-value format of the WMS 1.1.1 GetFeatureInfo request.
- Specified by:
validatein interfaceValidator- Overrides:
validatein classWMSParameterValidator- Parameters:
paramMap- the parameter is a java.util.Map object, the key is the parameter name of the WMS 1.1.1 GetFeatureInfo request, the value is the parameter value.- Throws:
OGCParameterException- parameter exception of OGC service. It occurs exception if the requested parameter is invalid.
-
createOGCException
protected OGCParameterException createOGCException(ValidateResult checkResult, java.lang.String format)
Verify the result and exception format according to the WMS 1.1.1 GetFeatureInfo request parameter, and create the OGCParameterException exception object.
- Overrides:
createOGCExceptionin classMapParameterValidator111- Parameters:
checkResult- WMS the verified result of the request parameter.format- the format of the exception information.- Returns:
- parameter exception of the OGC service.
-
-