Syntax FACTORY_DEF ExtensionFactory [FACTORY_NAME ] [INPUT FEATURE_TYPE [ ]* []*]* EXTENSION_LENGTH [SEGMENTS_TO_AVERAGE ] [REJECT_INVALID_GEOM ] [OUTPUT (ORIGINAL|BEGINNING|END|STRETCHED|REJECTED) FEATURE_TYPE [ ]* []*]* Overview This factory accepts linear features and can output two-point linear features that extend the feature by a user-specified length. This factory can also output the original feature with the first and last segments stretched by a user-specified amount. Each of the created features gets a copy of all attributes of the original feature, including the feature type. Arcs that are input are converted to lines before processing. One feature this factory can create is an extension of the first segment in the input feature. This feature's orientation is the same as the first segment of the input feature and its end point is the same as the input feature's start point. This new feature is output via the OUTPUT BEGINNING clause. Another feature this factory can create is an extension of the last segment of the input feature. This feature's orientation is the same as the last segment of the input feature and its start point is the same as the input feature's end point. The feature holding this segment is output via the OUTPUT END clause. The length of these extension features is controlled by the EXTENSION_LENGTH clause. This clause must specify a positive real number with a constant, or as an attribute value or as the output of a function. Each of the extension features consists of a two-point segment that has this length. The optional SEGMENTS_TO_AVERAGE clause indicates the number of segments that should be considered when computing the orientation angle for the extension feature. By default, this is set to 1, which means the orientation of the extension feature matches the orientation of just one segment in the original feature. It can be set to any number of segments, in which case the orientation will be set to the average orientation of those segments. If the number of segments is larger than the number of segments available on the feature, then the entire feature orientation is averaged and used. A third feature this factory can create is a duplicate of the input feature except that the first and last segments are extended in their respective orientation directions. The length of these extensions is also controlled by the EXTENSION_LENGTH clause. In this case the end nodes of the line are moved; no new nodes are added. The feature holding this segment is output via the OUTPUT STRETCHED clause. All input features are output untouched via the OUTPUT ORIGINAL clause. In addition, any non-linear input features are immediately output without any extension features via the OUTPUT ORIGINAL clause. When REJECT_INVALID_GEOM is Yes, the factory will output invalid features to Rejected port. Output Tags The ExtensionFactory supports the following output tags. BEGINNING A two-point feature extending the input feature's first segment. END A two-point feature extending the input feature's last segment. STRETCHED A copy of the original feature, with the end points extended. ORIGINAL The original, unchanged input features. REJECTED Inputs that are not lines go to this port.