fmeobjects.FMEFactoryPipeline.addFactory

FMEFactoryPipeline.addFactory(factoryDef, delimiter)

This method is used to add a new factory to the end of the factory pipeline. If ‘factoryDef’ is a list of str the factory to be added is specified as a set of tokens; one token for every whitespace-delimited str in the factory definition. Each token is represented as one entry in the ‘factoryDef’ parameter. For example, the PolygonFactory show below is be specified using 20 tokens:

  • FACTORY_DEF * PolygonFactory

  • FACTORY_NAME SamplePolygon

  • INPUT FEATURE_TYPE *

  • GROUP_BY someAttr

  • VERTEX_NODED

  • REMOVE_CORRIDORS

  • OUTPUT POLYGON FEATURE_TYPE poly

  • OUTPUT LINE FEATURE_TYPE line

If ‘factoryDef’ is a str, it specifies the factory to be added as an ASCII character str. The ‘delimiter’ parameter specifies the str to be used as delimiter when parsing the ‘factoryDef’ string for tokens.

Parameters:
  • factoryDef (list[str] or str) – Specifies the factory definition to be added.

  • delimiter ((Optional) str) – Only to be specified if ‘factoryDef’ is a str, defaults to “ “ or space delimited.

Return type:

None

Raises:

FMEException – An FMEException is raised if there was an error.