utils.Options Class
A simple mixin for managing an options argument. Mixin uses the defaultOptions property to identify default options. Mixin also automatically identify on* properties as events and assigns them
Constructor
utils.Options
()
Methods
merge
(
Object
static
-
target
-
[obj]
merges a list of objects into a single object
Parameters:
-
target
Object -
[obj]
Object optionalan object to merge (can be an infinite list of objects)
Returns:
Object:
merged object
setOptions
(
chainable
-
options
Parameters:
-
options
Object
setOptions
(
Object
static
-
defaults
-
options
this method acts like merge, only that it only merges properties of the original object
Creates a new object rather than actually merge
Parameters:
-
defaults
Objecta map of default properties
-
options
Objecta map of values to merge
Returns:
Object:
new merged object
Properties
defaultOptions
Unknown
protected
this property will be used to identify default options