deleteInstanceReference
function
Removes a reference to an instance by id so it can be garbage collected.
connection.addInstanceReference( instance )
Decrements the number of references to an instance in the instanceStore. Removes the instance if there are no longer any references.
Parameters
- instance
{Instance}:The instance to remove.
Use
deleteInstanceReference is called to remove references to instances in
the instanceStore so the instances maybe garbage
collected. It's usually called when the application or some part of the application no
longer is interested in an instance.
addInstanceReference has an example of adding
an instance to the store. The following continues that example to remove
the originalTodo from the store:
todoConnection.deleteInstanceReference(originalTodo);