mxObjectIdentity

Identity for JavaScript objects and functions.  This is implemented using a simple incrementing counter which is stored in each object under FIELD_NAME.

The identity for an object does not change during its lifecycle.

Summary
mxObjectIdentityIdentity for JavaScript objects and functions.
Variables
FIELD_NAMEName of the field to be used to store the object ID.
counterCurrent counter.
Functions
getReturns the ID for the given object or function or null if no object is specified.
clearDeletes the ID from the given object or function.

Variables

FIELD_NAME

FIELD_NAME: 'mxObjectId'

Name of the field to be used to store the object ID.  Default is <code>mxObjectId</code>.

counter

counter: 0

Current counter.

Functions

get

get: function(obj)

Returns the ID for the given object or function or null if no object is specified.

clear

clear: function(obj)

Deletes the ID from the given object or function.

FIELD_NAME: 'mxObjectId'
Name of the field to be used to store the object ID.
counter: 0
Current counter.
get: function(obj)
Returns the ID for the given object or function or null if no object is specified.
clear: function(obj)
Deletes the ID from the given object or function.
Close