Interface StackListener<T>

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Interface Description
      static class  StackListener.Adapter<T>
      Deprecated.
      Since 2.1 and Java 8 the interface itself has default implementations.
      static class  StackListener.Listeners<T>
      Stack listeners.
    • Method Detail

      • itemPushed

        default void itemPushed​(Stack<T> stack,
                                T item)
        Called when an item has been pushed onto a stack.
        Parameters:
        stack - The stack that has changed.
        item - The newly pushed item.
      • itemPopped

        default void itemPopped​(Stack<T> stack,
                                T item)
        Called when an item has been popped off of a stack.
        Parameters:
        stack - The stack that has changed.
        item - The item newly popped from the stack.
      • stackCleared

        default void stackCleared​(Stack<T> stack)
        Called when a stack has been cleared.
        Parameters:
        stack - The newly cleared stack.
      • comparatorChanged

        default void comparatorChanged​(Stack<T> stack,
                                       java.util.Comparator<T> previousComparator)
        Called when a stack's comparator has changed.
        Parameters:
        stack - The stack in question.
        previousComparator - The previous comparator for this stack (if any).