Class BoundedStack<T>
- Namespace
- AlgorithmsSW.Stack
- Assembly
- AlgorithmsSW.dll
public class BoundedStack<T> : IStack<T>, IEnumerable<T>, IEnumerable
Type Parameters
T
- Inheritance
-
BoundedStack<T>
- Implements
-
IStack<T>IEnumerable<T>
- Inherited Members
- Extension Methods
Constructors
BoundedStack(int)
public BoundedStack(int maxSize)
Parameters
maxSize
int
Properties
Count
public int Count { get; }
Property Value
IsEmpty
public bool IsEmpty { get; }
Property Value
IsFull
public bool IsFull { get; }
Property Value
MaxSize
public int MaxSize { get; }
Property Value
Peek
public T Peek { get; }
Property Value
- T
Methods
Clear()
public void Clear()
GetEnumerator()
Returns an enumerator that iterates through the collection.
public IEnumerator<T> GetEnumerator()
Returns
- IEnumerator<T>
An enumerator that can be used to iterate through the collection.
Pop()
public T Pop()
Returns
- T
Push(T)
public void Push(T item)
Parameters
item
T