Optimizing NSMutableDictionary Speed
Optimizing NSMutableDictionary Speed
- Subject: Optimizing NSMutableDictionary Speed
- From: John Nairn <email@hidden>
- Date: Fri, 11 Apr 2003 09:20:10 -0600
I am thinking of converting an application to Cocoa that may deal with
a large number of records. The data model fits logically into an
NSMutableDictionary with record IDs (which are unique) as keys. The
concern is how NSMutableDictionary will respond to frequent searching
by key? Typically files will have thousands of records; and an extreme
file might have a million records. Use of the application will require
frequent location of records by key.
All code examples I have seen use NSString's for keys in dictionaries,
but the documentation alludes to keys being any kind of object as long
as it responds to certain protocols. Are there ways to improve the
efficiency of dictionaries by defining key objects that might get
located faster?
------------
John Nairn (1-801-581-3413, FAX: 1-801-581-4816)
Web page:
http://www.mse.utah.edu/~nairn
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.