java.lang.Object
de.grogra.pf.ui.PanelDecorator
de.grogra.imp.View
- All Implemented Interfaces:
Manageable
,Context
,Panel
,Disposable
,EventListener
,ModifiableMap.Producer
,EventListener
,TreeModelListener
public abstract class View
extends PanelDecorator
implements EventListener, TreeModelListener, ModifiableMap.Producer, Manageable
A
View
is a Panel
which represents
a Graph
in geometrical-graphical way
(e.g., using two- or three-dimensional graphics).
View
is a subclass of PanelDecorator
:
As such, it implements some common operations of views, while
the actual GUI component is provided by the decorated panel.- Author:
- Ole Kniemeyer
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface de.grogra.util.EventListener
EventListener.Bicast, EventListener.Multicaster
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final View.Type
static int
static final EnumerationType
static final UIProperty
static final SCOType.Field
static final SCOType.Field
static final I18NBundle
protected final EventListener.Multicaster
static int
static int
static final EnumerationType
static final SCOType.Field
static int
static int
static String
static String
static int
static final EnumerationType
static final EnumerationType
static final EnumerationType
static final SCOType.Field
static final SCOType.Field
static final SCOType.Field
Fields inherited from class de.grogra.pf.ui.PanelDecorator
decorator, panel
Fields inherited from interface de.grogra.pf.ui.Panel
DEC_WAIT_CURSOR, DEFAULT_CURSOR, INC_WAIT_CURSOR, INHERIT_CURSOR, PANEL_ID, WAIT_CURSOR
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
addMappings
(ModifiableMap out) addToolListener
(View view, UIProperty tool) static View
protected abstract ViewEventHandler
static void
final void
dispose()
static void
disposeRenderer
(Item item, Object info, Context ctx) static void
void
This method is invoked on registered event listeners whenevent
has occured.void
fieldModified
(PersistenceField field, int[] indices, Transaction t) static View
get
(GraphState gs) static View
final Tool
float
float
abstract IOFlavor
getGraph()
float
float
getPathFor
(GraphState gs, Object obj, boolean node) abstract UIProperty
static Selectable
static Selectable
static Selectable
getSize()
int
getStamp()
Returns a stamp for this object.protected abstract UIProperty
Returns the view component which is used as a GUI component to perform the actual visualization of the graph.static ViewComponent
protected abstract UIProperty
boolean[]
boolean[]
float
float
final GraphState
initialize
(Panel panel, Map params) protected abstract void
boolean
isInVisibleLayer
(Object o, boolean asNode, GraphState gs) boolean
isInVisibleScale
(Object o, boolean asNode, GraphState gs) static boolean
abstract boolean
isToolGraph
(Graph graph) void
nextTool()
Set the next ToolFactory from the getToolProperty to be active.abstract void
abstract void
void
static void
static void
renderToFile
(Item item, Object info, Context ctx) protected void
repaint
(int flags) static void
set
(GraphState gs, View view) final void
setActiveTool
(Tool tool) final void
setDimensions
(float magnitude) final void
setDimensions
(float magnitude, float epsilon, float visualEpsilon) void
setEpsilon
(float epsilon) void
setGraph()
void
void
setMagnitude
(float magnitude) void
setViewComponent
(ViewComponent component) void
setVisibleLayers
(boolean[] l) void
setVisualEpsilon
(float visualEpsilon) void
substituteSelection
(GraphState[] gs, Object[] object, boolean[] asNode, int index) void
void
void
void
protected void
protected abstract void
Methods inherited from class de.grogra.pf.ui.PanelDecorator
checkClose, getComponent, getContent, getDecorator, getMenu, getPanel, getPanelId, getUIPropertyMap, getWindow, getWorkbench, initDecorator, initPanel, resolve, setContent, setCursor, setMenu, show
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.grogra.persistence.Manageable
getManageableType
-
Field Details
-
LOD_MIN
public static int LOD_MIN -
LOD_MAX
public static int LOD_MAX -
STEREO_MAX
public static int STEREO_MAX -
PREVIEW_MAX
public static int PREVIEW_MAX -
ANAGLYPH_MAX
public static int ANAGLYPH_MAX -
SCALE_COUNT
public static int SCALE_COUNT -
SCALES_CHANGED
-
SCALES_VISIBLE
-
I18N
-
LOD_TYPE
-
STEREO_VIEW_TYPE
-
VIEW_PREVIEW1_TYPE
-
VIEW_PREVIEW2_TYPE
-
ANAGLYPH_VIEW_TYPE
-
COMPONENT
-
listeners
-
$TYPE
-
graphDescriptor$FIELD
-
visibleScales$FIELD
-
visibleLayers$FIELD
-
epsilon$FIELD
-
visualEpsilon$FIELD
-
magnitude$FIELD
-
-
Constructor Details
-
View
public View()
-
-
Method Details
-
get
-
get
-
set
-
getViewComponent
-
create
-
getSelectableGraph
-
getSelectableLayers
-
getSelectableScales
-
getToolProperty
-
getViewEventFactoryProperty
-
getResolutionProperty
-
getFlavor
-
addToolListener
-
setGraph
public void setGraph() -
setGraph
-
uninstall
protected void uninstall() -
getGraph
-
getWorkbenchGraphState
-
substituteSelection
-
getPathFor
-
getEventHandler
-
addMappings
- Specified by:
addMappings
in interfaceModifiableMap.Producer
-
initialize
- Specified by:
initialize
in interfacePanel
- Overrides:
initialize
in classPanelDecorator
-
installImpl
protected abstract void installImpl() -
pick
-
pickTool
-
isToolGraph
-
addEventListener
-
removeEventListener
-
dispose
public final void dispose()- Specified by:
dispose
in interfaceDisposable
- Overrides:
dispose
in classPanelDecorator
-
uninstallImpl
protected abstract void uninstallImpl() -
createEventHandler
-
setViewComponent
-
getViewComponent
Returns the view component which is used as a GUI component to perform the actual visualization of the graph.- Returns:
- view component of the GUI
-
setActiveTool
-
getActiveTool
-
treeNodesChanged
- Specified by:
treeNodesChanged
in interfaceTreeModelListener
-
treeNodesInserted
- Specified by:
treeNodesInserted
in interfaceTreeModelListener
-
treeNodesRemoved
- Specified by:
treeNodesRemoved
in interfaceTreeModelListener
-
treeStructureChanged
- Specified by:
treeStructureChanged
in interfaceTreeModelListener
-
eventOccured
Description copied from interface:EventListener
This method is invoked on registered event listeners whenevent
has occured. This general listener interface does not restrict the possible kinds of events. Concrete sources of events should specify which events they may fire.- Specified by:
eventOccured
in interfaceEventListener
- Parameters:
e
- an event
-
repaint
protected void repaint(int flags) -
render
-
renderToFile
-
disposeRenderer
-
setDimensions
public final void setDimensions(float magnitude) -
setDimensions
public final void setDimensions(float magnitude, float epsilon, float visualEpsilon) -
setEpsilon
public void setEpsilon(float epsilon) -
setVisualEpsilon
public void setVisualEpsilon(float visualEpsilon) -
setMagnitude
public void setMagnitude(float magnitude) -
getEpsilonSquared
public float getEpsilonSquared() -
getVisualEpsilonSquared
public float getVisualEpsilonSquared() -
getMagnitudeSquared
public float getMagnitudeSquared() -
fieldModified
- Specified by:
fieldModified
in interfaceManageable
-
getStamp
public int getStamp()Description copied from interface:Manageable
Returns a stamp for this object. Each modification to this object increments the stamp. The initial stamp is non-negative.- Specified by:
getStamp
in interfaceManageable
- Returns:
- a stamp
-
manageableReadResolve
- Specified by:
manageableReadResolve
in interfaceManageable
-
manageableWriteReplace
- Specified by:
manageableWriteReplace
in interfaceManageable
-
isInVisibleLayer
-
getVisibleLayers
public boolean[] getVisibleLayers() -
setVisibleLayers
public void setVisibleLayers(boolean[] l) -
isInVisibleScale
-
getSize
-
getVisibleScales
public boolean[] getVisibleScales() -
getEpsilon
public float getEpsilon() -
getVisualEpsilon
public float getVisualEpsilon() -
getMagnitude
public float getMagnitude() -
disableRepaint
public static void disableRepaint() -
enableRepaint
public static void enableRepaint() -
isRepaint
public static boolean isRepaint() -
nextTool
public void nextTool()Set the next ToolFactory from the getToolProperty to be active. Loop on the ToolFactories defined.
-