Files: f7792c89da60d7cb1f331f20d26af148789f2e68 / README.md
2163 bytesRaw
install
npm install referanceMap
SYNOPSIS
This is a simple determinstic map that maps POJOs to an integer.
API
constructor
Handle mapping arbitary JS object to ints
add
Adds an object to the referance map returning an int to be used as a referance
Parameters
obj
any
Returns integer
get
gets a POJO given a refernce as an int
Parameters
ref
integer
Returns any
delete
deletes an object given a referance as an int
Parameters
integer
ref
Returns boolean whether or not the object was deleted
clear
clears the referance map of a objects
LICENSE
Built with git-ssb-web