类 Stack<T>

所有已实现的接口:
Serializable, Cloneable, Iterable<T>, Collection<T>, List<T>, RandomAccess

public class Stack<T> extends ArrayList<T>
A drop-in replacement for Stack based on ArrayList (instead of Vector) and therefore is (1) not synchronized and (2) faster.
另请参阅:
  • 构造器详细资料

    • Stack

      public Stack()
    • Stack

      public Stack(int initialCapacity)
    • Stack

      public Stack(@NotNull @NotNull Collection<? extends T> init)
    • Stack

      public Stack(@NotNull @NotNull T... items)
  • 方法详细资料

    • push

      public void push(T t)
    • peek

      public T peek()
    • pop

      public T pop()
    • tryPop

      @Nullable public T tryPop()
    • empty

      public boolean empty()
    • equals

      public boolean equals(Object o)
      指定者:
      equals 在接口中 Collection<T>
      指定者:
      equals 在接口中 List<T>
      覆盖:
      equals 在类中 ArrayList<T>