registerValueSpecType method
void
registerValueSpecType(
- String name,
- ValueSpecBuildFunction func,
- Map<
String, EditorPropertyType> properties, { - Map<
String, Map< ? subTypes,String, EditorPropertyType> >
Method for registering an object property, whose resolver requires a value for its execution. eg: ImageProvider needs the path or url.
Implementation
@nonVirtual
void registerValueSpecType(String name, ValueSpecBuildFunction func,
Map<String, EditorPropertyType> properties,
{Map<String, Map<String, EditorPropertyType>>? subTypes}) {
_propertyBuilders[name] = func;
_schema[name] = EditorSpecProperty(properties,
abstract: subTypes != null && subTypes.isNotEmpty);
if (subTypes != null) {
for (var subType in subTypes.keys) {
_schema[subType] =
EditorSpecProperty(subTypes[subType], baseType: name);
}
}
}