Class GraphPlotter<T extends Node,S extends GeneralEdge<T>>

java.lang.Object
org.tweetyproject.graphs.util.GraphPlotter<T,S>
Type Parameters:
T - the node class of the graph which is to plot
S - the edge class of the grpah which is to plot
Direct Known Subclasses:
BpmnModelPlotter, DungTheoryPlotter, PetriNetPlotter, ReachabilityGraphPlotter, SerialisationGraphPlotter

public abstract class GraphPlotter<T extends Node,S extends GeneralEdge<T>> extends Object
A generic class for plotting graphs
Author:
Benedikt Knopp
  • Constructor Summary

    Constructors
    Constructor
    Description
    GraphPlotter(Plotter plotter, Graph<T> graph)
    Create a new instance
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Add some description to the panel
    void
    Parse the elements of the graph to visual elements and align them in a hierarchical (top-to-bottom) layout
    void
    createGraph(boolean isVertical)
    Parse the elements of the graph to visual elements and align them in a hierarchical layout in a specified orientation

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • GraphPlotter

      public GraphPlotter(Plotter plotter, Graph<T> graph)
      Create a new instance
      Parameters:
      plotter - the ground plotter
      graph - the graph to plot
  • Method Details

    • addLabels

      public void addLabels(List<String> labels)
      Add some description to the panel
      Parameters:
      labels - some labels that will be aligned vertically
    • createGraph

      public void createGraph()
      Parse the elements of the graph to visual elements and align them in a hierarchical (top-to-bottom) layout
    • createGraph

      public void createGraph(boolean isVertical)
      Parse the elements of the graph to visual elements and align them in a hierarchical layout in a specified orientation
      Parameters:
      isVertical - If TRUE layout of graph is "top-to-bottom", if FALSE, layout is "left-to-right"