this.ElementNodeFactory.prototype.registerTransformation = function(Transformation) {
return this.transformations.register(Transformation);
};
+ this.ElementNodeFactory.prototype.registerMethod = function(methodName, method) {
+ this[methodName] = method;
+ };
this.TextNodeFactory = function() {
smartxml.TextNode.apply(this, arguments);
this.TextNodeFactory.prototype.registerTransformation = function(Transformation) {
return this.transformations.register(Transformation);
};
+ this.TextNodeFactory.prototype.registerMethod = function(methodName, method) {
+ this[methodName] = method;
+ };
this.classMethods = {};
this.classTransformations = {};
this.trigger('contentSet');
},
+ registerMethod: function(methodName, method) {
+ this[methodName] = method;
+ },
+
registerTransformation: function(Transformation) {
return this.transformations.register(Transformation);
},
);
}
targets.forEach(function(target) {
- target[methodName] = method;
+ target.registerMethod(methodName, method)
});
});
}