|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--com.novell.application.console.snapin.context.SnapinContext
Provides the base class from which all snap-in context classes are derived.
Classes derived from the SnapinContext base class contain information on the current state of the Object Browser, such as which entries are selected. This information is usually available during snap-in initialization and can be extracted into private data fields for use by the snap-in methods.
Any relevant context information is packaged in the info parameter supplied to the initSnapin() method. The context is extracted from the info object by calling info.getContext() and casting it to the appropriate snap-in context. If a null is returned, no context is defined for that particular snap-in class.
During ViewSnapin initalization the current Object Browser context is also stored in the InitSnapinInfo parameter supplied to the initSnapin() method. A call to the getSnapinContext() method will return a valid ViewSnapinContext for that point in time. However, the context can change between initialization and a call to the getView() method. Therefore, the context should be obtained from the ViewSnapinContext parameter supplied in the getView() call and not from the context provided during initialization.
The following table summarizes the data contained in the contexts for the various snap-in classes:
| Snap-in Class | Snapin Context Class | Context Contains | Where Obtained |
| Page | PageSnapinContext | ObjectEntryCollection, PropertyBook ref. | initSnapin(into) |
| View | ViewSnapinContext | ObjectEntry, Result Modifier | getView(view_context) |
| Menu | MenuSnapinContext | ObjectEntryCollection | initSnapin(info) |
| ToolBar | ToolBarSnapinContext | ObjectEntryCollection | initSnapin(info) |
| StatusBar | StatusBarSnapinContext | ObjectEntryCollection | initSnapin(info) |
| PopupMenu | PopupMenuSnapinContext | ObjectEntryCollection, Parent ObjectEntry | initSnapin(info) |
| MapObjectEntry | MapObjectEntrySnapinContext | ObjectEntry | initSnapin(info) |
| ResultModifier | ResultModifierSnapinContext | GUI type, User object | initSnapin(info) |
| All Others | SnapinContext(base class) | null |
PageSnapinContext,
MenuSnapinContext,
ToolBarSnapinContext,
StatusBarSnapinContext,
PopupMenuSnapinContext,
ViewSnapinContext,
ResultModifierSnapinContext,
MapObjectEntrySnapinContext| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||