Class ModificationDAGInt

    • Method Detail

      • toposort

        @NotNull
        public List<Long> toposort()
        Description copied from class: DAG
        Get topologically sorted list of graph nodes (parents go before children)
        Specified by:
        toposort in class DAG<Long>
        Returns:
        see above
      • getParents

        @NotNull
        public List<Long> getParents​(@NotNull
                                     Long node)
        Description copied from class: DAG
        Get parents of the specified node
        Specified by:
        getParents in class DAG<Long>
        Parameters:
        node - node of interest
        Returns:
        see above
      • isEmpty

        public boolean isEmpty()
        Overrides:
        isEmpty in class DAG<Long>
      • hasParents

        public boolean hasParents​(@NotNull
                                  Long node)
        Description copied from class: DAG
        Returns true if the given node has parents
        Overrides:
        hasParents in class DAG<Long>
        Parameters:
        node - node of interest
        Returns:
        see above
      • containsNode

        public boolean containsNode​(@NotNull
                                    Long node)
        Description copied from class: DAG
        Check if graph contains specified node
        Specified by:
        containsNode in class DAG<Long>
        Parameters:
        node - node to check
        Returns:
        true if graph contains node, false otherwise
      • processNodesWithoutChildren

        protected void processNodesWithoutChildren​(@NotNull
                                                   ItemProcessor<Long> nodesProcessor)
        Description copied from class: DAG
        Passes nodes without children to the specified processor.
        Specified by:
        processNodesWithoutChildren in class DAG<Long>
      • getNodesWithoutParents

        @NotNull
        public List<Long> getNodesWithoutParents()
        Description copied from class: DAG
        Returns nodes without parents
        Specified by:
        getNodesWithoutParents in class DAG<Long>
        Returns:
        see above
      • size

        public int size()
        Description copied from class: DAG
        Returns number of nodes in the graph
        Specified by:
        size in class DAG<Long>
        Returns:
        see above
      • selfSize

        protected int selfSize()
      • getTail

        @NotNull
        protected DAG<Long> getTail()
      • getMaxNode

        public long getMaxNode()
        Specified by:
        getMaxNode in class BaseModificationDAG
        Returns:
        max node from the current DAG if it is not empty, otherwise returns 0