Interface ILinkedNode<T>

  • Type Parameters:
    T - the generic type of the value
    All Known Implementing Classes:
    LinkedNode

    public interface ILinkedNode<T>
    The interface ILinkedNode represents a chainable object with a generic value
    • Method Detail

      • getNext

        ILinkedNode<T> getNext()
        Gets the next object
        Returns:
        the next object
      • getNextCount

        default int getNextCount()
        Gets the next count.
        Returns:
        the next count
      • getNextLinkedNodes

        default java.util.List<ILinkedNode<T>> getNextLinkedNodes()
        Gets all next ILinkedNode from the current linked node
        Returns:
        all next ILinkedNode from the current linked node
      • getPrevious

        ILinkedNode<T> getPrevious()
        Gets the previous object
        Returns:
        the previous object
      • getPreviousCount

        default int getPreviousCount()
        Gets the next count.
        Returns:
        the next count
      • getPreviousLinkedNodes

        default java.util.List<ILinkedNode<T>> getPreviousLinkedNodes()
        Gets all previous ILinkedNode from the current linked node
        Returns:
        all previous ILinkedNode from the current linked node
      • getValue

        T getValue()
        Gets the value
        Returns:
        the value
      • hasNext

        default boolean hasNext()
        Checks if this tree node has a next object
        Returns:
        true, if successful
      • hasPrevious

        default boolean hasPrevious()
        Checks for previous object
        Returns:
        true, if successful
      • isFirst

        default boolean isFirst()
        Checks if this is the first object
        Returns:
        true, if is first
      • setNext

        void setNext​(ILinkedNode<T> next)
        Sets the next object
        Parameters:
        next - the new next object
      • setPrevious

        void setPrevious​(ILinkedNode<T> previous)
        Sets the previous object
        Parameters:
        previous - the new previous object
      • setValue

        void setValue​(T value)
        Sets the value.
        Parameters:
        value - the new value
      • toList

        default java.util.List<ILinkedNode<T>> toList()
        Transforms this linked node object to an ordered LinkedList with all nodes
        Returns:
        the ordered LinkedList with all nodes