Class SwingGraphStreamer
java.lang.Object
org.bigraphs.framework.visualization.SwingGraphStreamer
Swing-based GraphStream-based renderer for
PureBigraphs.
Builds a Graph and displays it via a GraphStream Viewer (Swing UI).
Supports optional rendering of roots/sites, dark mode styling.
Typical usage
prepareSystemEnvironment()(sets UI system properties for Swing)getGraphViewer()orgetGraphViewer(String)to build+display
- Author:
- Dominik Grzelak
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSwingGraphStreamer(PureBigraph bigraph) SwingGraphStreamer(PureBigraph bigraph, boolean withSites, boolean withRoots) SwingGraphStreamer(PureBigraph bigraph, boolean withSites, boolean withRoots, boolean darkMode) -
Method Summary
Modifier and TypeMethodDescriptionorg.graphstream.graph.GraphgetGraph()Get the underlying graph object for the visualization with GraphStreamorg.graphstream.ui.view.ViewerGraphStream Visualization.org.graphstream.ui.view.ViewergetGraphViewer(String graphId) GraphStream Visualizationorg.graphstream.ui.view.ViewervoidvoidvoidSets some system properties so that the UI can be shown.renderAsync(int delayPerElement) renderAsync(String graphId, int delayPerElement) renderRoots(boolean withRoots) renderSites(boolean withSites)
-
Constructor Details
-
SwingGraphStreamer
- Parameters:
bigraph- the bigraph to be rendered
-
SwingGraphStreamer
- Parameters:
bigraph- the bigraph to be renderedwithSites- draw sites?withRoots- draw roots?
-
SwingGraphStreamer
public SwingGraphStreamer(PureBigraph bigraph, boolean withSites, boolean withRoots, boolean darkMode)
-
-
Method Details
-
prepareSystemEnvironment
public void prepareSystemEnvironment()Sets some system properties so that the UI can be shown. Otherwise, an exception might be thrown: "No UI package detected! Please use System.setProperty("org.graphstream.ui") for the selected package." -
initGraph
-
initViewer
public void initViewer() -
getGraph
public org.graphstream.graph.Graph getGraph()Get the underlying graph object for the visualization with GraphStream- Returns:
-
getGraphViewer
public org.graphstream.ui.view.Viewer getGraphViewer()GraphStream Visualization. Returns the Viewer, which is responsible for the actual display of the bigraph.- Returns:
-
getGraphViewer
GraphStream Visualization- Parameters:
graphId- graphId of the window- Returns:
-
renderAsync
-
renderAsync
-
getViewer
public org.graphstream.ui.view.Viewer getViewer() -
renderSites
-
renderRoots
-