Package mapnik :: Package ogcserver :: Module common :: Class ParameterDefinition

Class ParameterDefinition

Instance Methods
 
__init__(self, mandatory, cast, default=None, allowedvalues=None, fallback=False)
An OGC request parameter definition.
Method Details

__init__(self, mandatory, cast, default=None, allowedvalues=None, fallback=False)
(Constructor)

 

An OGC request parameter definition. Used to describe a parameter's characteristics.

Parameters:
  • mandatory (Boolean.) - Is this parameter required by the request?
  • default (None or any valid value.) - Default value to use if one is not provided and the parameter is optional.
  • allowedvalues (A python tuple of values.) - A list of allowed values for the parameter. If a value is provided that is not in this list, an error is raised.
  • fallback (Boolean.) - Whether the value of the parameter should fall back to the default should an illegal value be provided.
Returns:
A ParameterDefinition instance.