eoxserver.services.ows.wps.parameters package¶
Submodules¶
eoxserver.services.ows.wps.parameters.allowed_values module¶
- class eoxserver.services.ows.wps.parameters.allowed_values.AllowedAny¶
Bases:
BaseAllowed
Allowed values class allowing any value.
- check(value)¶
check validity
- verify(value)¶
Verify the value.
- class eoxserver.services.ows.wps.parameters.allowed_values.AllowedByReference(url)¶
Bases:
BaseAllowed
Allowed values class defined by a reference.
NOTE: As it is not how such a reference definition looks like this class has the same behaviour as the AllowedAny class.
- check(value)¶
check validity
- property url¶
Get the URL of the reference.
- verify(value)¶
Verify the value.
- class eoxserver.services.ows.wps.parameters.allowed_values.AllowedEnum(values, dtype=<class 'eoxserver.services.ows.wps.parameters.data_types.Double'>)¶
Bases:
BaseAllowed
,TypedMixIn
Allowed values class allowing values from an enumerated set.
- check(value)¶
check validity
- property values¶
Get the allowed values.
- verify(value)¶
Verify the value.
- class eoxserver.services.ows.wps.parameters.allowed_values.AllowedRange(minval, maxval, closure='closed', spacing=None, spacing_rtol=1e-09, dtype=<class 'eoxserver.services.ows.wps.parameters.data_types.Double'>)¶
Bases:
BaseAllowed
,TypedMixIn
Allowed values class allowing values from a range.
- Constructor parameters:
minval range lower bound - set to None if unbound maxval range upper bound - set to None if unbound closure *’closed’|’open’|’open-closed’|’closed-open’ spacing uniform spacing of discretely sampled ranges spacing_rtol relative tolerance of the spacing match
- ALLOWED_CLOSURES = ['closed', 'open', 'open-closed', 'closed-open']¶
- check(value)¶
check validity
- property closure¶
Get the range closure type.
- property maxval¶
Get the upper bound of the range.
- property minval¶
Get the lower bound of the range.
- property spacing¶
Get the range spacing.
- verify(value)¶
Verify the value.
- class eoxserver.services.ows.wps.parameters.allowed_values.AllowedRangeCollection(*objs)¶
Bases:
BaseAllowed
,TypedMixIn
Allowed value class allowing values from a collection of AllowedEnum and AllowedRange instances.
- check(value)¶
check validity
- property enum¶
Get merged set of the enumerated allowed values.
- property ranges¶
Get list of the allowed values’ ranges.
- verify(value)¶
Verify the value.
eoxserver.services.ows.wps.parameters.base module¶
- class eoxserver.services.ows.wps.parameters.base.BaseParamMetadata(identifier, title=None, abstract=None)¶
Bases:
object
Common metadata base of all parameter classes.
- Constructor parameters:
identifier item identifier title item title (human-readable name) abstract item abstract (human-readable description)
- class eoxserver.services.ows.wps.parameters.base.ParamMetadata(identifier, title=None, abstract=None, uom=None, crs=None, mime_type=None, encoding=None, schema=None)¶
Bases:
BaseParamMetadata
Common metadata of the execute request parameters.
- Constructor parameters:
identifier item identifier title item title (human-readable name) abstract item abstract (human-readable description) uom item LiteralData UOM crs item BoundingBox CRS mime_type item ComplexData mime-type encoding item ComplexData encoding schema item ComplexData schema
- class eoxserver.services.ows.wps.parameters.base.Parameter(identifier=None, title=None, abstract=None, metadata=None, optional=False, resolve_input_references=True)¶
Bases:
BaseParamMetadata
Base parameter class used by the process definition.
- Constructor parameters:
identifier identifier of the parameter. title optional human-readable name (defaults to identifier). abstract optional human-readable verbose description. metadata optional metadata (title/URL dictionary). optional optional boolean flag indicating whether the input
parameter is optional or not.
- resolve_input_references Set this option to False not to resolve
input references. By default the references are resolved (downloaded and parsed) transparently. If set to False the references must be handled by the process.
eoxserver.services.ows.wps.parameters.bboxdata module¶
- class eoxserver.services.ows.wps.parameters.bboxdata.BoundingBox(bbox, crs=None)¶
Bases:
tuple
Bounding-box class.
- Constructor parameters:
- bbox N-dimensional bounding box definition:
((xmin,),(xmax,)) ((xmin,ymin),(xmax,ymax)) ((xmin,ymin,zmin),(xmax,ymax,zmax))
or instance of the
Rect
class.
crs optional CRS identifier (URI)
- property as_rect¶
Cast to a Rect object. (Available only for the 2D bounding-box).
- property crs¶
Get the bounding-box CRS.
- property dimension¶
Get the bounding-box dimension.
- property lower¶
Get the bounding-box lower coordinates.
- property upper¶
Get the bounding-box upper coordinates.
- class eoxserver.services.ows.wps.parameters.bboxdata.BoundingBoxData(identifier, crss=None, dimension=2, default=None, *args, **kwargs)¶
Bases:
Parameter
Bounding-box parameter class
- Constructor parameters:
identifier identifier of the parameter. title optional human-readable name (defaults to identifier). abstract optional human-readable verbose description. metadata optional metadata (title/URL dictionary). optional optional boolean flag indicating whether the input
parameter is optional or not.
- default optional default input value. Presence of the
default value sets the parameter optional.
- crss list of accepted CRSs (Coordinate Reference Systems).
The CRSs shall be given in form of the integer EPSG codes. Defaults to WGS84 (EPSG:4326).
- dimension optional dimension of the bounding box coordinates.
Defaults to 2.
- resolve_input_references Set this option to False not to resolve
input references. By default the references are resolved (downloaded and parsed) transparently. If set to False the references must be handled by the process.
- property default_crs¶
Get the bounding-box default CRS.
- classmethod encode_crs(crs)¶
Encode the output bounding CRS.
- encode_kvp(bbox)¶
Encode KVP bounding box.
- encode_xml(bbox)¶
Encode XML bounding box.
- parse(raw_bbox)¶
Parse the input CRS.
- classmethod parse_crs(raw_crs)¶
Parse the input bounding CRS.
eoxserver.services.ows.wps.parameters.codecs module¶
- class eoxserver.services.ows.wps.parameters.codecs.Codec¶
Bases:
object
Base complex data codec.
- static decode(file_in, **opt)¶
Encoding generator.
- static encode(file_in, **opt)¶
Encoding generator.
- encoding = None¶
eoxserver.services.ows.wps.parameters.complexdata module¶
- class eoxserver.services.ows.wps.parameters.complexdata.CDAsciiTextBuffer(data='', *args, **kwargs)¶
Bases:
CDByteBuffer
- Complex data text (ASCII) in-memory buffer (StringIO).
To be used to hold generic ASCII text. The text payload is stored as a byte-stream and this class cannot hold characters outside of the 7-bit ASCII characters’ range.
- Constructor parameters:
data optional initial payload ASCII string mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- headers additional raw output HTTP headers encoded as a list
of <key>, <value> pairs (tuples).
- text_encoding optional keyword parameter defining the input text
encoding. By default ASCII is assumed.
- read(size=None)¶
Read at most size bytes, returned as a bytes object.
If the size argument is negative, read until EOF is reached. Return an empty bytes object at EOF.
- write(data)¶
Write bytes to file.
Return the number of bytes written.
- class eoxserver.services.ows.wps.parameters.complexdata.CDBase(mime_type=None, encoding=None, schema=None, format=None, filename=None, headers=None, **kwargs)¶
Bases:
object
Base class of the complex data container.
- Constructor parameters (all optional and all defaulting to None):
mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- headers additional raw output HTTP headers encoded as a list
of <key>, <value> pairs (tuples).
- property data¶
Get the payload data.
- property encoding¶
- class eoxserver.services.ows.wps.parameters.complexdata.CDByteBuffer(data=b'', *args, **kwargs)¶
Bases:
BytesIO
,CDBase
- Complex data binary in-memory buffer (StringIO).
To be used to hold a generic binary (byte-stream) payload.
- Constructor parameters:
data optional initial payload byte string mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- headers additional raw output HTTP headers encoded as a list
of <key>, <value> pairs (tuples).
- property data¶
Get the payload data.
- write(data)¶
Write bytes to file.
Return the number of bytes written.
- class eoxserver.services.ows.wps.parameters.complexdata.CDFile(name, mode='rb', buffering=-1, *args, **kwargs)¶
Bases:
CDFileWrapper
- Complex data file.
To be used to hold a generic (binary or text) byte-stream payload. NOTE: The file allows you to specify whether the file is
temporary (will be automatically removed - by default) or permanent (preserved after object destruction).
- Constructor parameters:
name mandatory file-name mode opening mode (passed to open, ‘r’ by default) buffering buffering mode (passed to open, -1 by default) mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- remove_file optional keyword argument defining whether the file
should be removed or not. Set to True by default.
- class eoxserver.services.ows.wps.parameters.complexdata.CDFileWrapper(file_object, *args, **kwargs)¶
Bases:
CDBase
Complex data file (or file-like) object wrapper.
- Constructor parameters:
file_object mandatory seekable Python file or file-like object. mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
text_encoding optional source text file encoding
- property data¶
Get the payload data.
- class eoxserver.services.ows.wps.parameters.complexdata.CDObject(data, *args, **kwargs)¶
Bases:
CDBase
- Complex data wrapper around an arbitrary python object.
To be used to set custom format attributes for the XML and JSON payload. NOTE: CDObject is not used for the input JSON and XML.
- Constructor parameters:
data mandatory object holding the payload data mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- headers additional raw output HTTP headers encoded as a list
of <key>, <value> pairs (tuples).
- property data¶
Get the payload data.
- class eoxserver.services.ows.wps.parameters.complexdata.CDPermanentFile(*args, **kwargs)¶
Bases:
CDFile
- Complex data permanent file.
To be used to hold a generic (binary or text) byte-stream payload. NOTE: This class preserves the actual file.
- Constructor parameters:
name mandatory file-name mode opening mode (passed to open, ‘r’ by default) buffering buffering mode (passed to open, -1 by default) mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- class eoxserver.services.ows.wps.parameters.complexdata.CDTextBuffer(data='', *args, **kwargs)¶
Bases:
StringIO
,CDBase
- Complex data text (Unicode) in-memory buffer (StringIO).
To be used to hold generic text. The text payload is stored as a Unicode-stream.
- Constructor parameters:
data optional initial payload Unicode string mime_type ComplexData mime-type encoding ComplexData encoding schema ComplexData XML schema (applicable XML only) format an alternative format object defining the ComplexData
mime_type, encoding, and XML schema
- filename optional raw output file-name set in the Content-Disposition
HTTP header.
- headers additional raw output HTTP headers encoded as a list
of <key>, <value> pairs (tuples).
- text_encoding optional keyword parameter defining the input text
encoding. By default UTF-8 is assumed.
- property data¶
Get the payload data.
- read(size=None)¶
Read at most size characters, returned as a string.
If the argument is negative or omitted, read until EOF is reached. Return an empty string at EOF.
- write(data)¶
Write string to file.
Returns the number of characters written, which is always equal to the length of the string.
- class eoxserver.services.ows.wps.parameters.complexdata.ComplexData(identifier, formats, *args, **kwargs)¶
Bases:
Parameter
Complex-data parameter class
- Constructor parameters:
identifier identifier of the parameter. title optional human-readable name (defaults to identifier). abstract optional human-readable verbose description. metadata optional metadata (title/URL dictionary). optional optional boolean flag indicating whether the input
parameter is optional or not.
formats List of supported formats. resolve_input_references Set this option to False not to resolve
input references. By default the references are resolved (downloaded and parsed) transparently. If set to False the references must be handled by the process.
- property default_format¶
Get default the default format.
- encode_raw(data)¶
encode complex data for raw output
- encode_xml(data)¶
encode complex data to be embedded to an XML document
- get_format(mime_type, encoding=None, schema=None)¶
Get format definition for the given mime-type and the optional encoding and schema.
- parse(data, mime_type, schema, encoding, **opt)¶
parse input complex data
eoxserver.services.ows.wps.parameters.crs module¶
- class eoxserver.services.ows.wps.parameters.crs.CRSType¶
Bases:
BaseType
CRS data-type. CRS are represented by the EPSG codes + 0 meaning the ImageCRC.
- comparable = False¶
- classmethod encode(value)¶
Encode value to a Unicode string.
- classmethod get_diff_dtype()¶
Get type of the difference of this type. E.g., timedelta for a datetime.
- name = 'anyURI'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- zero = None¶
eoxserver.services.ows.wps.parameters.data_types module¶
- class eoxserver.services.ows.wps.parameters.data_types.BaseType¶
Bases:
object
Base literal data type class. This class defines the class interface.
- classmethod as_number(value)¶
convert to a number (e.g., duration)
- comparable = True¶
- classmethod encode(value)¶
Encode value to a Unicode string.
- classmethod get_diff_dtype()¶
Get type of the difference of this type. E.g., timedelta for a datetime.
- name = None¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- classmethod sub(value0, value1)¶
subtract value0 - value1
- zero = None¶
- class eoxserver.services.ows.wps.parameters.data_types.Boolean¶
Bases:
BaseType
Boolean literal data type class.
- classmethod as_number(value)¶
convert to a number (e.g., duration)
- classmethod encode(value)¶
Encode value to a Unicode string.
- name = 'boolean'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- classmethod sub(value0, value1)¶
subtract value0 - value1
- class eoxserver.services.ows.wps.parameters.data_types.Date¶
Bases:
BaseType
Date (datetime.date) literal data type class.
- classmethod encode(value)¶
Encode value to a Unicode string.
- classmethod get_diff_dtype()¶
Get type of the difference of this type. E.g., timedelta for a datetime.
- name = 'date'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- classmethod sub(value0, value1)¶
subtract value0 - value1
- class eoxserver.services.ows.wps.parameters.data_types.DateTime¶
Bases:
BaseType
Date-time (datetime.datetime) literal data type class.
- TZOffset(name=None)¶
- UTC = <UTC>¶
- classmethod encode(value)¶
Encode value to a Unicode string.
- classmethod get_diff_dtype()¶
Get type of the difference of this type. E.g., timedelta for a datetime.
- name = 'dateTime'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- classmethod sub(value0, value1)¶
subtract value0 - value1
- class eoxserver.services.ows.wps.parameters.data_types.DateTimeTZAware(default_tz=<UTC>, target_tz=None)¶
Bases:
DateTime
Time-zone aware date-time (datetime.datetime) literal data type class.
This data-type is a variant of the DateTime which assures that the parsed date-time is time-zone aware and optionally also converted to a common target time-zone.
The default time-zone applied to the unaware time-input is passed trough the constructor. By default the UTC time-zone is used. By default the target time-zone is set to None which means that the original time-zone is preserved.
Unlike the DateTime this class must be instantiated and it cannot be used directly as a data-type.
- Constructor parameters:
default_tz default time-zone target_tz optional target time-zone
- encode(value)¶
Encode value to a Unicode string.
- parse(raw_value)¶
Cast or parse input to its proper representation.
- set_time_zone(value)¶
Make a date-time value time-zone aware by setting the default time-zone and convert the time-zone if the target time-zone is given.
- class eoxserver.services.ows.wps.parameters.data_types.Double¶
Bases:
BaseType
Double precision float literal data type class.
- classmethod as_number(value)¶
convert to a number (e.g., duration)
- classmethod encode(value)¶
Encode value to a Unicode string.
- name = 'double'¶
- classmethod sub(value0, value1)¶
subtract value0 - value1
- zero = 0.0¶
- class eoxserver.services.ows.wps.parameters.data_types.Duration¶
Bases:
BaseType
Duration (datetime.timedelta) literal data type class.
- classmethod as_number(value)¶
convert to a number (e.g., duration)
- classmethod encode(value)¶
Encode value to a Unicode string.
- name = 'duration'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- classmethod sub(value0, value1)¶
subtract value0 - value1
- zero = datetime.timedelta(0)¶
- eoxserver.services.ows.wps.parameters.data_types.FixedOffset(offset, name=None)¶
- class eoxserver.services.ows.wps.parameters.data_types.Integer¶
Bases:
BaseType
Integer literal data type class.
- classmethod as_number(value)¶
convert to a number (e.g., duration)
- classmethod encode(value)¶
Encode value to a Unicode string.
- name = 'integer'¶
- classmethod sub(value0, value1)¶
subtract value0 - value1
- zero = 0¶
- class eoxserver.services.ows.wps.parameters.data_types.String¶
Bases:
BaseType
Unicode character string literal data type class.
- comparable = False¶
- classmethod encode(value)¶
Encode value to a Unicode string.
- encoding = 'utf-8'¶
- classmethod get_diff_dtype()¶
Get type of the difference of this type. E.g., timedelta for a datetime.
- name = 'string'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- class eoxserver.services.ows.wps.parameters.data_types.Time¶
Bases:
BaseType
Time (datetime.time) literal data type class.
- classmethod encode(value)¶
Encode value to a Unicode string.
- classmethod get_diff_dtype()¶
Get type of the difference of this type. E.g., timedelta for a datetime.
- name = 'time'¶
- classmethod parse(raw_value)¶
Cast or parse input to its proper representation.
- classmethod sub(value0, value1)¶
subtract value0 - value1
eoxserver.services.ows.wps.parameters.formats module¶
- class eoxserver.services.ows.wps.parameters.formats.Format(encoder, mime_type, schema=None, is_text=False, is_xml=False, is_json=False)¶
Bases:
object
Base complex data format.
- Constructor parameters:
encoder format’s encoder object (defines the encoding) mime_type mime-type of the format schema optional schema of the document is_text optional boolean flag indicating text-based data
format.
- is_xml optional boolean flag indicating XML-based format.
The flag enables is_text flag.
- is_json optional boolean flag indicating JSON-bases format.
The flag enables is_text flag.
- allows_xml_embedding = False¶
- decode(file_in, **opt)¶
Encoding generator.
- encode(file_in, **opt)¶
Encoding generator.
- property encoding¶
Get the format encoding name.
- class eoxserver.services.ows.wps.parameters.formats.FormatBinaryBase64(mime_type='application/octet-stream')¶
Bases:
Format
Base64 encoded binary complex data format.
- allows_xml_embedding = True¶
- class eoxserver.services.ows.wps.parameters.formats.FormatBinaryRaw(mime_type='application/octet-stream')¶
Bases:
Format
Raw binary complex data format.
- allows_xml_embedding = False¶
- class eoxserver.services.ows.wps.parameters.formats.FormatJSON(mime_type='application/json', schema=None, text_encoding='utf-8')¶
Bases:
Format
JSON-based complex data format.
- allows_xml_embedding = True¶
eoxserver.services.ows.wps.parameters.inputs module¶
- class eoxserver.services.ows.wps.parameters.inputs.InputData(data, identifier, title=None, abstract=None, uom=None, crs=None, mime_type=None, encoding=None, schema=None, asurl=False)¶
Bases:
ParamMetadata
Generic container for the raw data inputs. An instances of this class holds the inputs as decoded from various WPS requests before their validation and conversion to their configured data-type.
- Constructor parameters:
data unparsed (raw) data payload (byte string) identifier input item identifier title user defined title abstract user defined abstract uom input LiteralData UOM crs input BoundingBoxData CRS mime_type input ComplexData mime-type encoding input ComplexData encoding schema input ComplexData schema asurl indicates whether the decoded input comes from
a URL encoded request (KVP) or not.
- class eoxserver.services.ows.wps.parameters.inputs.InputReference(href, identifier, title=None, abstract=None, headers=None, body=None, method=None, mime_type=None, encoding=None, schema=None, body_href=None)¶
Bases:
ParamMetadata
Input data reference class.
- Constructor parameters:
href input reference URL identifier input item identifier title user defined title abstract user defined abstract headers additional HTTP request headers body optional HTTP/POST request payload method reference method (‘GET’ or ‘POST’) mime_type reference ComplexData mime-type encoding reference ComplexData encoding schema reference ComplexData schema body_href optional HTTP/POST request payload reference URL
eoxserver.services.ows.wps.parameters.literaldata module¶
- class eoxserver.services.ows.wps.parameters.literaldata.LiteralData(identifier, dtype=<class 'eoxserver.services.ows.wps.parameters.data_types.String'>, uoms=None, default=None, allowed_values=None, *args, **kwargs)¶
Bases:
Parameter
Literal-data parameter class.
- Constructor parameters:
identifier identifier of the parameter used by the WPS service title optional human-readable name (defaults to identifier) abstract optional human-readable verbose description metadata optional metadata (title/URL dictionary) optional optional boolean flag indicating whether the input
parameter is optional or not
- dtype optional data type of the parameter. String type
str
is set by default. For list of supported types seeLiteralData.SUPPORTED_TYPES
)
uoms optional sequence of the supported units default optional default input value. Presence of the
default value sets the parameter optional.
- allowed_values optional restriction on the accepted values.
By default any value of the given type is supported. The allowed value can be specified by an enumerated list (iterable) of values or by instance of one of the following classes:
AllowedAny
,AllowedEnum
,AllowedRange
, orAllowedByReference
.- resolve_input_references Set this option to False not to resolve
input references. By default the references are resolved (downloaded and parsed) transparently. If set to False the references must be handled by the process.
- property allowed_values¶
Allowed values object of the literal data object. (RO)
- apply_uom(value, uom)¶
Convert value from the common base to the desired UOM.
- check(value)¶
Check whether the value is allowed (True) or not (False).
- property default_uom¶
Get the default UOM.
- property dtype¶
Data type class of the literal data object. (RO)
- encode(value, uom=None, encoding=None)¶
Encode the output value to its string representation.
The value is checked to match the defined allowed values restriction and the UOM conversion is applied.
Returns Unicode or byte-string if the encoding is given.
- parse(raw_value, uom=None, encoding='utf-8')¶
Parse the input value from its string representation.
The value is checked to match the defined allowed values restriction and the UOM conversion is applied.
Non-Unicode raw_data are converted to Unicode before parsing. Byte strings are decoded using the profited encoding (utf8 by default).
- strip_uom(value, uom)¶
Convert value from the provided UOM to the common base.
- property uoms¶
Get all allowed UOMs.
- verify(value)¶
Return the value if allowed or raise the ValueError exception.
eoxserver.services.ows.wps.parameters.response_form module¶
- class eoxserver.services.ows.wps.parameters.response_form.Output(identifier, title=None, abstract=None, uom=None, crs=None, mime_type=None, encoding=None, schema=None, as_reference=False)¶
Bases:
ParamMetadata
Requested output definition.
- Constructor parameters:
identifier output identifier title output title (human-readable name) abstract output abstract (human-readable description) uom output LiteralData UOM crs output BoundingBox CRS mime_type output ComplexData mime-type encoding output ComplexData encoding schema output ComplexData schema as_reference boolean flag indicating whether the output should
passed as a reference op directly in the response.
- class eoxserver.services.ows.wps.parameters.response_form.RawDataOutput(output)¶
Bases:
ResponseForm
Object representation of the raw output response.
- Constructor parameters:
output name of the requested output parameter
- lineage = False¶
- raw = True¶
- status = False¶
- store_response = False¶
- class eoxserver.services.ows.wps.parameters.response_form.ResponseDocument(lineage=False, status=False, store_response=False)¶
Bases:
ResponseForm
Object representation of the (WPS Execute) response document.
- Constructor parameters (meaning described in OGC 05-007r7, Table 50):
lineage boolean flag, set to True to print the lineage status boolean flag, set to True to update status store_response boolean flag, set to True to store execute response
- raw = False¶
- class eoxserver.services.ows.wps.parameters.response_form.ResponseForm¶
Bases:
OrderedDict
Response form defined as an ordered dictionary of the output definitions.
- get_output(identifier)¶
Get an output for the given output identifier. An instance of the Output object is always returned.
- set_output(output)¶
Set (insert) a new definition output.
eoxserver.services.ows.wps.parameters.units module¶
- class eoxserver.services.ows.wps.parameters.units.UnitLinear(name, scale, offset=0)¶
Bases:
UnitOfMeasure
Simple unit of measure with linear conversion (scale and offset):
value_uom = (value_base - offset)/scale value_base = value_uom*scale + offset
- Constructor parameters:
name UOM name scale scale factor offset optional base offset (set to 0.0 by default)
- Examples:
For temperature conversions between the Fahrenheit scale (this UOM) and the Kelvin scale (base UOM) set scale to 5.0/9.0 and offset to 459.67*5.0/9.0 .
For simple distance conversions between kilometres (this UOM) and metres (base UOM) set scale factor to 1000.0 and offset to 0.0 .
- apply(value)¶
Convert value from the common base to this unit.
- strip(value)¶
Convert value of this unit to the common base.
- class eoxserver.services.ows.wps.parameters.units.UnitOfMeasure(name)¶
Bases:
object
Base unit of measure class. The class defines conversion of input values in the given units to a common base unit and conversion of the output values from the common base unit to the this unit.
- Constructor parameters:
name UOM name
- apply(value)¶
Convert value from the common base to this unit.
- strip(value)¶
Convert value of this unit to the common base.
Module contents¶
- class eoxserver.services.ows.wps.parameters.Reference(path, href, mime_type=None, encoding=None, schema=None, **kwarg)¶
Bases:
object
Output reference. An instance of this class defines a CommplexData output passed by a reference. The output must be stored in a file.
- Constructor parameters:
path path to the output file in the local file-system href public URL of the output reference mime_type output ComplexData mime-type encoding output ComplexData encoding schema output ComplexData schema
- class eoxserver.services.ows.wps.parameters.RequestParameter(request_parser=None)¶
Bases:
object
Special input parameter extracting input from the request metadata. This might be used to pass information such as, e.g., HTTP headers or user authentication to the process like a regular input variable.
This class is the base class and it expected that parse_request method get overloaded by inheritance or by a function passed as an argument to the constructor.
- parse_request(request)¶
Method extracting information from the Django HTTP request object.
- eoxserver.services.ows.wps.parameters.fix_parameter(name, prm)¶
Expand short-hand definition of the parameter.