maptek.workflows.matching sub-module

Module containing the enum used to set the method used by generated connectors to match their values.

enum MatchAttribute(value)

Bases: Enum

Enum of possible matching types for generated connectors.

Examples

This script creates one connector which uses each matching scheme.

>>> from maptek.workflows import (WorkflowArgumentParser, MatchAttribute,
...                               FileConnectorType, Point3DConnectorType,
...                               BooleanConnectorType)
>>> parser = WorkflowArgumentParser("Example attribute matching")
>>> parser.declare_input_connector(
...     "surface",
...     FileConnectorType,
...     connector_name="Surface",
...     matching=MatchAttribute.BY_NAME)
>>> parser.declare_input_connector(
...     "centroid",
...     Point3DConnectorType,
...     connector_name="Centroid",
...     matching=MatchAttribute.BY_TYPE)
>>> parser.declare_input_connector(
...     "overwrite",
...     BooleanConnectorType,
...     connector_name="Overwrite",
...     matching=MatchAttribute.DO_NOT_MATCH)
>>> parser.parse_arguments()
>>> # Do something useful with the arguments.

Valid values are as follows:

BY_TYPE = <MatchAttribute.BY_TYPE: 0>
BY_NAME = <MatchAttribute.BY_NAME: 1>
DO_NOT_MATCH = <MatchAttribute.DO_NOT_MATCH: 2>