Package ptolemy.graph

Class GraphException

    • Constructor Summary

      Constructors 
      Constructor Description
      GraphException()
      The default constructor without arguments.
      GraphException​(java.lang.String message)
      Constructor with an argument of text description.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      protected static java.lang.String _elementDump​(java.lang.Object element, Graph graph, java.lang.String elementDescriptor)
      Return a dump of an element (Node, Edge, or weight) and the container graph suitable to be appended to an error message.
      static java.lang.String elementDump​(Element element, Graph graph)
      Return a dump of a graph element and the container graph suitable to be appended to an error message.
      static java.lang.String graphDump​(Graph graph)
      Return a dump of this graph suitable to be appended to an error message.
      static java.lang.String weightDump​(java.lang.Object weight)
      Return a dump of a weight and the container graph suitable to be appended to an error message.
      • Methods inherited from class java.lang.Throwable

        addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • GraphException

        public GraphException()
        The default constructor without arguments.
      • GraphException

        public GraphException​(java.lang.String message)
        Constructor with an argument of text description.
        Parameters:
        message - The exception message.
    • Method Detail

      • graphDump

        public static java.lang.String graphDump​(Graph graph)
        Return a dump of this graph suitable to be appended to an error message.
        Parameters:
        graph - The graph to dump.
        Returns:
        A text string dump of the graph.
      • elementDump

        public static java.lang.String elementDump​(Element element,
                                                   Graph graph)
        Return a dump of a graph element and the container graph suitable to be appended to an error message.
        Parameters:
        element - The element to dump.
        graph - The graph where the element resides.
        Returns:
        A text string dump of the element and graph.
      • weightDump

        public static java.lang.String weightDump​(java.lang.Object weight)
        Return a dump of a weight and the container graph suitable to be appended to an error message. Generally, an elementDump(Element, Graph) follows.
        Parameters:
        weight - The weight to dump.
        Returns:
        A text string dump of the weight and graph.
      • _elementDump

        protected static java.lang.String _elementDump​(java.lang.Object element,
                                                       Graph graph,
                                                       java.lang.String elementDescriptor)
        Return a dump of an element (Node, Edge, or weight) and the container graph suitable to be appended to an error message.
        Parameters:
        element - The element to dump.
        graph - The container graph.
        elementDescriptor - Descriptor of the element.
        Returns:
        A text string dump of the element and graph.