Abstract base class for filter input/output type descriptions.
Filter type specifications need to fulfill the following requirements: 1) They must uniquely and reliably identify the input/output types supported by a filter. 2) They must be flexible enough to deal with type polymorphism (e.g. a generic XSL filter may accept several XML input formats while a specialized crosswalk filter may only accept a very specific XML encoding as input) or inheritance (e.g. when checking the class of an object). 3) Type definitions must be consistent across all filters (even those contributed by community plugins). 4) Type descriptions must be flexible enough so that new types can always be introduced, even by the community. 5) Type descriptions should have a unique string representation that is easy to read by humans and can be persisted. The string must contain all information necessary to instantiate the type description object.
String representations of type descriptions consist of two parts:
- the first part identifies the type description class
- the second part contains parameters that a specific type description class needs to actually check a type The two parts are separated by a double colon.
- See Also
- TypeDescriptionFactory for more details about the type description string representation.
FilterDAO for more details about how type descriptions are used to choose compatible filters for a given input/output type.
Definition at line 49 of file TypeDescription.inc.php.
|$typeName||string A plain text type name to be parsed by this type description class.|
Type names can be any string. This base class provides a basic implementation for type cardinality (array-types) which can be re-used by all subclasses.
We currently do not support heterogeneous or multi-dimensional arrays because we don't have corresponding use cases. We may, however, expand our syntax later to accommodate that.
If you do not know the exact count of an array then you can leave the parentheses empty ().
Definition at line 79 of file TypeDescription.inc.php.