weaver.status
Module Contents
- class weaver.status.StatusCompliant[source]
Utility
enum.Enum
methods.Create an extended enum with these utilities as follows.
class CustomEnum(ExtendedEnum): ItemA = "A" ItemB = "B"
Warning
Must not define any enum value here to allow inheritance by subclasses.
- class weaver.status.StatusCategory[source]
Utility
enum.Enum
methods.Create an extended enum with these utilities as follows.
class CustomEnum(ExtendedEnum): ItemA = "A" ItemB = "B"
Warning
Must not define any enum value here to allow inheritance by subclasses.
- class weaver.status.Status[source]
Constants container that provides similar functionalities to
ExtendedEnum
without explicit Enum membership.
- weaver.status.map_status(wps_status: AnyStatusType, compliant: StatusCompliant = StatusCompliant.OGC) StatusType [source]
Maps WPS execution statuses to between compatible values of different implementations.
Mapping is supported for values from
weaver.status
,OWSLib
,pywps
as well as some specific one-of values of custom implementations.For each compliant combination, unsupported statuses are changed to corresponding ones (with closest logical match). Statuses are returned following
Status
format. Specifically, this ensures statues are lowercase and not prefixed byProcess
(as in XML response of OWS WPS likeProcessSucceeded
for example).- Parameters:
wps_status – One of
Status
or its literal value to map to compliant standard.compliant – One of
StatusCompliant
values.
- Returns:
mapped status complying to the requested compliant category, or
Status.UNKNOWN
if no match found.