5. Using the ListEditor, change to class mode, add Object class
6. Drag out a ClassAgent object
7. Make the SortedList's agent the ClassAgent instance
8. Make the browser's delegate the SortedList
9. Test Interface (Use switch on appicon to stop).
StringBrowsing:
1. IB, New Empty Module.
2. Drag out a window
3. Drag out a browser, resize it
4. Drag out a SortedList object
5. Drag out a StringAgent object
6. Connect agent outlet of SortedList to StringAgent
7. Connect delegate outlet of browser to SortedList
8. Edit SortedList
9. Add several instances of String (use object, not class, mode)
10. Selecting a String in the list, go to attributes browser, change initial stringValue.
11. Repeat above; make each string different - enter "stringValue" in the showBy field to keep track.
12. Test Interface.
NOTE: Strings will not be in sorted order - awakeFromNib isn't called in Test Interface mode. At run-time in an application context, the strings will be sorted as soon as the nib is loaded.
TimerInspector:
1. Copy TimerInspector.nib from project
2. Drag out a new TBinderList, drag out a Timer
3. Connect from TBinderList to Timer, make it the dataSource.
4. Connect from TBinderList to each text field, choosing the appropriate dataSource and interface accessor methods.
5. Inspect each of the above connections by double-clicking on the connection in the list. Turn the verify feature on for each one.
6. Connect the TBinderList to the three switches (using the state accessor).
7. Test Interface. Notice that the dataSource is updated when you hit enter in the TextFields, or click on a button. This is the "autoUpdate" feature. Also notice that unacceptable values are "clipped". Thus, a -1 in the Period field becomes a 0.05 (the smallest allowable period for the Timer object). This is the verify feature.
8. Notice the limitations of TBinders. The pulldown list needs some code behind it, since TBinders can only do direct mappings. Matrixes of buttons are often used to index an array of unrelated values as well; there is no provision for this kind of thing in TBinders.