Class GraphContext

    • Constructor Detail

      • GraphContext

        public GraphContext​(Graph graph)
                     throws GraphException
        Creates a GraphContext for the given graph and a logger.
        Parameters:
        graph - the Graph to create the context for
        Throws:
        GraphException - if the graph context could not be created
      • GraphContext

        public GraphContext​(Graph graph,
                            Operator graphOp)
                     throws GraphException
        Creates a GraphContext for the given graph and a logger.
        Parameters:
        graph - the Graph to create the context for
        Throws:
        GraphException - if the graph context could not be created
    • Method Detail

      • dispose

        public void dispose()
        Disposes this GraphContext.
      • getGraph

        public Graph getGraph()
        Gets the Graph of this context.
        Returns:
        the Graph
      • getLogger

        public Logger getLogger()
        Gets the @link Logger} of this context.
        Returns:
        the logger
      • setPreferredTileSize

        public void setPreferredTileSize​(Dimension preferredTileSize)
        Sets the preferred tile size.
        Parameters:
        preferredTileSize - the preferred tile size
      • getOutputProducts

        public Product[] getOutputProducts()
        Returns an array containing the output products generated by this graph's output nodes, i.e. nodes that are not input to other nodes.
        Returns:
        an array containing the output products of this graph
      • getNodeContext

        public NodeContext getNodeContext​(Node node)
        Gets the NodeContext of the given node.
        Parameters:
        node - the node to get the context for
        Returns:
        the NodeContext of the given node or null if it's not contained in this context