You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
462 B

import { find } from './util.js';
export class CustomTransformerRegistry {
constructor() {
this.transfomers = {};
}
register(transformer) {
this.transfomers[transformer.name] = transformer;
}
findApplicable(v) {
return find(this.transfomers, transformer => transformer.isApplicable(v));
}
findByName(name) {
return this.transfomers[name];
}
}
//# sourceMappingURL=custom-transformer-registry.js.map