I am looking over the Mail Search Tutorial provided by Apple and I notice that at several points in their code they set an associated object, for example:
set associated object of accountItem to accountIndex
It looks like the index number of a mailboxe in the Mail app. The actual value is an integer, I’m not showing the source here. They pull out the info as shown here:
set theIndex to associated object of theItem
As far as I can tell, it looks like an associated object is something that stores data, but does not show up in the Table View.
Maybe I’m grasping, but can one set any object as the associated object?
For example, would it be possible to have a Table View with a datasource, and each row of the datasource would have an associated object (such as a list) that contains data?
Maybe I’m way out in left field trying to understand and combine datasources and associated objects. Can anyone help?
Scott