This is the base class for all typed resource dictionaries. Instances can be obtained from one of its subclasses, or via the
build method, which crates an intermediate
ResourceBuilder object. All members of a
Resources (or subclass) instance must be of the same type (
ResourceBuilder, which is a factory for resource dictionaries. The options given here determine the type of the resource, as well as the “raw” type from which to create the resource values from.
- The validator function receives a “raw” resource value (unconverted, as provided in the input data object) and must return a boolean indicating whether it is accepted. This means it either is a value that will be accepted by the converter, or if no converter is present it must be the final format of the resource value.
- The converter if a function that receives the raw input value and returns the value as it will be present on the final resource dictionary. If no converter is given this is the same type as the resource type.
- The “type” may be a constructor of the type of the final resource value as returned by the converter. For primitives this option must not be given.
||The configuration of the new