Dictionaries vs iVars
Dictionaries vs iVars
- Subject: Dictionaries vs iVars
- From: Gordon Apple <email@hidden>
- Date: Wed, 27 Jun 2007 15:54:29 -0500
I'm still toying with the idea of using dictionaries instead of iVars in
my graphics objects and other types of data objects. My thinking is to have
only one type of graphic object with a single dictionary and let the
relevant controller dynamically add properties as needed, e.g., shadows,
borders, shaders, content (pictures, QT, text, etc.) These can all be
accessed by key value by the renderer and editor. This seems like it would
be a tremendous simplification of design and would offer great flexibility
for later feature additions. It seems like it could simplify the inspector
interface. It could also make it easy to view data structures when needed
without having to resort to the debugger (e.g., field maintenance).
I would like to hear any comments on this approach. For example,
performance hits? Has anyone tried this?
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden