public abstract class SubViewer extends Object
Modifier | Constructor and Description |
---|---|
protected |
SubViewer(Viewer viewer)
Creates a new sub-viewer.
|
Modifier and Type | Method and Description |
---|---|
void |
closed()
Call this before you discard a sub-viewer.
|
static SubViewer |
createSubViewer(Viewer viewer,
ViewerInitData vid)
Creates a new sub-viewer that allows selecting from any applicable view.
|
abstract JComponent |
getComponent()
Gets the JComponent on which the sub-viewer is displayed.
|
static List<SubViewer> |
getSubViewers(Viewer viewer)
Gets the sub-viewers for a particular viewer.
|
static void |
linkSubViewers(Viewer viewer,
Viewer wrappedViewer)
Registers a viewer so that it's sub-viewers will act as sub-viewer for
another.
|
static void |
releaseAll(Viewer viewer)
Frees resources associated with sub-viewers attached to a particular
viewer.
|
abstract void |
setValue(Value value,
DebugContext context,
String name,
String label,
boolean reset)
Sets the value in the sub-viewer.
|
static void |
unlinkSubViewers(Viewer viewer)
Unregisters a wrapped viewer from a wrapper viewer.
|
abstract void |
update()
Updates the subviewer from any thread.
|
abstract void |
update(DebugContext context)
Updates the subviewer immediately from the debugger thread.
|
protected SubViewer(Viewer viewer)
viewer
- the parent viewer.public static SubViewer createSubViewer(Viewer viewer, ViewerInitData vid)
viewer
- the parent viewer.vid
- the ViewerInitData that was passed to the parent viewer in the
build() method.public static List<SubViewer> getSubViewers(Viewer viewer)
viewer
- the parent viewer.public static void linkSubViewers(Viewer viewer, Viewer wrappedViewer)
viewer
- the wrapper viewer.wrappedViewer
- the wrapped viewer. This should have been created
manually, not through the automatic viewer system.public static void releaseAll(Viewer viewer)
viewer
- the viewer for which sub-viewer will be released.public static void unlinkSubViewers(Viewer viewer)
viewer
- the wrapper viewer.public void closed()
public abstract JComponent getComponent()
public abstract void setValue(Value value, DebugContext context, String name, String label, boolean reset)
value
- the new value.context
- the current debugger context.name
- display name to give the value. This will be shown by the
"basic" viewer.label
- string to display at the top of the sub-viewer.reset
- true if this value should not be considered the "same
variable" as the previous value, false otherwise. If this is true and the
viewer shows an indication of changes to the value, it should display
this value as it would the initial value.public abstract void update()
public abstract void update(DebugContext context)
context
- the current debugger context.