Class Display2D
java.lang.Object
repast.simphony.visualization.AbstractDisplay
repast.simphony.visualization.visualization2D.Display2D
- All Implemented Interfaces:
WindowListener
,EventListener
,Renderer
,ProjectionListener
,IDisplay
Deprecated.
replaced by ogl 2D
-
Nested Class Summary
Nested classes/interfaces inherited from interface repast.simphony.visualization.IDisplay
IDisplay.LayoutFrequency
-
Field Summary
Modifier and TypeFieldDescriptionprotected RepastCanvas2D
Deprecated.protected Map<Class,
IDisplayLayer2D> Deprecated.protected Map<String,
ProjectionDecorator2D> Deprecated.static int
Deprecated.static int
Deprecated.protected boolean
Deprecated.protected org.piccolo2d.nodes.PPath
Deprecated.protected org.piccolo2d.nodes.PPath
Deprecated.protected boolean
Deprecated.protected DisplayData<?>
Deprecated.protected Object
Deprecated.protected Layout
Deprecated.protected LayoutUpdater
Deprecated.protected final Object
Deprecated.protected Map<Object,
IDisplayLayer2D> Deprecated.protected JPanel
Deprecated.protected boolean
Deprecated.protected Runnable
Deprecated.protected boolean
Deprecated.protected repast.simphony.visualization.visualization2D.Display2D.Updater
Deprecated.protected ValueDisplayLayer2D
Deprecated.protected Iterable<ValueLayer>
Deprecated.Fields inherited from class repast.simphony.visualization.AbstractDisplay
dlSupport, FRAME_UPDATE_INTERVAL, INFO_CURSOR, lastRenderTS, probeSupport
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
Deprecated.void
closed()
Deprecated.Notifies this IDisplay that its associated gui widget has been closed.createEditor
(JPanel panel) Deprecated.Creates an DisplayEditor appropriate for editing this display.void
Deprecated.void
Deprecated.Notifies this IDisplay that its associated gui widget has been deIconified.void
destroy()
Deprecated.Destroys the display, allowing it to free any resources it may have acquired.protected IDisplayLayer2D
Deprecated.findObjForItem
(org.piccolo2d.PNode node) Deprecated.Finds the object for which the specified PNode is the representation.void
Deprecated.Need to render displays when the sim is paused and initialized, because the display won't render with Display2D.render() if it is hidden.Deprecated.Gets the data used to initialize this display.Deprecated.Gets the layout.getPanel()
Deprecated.Gets a panel that contains the actual gui for visualization.getprobedObjects
(org.piccolo2d.util.PPickPath path, Point2D probeLocation) Deprecated.Returns a list of agents at the probe locationDeprecated.Gets the classes for which styles have been registered.org.piccolo2d.PNode
Deprecated.void
Deprecated.Notifies this IDisplay that its associated gui widget has been iconified.void
init()
Deprecated.Initializes the display.protected void
Deprecated.protected void
moveObject
(Object o) Deprecated.void
registerDecorator
(ProjectionDecorator2D decorator) Deprecated.void
registerNetworkStyle
(Network topology, EdgeStyle2D style) Deprecated.void
registerStyle
(Class clazz, Style2D style) Deprecated.void
registerToolBar
(JToolBar bar) Deprecated.Registers the specified toolbar with this IDisplay.void
Deprecated.protected void
Deprecated.void
render()
Deprecated.The render method is alled each time the simulation runner thread steps the schedule.void
Deprecated.Resets the home (initial) view of the displayvoid
setBackgroundColor
(Color color) Deprecated.void
Deprecated.void
Deprecated.Sets the Layout for the display to use.void
setLayoutFrequency
(IDisplay.LayoutFrequency frequency, int interval) Deprecated.Sets the frequency of the layout.void
setPause
(boolean pause) Deprecated.Pause the rendering.void
Deprecated.void
update()
Deprecated.The update method is called according to the frequency in the display descriptor.void
windowActivated
(WindowEvent arg0) Deprecated.void
windowClosed
(WindowEvent arg0) Deprecated.void
windowClosing
(WindowEvent arg0) Deprecated.void
windowDeactivated
(WindowEvent arg0) Deprecated.void
Deprecated.void
Deprecated.void
windowOpened
(WindowEvent arg0) Deprecated.Methods inherited from class repast.simphony.visualization.AbstractDisplay
addDisplayListener, addProbeListener, createInfoCursor, getProbeSupport, projectionEventOccurred, setProbeSupport
-
Field Details
-
DISPLAY_HEIGHT
public static int DISPLAY_HEIGHTDeprecated. -
DISPLAY_WIDTH
public static int DISPLAY_WIDTHDeprecated. -
lock
Deprecated. -
classStyleMap
Deprecated. -
objectStyleMap
Deprecated. -
valueDisplayLayer
Deprecated. -
layout
Deprecated. -
layoutUpdater
Deprecated. -
initData
Deprecated. -
iconified
protected boolean iconifiedDeprecated. -
panel
Deprecated. -
renderer
Deprecated. -
updater
protected repast.simphony.visualization.visualization2D.Display2D.Updater updaterDeprecated. -
canvas
Deprecated. -
decoratorMap
Deprecated. -
valueLayers
Deprecated. -
doRender
protected boolean doRenderDeprecated. -
showHoverProbes
protected boolean showHoverProbesDeprecated. -
hoverProbe
protected org.piccolo2d.nodes.PPath hoverProbeDeprecated. -
hoverProbeBox
protected org.piccolo2d.nodes.PPath hoverProbeBoxDeprecated. -
lastProbedObject
Deprecated. -
pause
protected boolean pauseDeprecated.
-
-
Constructor Details
-
Display2D
Deprecated.
-
-
Method Details
-
getInitData
Deprecated.Gets the data used to initialize this display.- Returns:
- the data used to initialize this display.
-
initScene
protected void initScene()Deprecated. -
findObjForItem
Deprecated.Finds the object for which the specified PNode is the representation.- Parameters:
node
- the representational PNode- Returns:
- the object for which the specified PNode is the representation or null if the object is not found.
-
getprobedObjects
Deprecated.Returns a list of agents at the probe location- Parameters:
path
- the path at the probe locationprobeLocation
- the probe location- Returns:
- the list of agents at the probe location.
-
registerDecorator
Deprecated. -
init
public void init()Deprecated.Description copied from interface:IDisplay
Initializes the display. Called once before the display is made visible. -
setBoundingBox
Deprecated. -
registerStyle
Deprecated. -
registerNetworkStyle
Deprecated. -
registerValueLayerStyle
Deprecated. -
createPanel
public void createPanel()Deprecated. -
render
public void render()Deprecated.The render method is alled each time the simulation runner thread steps the schedule. -
forceRender
public void forceRender()Deprecated.Need to render displays when the sim is paused and initialized, because the display won't render with Display2D.render() if it is hidden. -
destroy
public void destroy()Deprecated.Description copied from class:AbstractDisplay
Destroys the display, allowing it to free any resources it may have acquired.- Specified by:
destroy
in interfaceIDisplay
- Overrides:
destroy
in classAbstractDisplay
-
getPanel
Deprecated.Description copied from interface:IDisplay
Gets a panel that contains the actual gui for visualization. -
addObject
Deprecated.- Specified by:
addObject
in classAbstractDisplay
-
moveObject
Deprecated.- Specified by:
moveObject
in classAbstractDisplay
-
findLayer
Deprecated. -
removeObject
Deprecated.- Specified by:
removeObject
in classAbstractDisplay
-
setLayout
Deprecated.Description copied from interface:IDisplay
Sets the Layout for the display to use. -
setLayoutFrequency
Deprecated.Description copied from interface:IDisplay
Sets the frequency of the layout.- Specified by:
setLayoutFrequency
in interfaceIDisplay
- Parameters:
frequency
- the frequency of the layoutinterval
- the interval if the frequency is AT_INTERVAL. The interval is in terms of number of calls to update()
-
update
public void update()Deprecated.The update method is called according to the frequency in the display descriptor. First the layoutUpdater.update() is called to calculate the new positions for objects, then the doRender flag is set so that the next render() call renders the updates, then the updater runnable is executed in the event dispatch thread. -
getVisualItem
Deprecated. -
windowActivated
Deprecated.- Specified by:
windowActivated
in interfaceWindowListener
-
windowClosed
Deprecated.- Specified by:
windowClosed
in interfaceWindowListener
-
windowClosing
Deprecated.- Specified by:
windowClosing
in interfaceWindowListener
-
windowDeactivated
Deprecated.- Specified by:
windowDeactivated
in interfaceWindowListener
-
windowDeiconified
Deprecated.- Specified by:
windowDeiconified
in interfaceWindowListener
-
windowIconified
Deprecated.- Specified by:
windowIconified
in interfaceWindowListener
-
windowOpened
Deprecated.- Specified by:
windowOpened
in interfaceWindowListener
-
setPause
public void setPause(boolean pause) Deprecated.Description copied from interface:Renderer
Pause the rendering. The Renderer should update and render if pause is true, if possible. The rendering should take place asynchronously on the AWT thread. -
iconified
public void iconified()Deprecated.Notifies this IDisplay that its associated gui widget has been iconified. -
closed
public void closed()Deprecated.Notifies this IDisplay that its associated gui widget has been closed. -
deIconified
public void deIconified()Deprecated.Notifies this IDisplay that its associated gui widget has been deIconified.- Specified by:
deIconified
in interfaceIDisplay
-
getLayout
Deprecated.Gets the layout. -
getRegisteredClasses
Deprecated.Gets the classes for which styles have been registered.- Returns:
- the classes for which styles have been registered.
-
createEditor
Deprecated.Creates an DisplayEditor appropriate for editing this display.- Specified by:
createEditor
in interfaceIDisplay
- Parameters:
panel
- a JPanel with a BorderLayout to which editor components can be added- Returns:
- an DisplayEditor appropriate for editing this display or null if this display cannot be edited.
-
resetHomeView
public void resetHomeView()Deprecated.Description copied from interface:IDisplay
Resets the home (initial) view of the display- Specified by:
resetHomeView
in interfaceIDisplay
-
setBackgroundColor
Deprecated. -
registerToolBar
Deprecated.Description copied from class:AbstractDisplay
Registers the specified toolbar with this IDisplay. This IDisplay can then put buttons etc. are on this toolbar. This is a default no-op implementation.- Specified by:
registerToolBar
in interfaceIDisplay
- Overrides:
registerToolBar
in classAbstractDisplay
- Parameters:
bar
- the bar to register
-
toggleInfoProbe
public void toggleInfoProbe()Deprecated.
-