Simle Hashtable

版本 1.0.0.0 (4.2 KB) 作者: Matthew Krauski
Simple hashtable class.
4.7K 次下载
更新时间 2004/12/14

无许可证

This is a simple hashtable class. Keys must be a string (strcmp is used to located entries), and the data can be any type. The internal structure is two cell lists, one for the keys and one for the data.

Following is the hashtable Contents:

@HASHTABLE

Files
clear - Clear hash table
display - Display a hash table object
elements - Get all hash table elements
get - Get data from the hash table
hashtable - Constructor for HashTable class
isempty - Check to see if the hash is empty
iskey - Check to see if the hash is currently using a key
keys - Get all the keys currently being used in the hash
put - Put data in the hash table
remove - Remove element from the hash
values - Get all data contained in the hash table

As previously stated, this is a very simple structure. No attempt has been made for optimization, and 'put' and 'get' can only handle one entry at a time. The intent is to provide a structure that overcomes MATLAB struct field name limitations.

引用格式

Matthew Krauski (2024). Simle Hashtable (https://www.mathworks.com/matlabcentral/fileexchange/6514-simle-hashtable), MATLAB Central File Exchange. 检索时间: .

MATLAB 版本兼容性
创建方式 R14SP1
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Dictionaries 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
版本 已发布 发行说明
1.0.0.0