angular2-schema-form
Version:
Angular2 Schema Form (DISCLAIMER: it is not related to angular-schema-form)
17 lines (16 loc) • 490 B
JavaScript
var ValidatorRegistry = (function () {
function ValidatorRegistry() {
this.validators = [];
}
ValidatorRegistry.prototype.register = function (path, validator) {
this.validators[path] = validator;
};
ValidatorRegistry.prototype.get = function (path) {
return this.validators[path];
};
ValidatorRegistry.prototype.clear = function () {
this.validators = [];
};
return ValidatorRegistry;
}());
export { ValidatorRegistry };