RecordsetIndexer Class
yui3/src/recordset/js/recordset-indexer.js:6
Parent Module: recordset
Plugin that provides the ability to store multiple custom hash tables referencing records in the recordset. This utility does not support any collision handling. New hash table entries with a used key overwrite older ones.
Index
Attributes
Methods
_defAddHash
()
private
Updates all hash tables when a record is added to the recordset
_defRemoveHash
()
private
Updates all hash tables when a record is removed from the recordset
_defUpdateHash
()
private
Updates all hash tables when the recordset is updated (a combination of add and remove)
_setHashTable
-
key
Setup the hash table for a given key with all existing records in the recordset
Parameters:
-
key
StringA key to hash by.
Returns:
obj The created hash table
createTable
-
key
Creates a new hash table.
Parameters:
-
key
StringA key to hash by.
Returns:
tbls[key] The created hash table
getTable
-
key
Get a hash table that hashes records by a given key.
Parameters:
-
key
StringA key to hash by.
Returns:
table The created hash table