Class R.math.PooledMathObject
Extends
R.engine.PooledObject.
The base object class which represents a math object within
the engine. All math objects should extend from this class mainly due to
the fact that the engine can switch between pooling the object and running
transiently.
Defined in: pooledmathobject.js.
Constructor Attributes | Constructor Name and Description |
---|---|
R.math.PooledMathObject(name)
Create a math object.
|
Method Attributes | Method Name and Description |
---|---|
<static> |
R.math.PooledMathObject.create()
Similar to a constructor, all pooled objects implement this method.
|
destroy()
Destroy this object instance (remove it from the Engine).
|
|
Get the class name of this object
|
- Methods borrowed from class R.engine.PooledObject:
- clearObjectDataModel, getId, getName, getObjectDataModel, getProperties, isDestroyed, release, setName, setObjectDataModel, toString, toXML
Class Detail
R.math.PooledMathObject(name)
Create a math object.
- Parameters:
- name
- {String} The name of the object
Method Detail
<static>
R.math.PooledMathObject.create()
Similar to a constructor, all pooled objects implement this method.
The create() method will either create a new instance, if no object of the object's
class exists within the pool, or will reuse an existing pooled instance of
the object. Either way, the constructor for the object instance is called so that
instance creation can be maintained in the constructor.
Usage: var obj = [ObjectClass].create(arg1, arg2, arg3...);
destroy()
Destroy this object instance (remove it from the Engine). The object's release
method is called after destruction so it will be returned to the pool of objects
to be used again.
{String}
getClassName()
Get the class name of this object
- Returns:
- {String} "R.math.PooledMathObject"