Click or drag to resize
StackT Class
Represents a variable size last-in-first-out (LIFO) collection of instances of the same arbitrary type.
Inheritance Hierarchy
SystemObject
  System.Collections.GenericStackT

Namespace: System.Collections.Generic
Assembly: CSharpXamlForHtml5.System.dll (in CSharpXamlForHtml5.System.dll.dll) Version: 1.0.0.0
Syntax
C#
public class Stack<T> : IEnumerable<T>, ICollection, 
	IEnumerable

Type Parameters

T
Specifies the type of elements in the stack.

The StackT type exposes the following members.

Constructors
  NameDescription
Public methodStackT
Initializes a new instance of the StackT class that is empty and has the default initial capacity.
Public methodStackT(IEnumerableT)
Initializes a new instance of the StackT class that contains elements copied from the specified collection and has sufficient capacity to accommodate the number of elements copied.
Public methodStackT(Int32)
Initializes a new instance of the StackT class that is empty and has the specified initial capacity or the default initial capacity, whichever is greater.
Top
Methods
  NameDescription
Public methodClear
Removes all objects from the StackT.
Public methodContains
Determines whether an element is in the StackT.
Public methodCopyTo
Copies the StackT to an existing one-dimensional Array, starting at the specified array index.
Public methodEquals(Object)
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodGetEnumerator
Returns an enumerator for the StackT.
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodPeek
Returns the object at the top of the StackT without removing it.
Public methodPop
Removes and returns the object at the top of the StackT.
Public methodPush
Inserts an object at the top of the StackT.
Public methodToArray
Copies the StackT to a new array.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodTrimExcess
Sets the capacity to the actual number of elements in the StackT, if that number is less than 90 percent of current capacity.
Top
Properties
  NameDescription
Public propertyCount
Gets the number of elements contained in the StackT.
Top
See Also