Syntax FACTORY_DEF ListFactory [FACTORY_NAME ] [INPUT FEATURE_TYPE [ ]* []*]* [GROUP_BY []+]* [FLUSH_WHEN_GROUPS_CHANGE (Yes|No)] LIST_NAME [LIST_ATTRS_TO_INCLUDE []* ] [LIST_ATTRS_TO_INCLUDE_MODE (ALL|SELECTED)] [OUTPUT (LIST|SINGLETON) FEATURE_TYPE [ ]* []*]* Overview This factory takes a series of features matching an input specification and joins them together based on attribute values specified by the GROUP_BY clause. One feature is output for each group resulting from the GROUP_BY clause. If no GROUP_BY clause is specified, then all features fall into the same group and a single feature is output. The features output from the ListFactory have all of their attributes stored within the list identified by . There is one element in the list for each feature that is in the group from which the list is constructed. If no GROUP_BY clause is specified, then the number of elements in the list is equivalent to the number of features input into the ListFactory. If FLUSH_WHEN_GROUPS_CHANGE is specified with a value of Yes, then the input features are assumed to be grouped prior to coming in, and resulting output features will be emitted whenever a feature comes in that renders a different group key value from the previous feature. Note that, for backwards compatibility, ORDERED_BY_GROUP will alias to the keyword FLUSH_WHEN_GROUPS_CHANGE (see above). The optional LIST_ATTRS_TO_INCLUDE_MODE will specify if ALL attributes should be added to a list, or if only the SELECTED attributes (specified with the LIST_ATTRS_TO_INCLUDE clause) should be added to the list. If this value is not specified, it defaults to ALL. The output features have no geometry. If the OUTPUT SINGLETON clause is specified, features that are the only members of their group are output unchanged. Output Tags The ListFactory supports the following output tags. LIST The features for which lists are constructed. If the SINGLETON tag is specified, then each of these features has a list with at least two elements. SINGLETON Applies to features that are the only members in a group. If this isn't specified, then such features are output using the LIST tag with all their attributes stored in an element list having only one element. If an OUTPUT SINGLETON clause is specified, such features are output unchanged.