TinyMCE:API/tinymce/extend
From Moxiecode Documentation Wiki
< TinyMCE:API | tinymce
Contents |
[edit]
Method: extend
[edit]
Summary
Extends an object with the specified other object(s).
[edit]
Syntax
<Object> extend(<Object> o, <Object eo> ..)
[edit]
Parameters
- o
- Object to extend with new items.
- eo
- Object to extend the specified object with, multiple objects can be passed as arguments after this one.
[edit]
Returns
o New extended object, same reference as the input object.
[edit]
Examples
// Extends obj1 with two new fields
var obj = tinymce.extend(obj1, {
somefield1 : 'a',
somefield2 : 'a'
});
// Extends obj with obj2 and obj3
tinymce.extend(obj, obj2, obj3);
