Share via


ArrayList Members

The following tables list the members exposed by the ArrayList type.

Public Constructors

Name Description
Public Method ArrayList Initializes a new instance of the ArrayList class.

Public Properties

Name Description
Public Property Capacity Gets or sets the number of objects that the ArrayList collection can contain.
Public Property Count Gets the number of objects that the ArrayList collection actually contains.
Public Property IsFixedSize Gets a value indicating whether the ArrayList collection has a fixed size.
Public Property IsReadOnly Gets a value indicating whether the ArrayList collection is read-only.
Public Property IsSynchronized Gets a value indicating whether access to the ArrayList collection is synchronized.
Public Property Item Gets or sets the object at the specified index number in the ArrayList collection.
Public Property SyncRoot Gets an object that you can use to synchronize access to the ArrayList collection.

Public Methods

Name Description
Public Method Add Adds a specified object to the end of the ArrayList collection.
Public Method BinarySearch Searches the entire sorted ArrayList collection for a specified object by using the specified comparer; returns the zero-based index number of the object.
Public Method Clear Removes all objects from the ArrayList collection.
Public Method Clone Creates a shallow copy of the ArrayList collection.
Public Method Contains Determines whether a specified object is contained in the ArrayList collection.
Public Method CopyTo Overloaded. Copies objects from the ArrayList collection to a specified one-dimensional array.
Public Method Equals (Inherited from Object.)
Public Method GetEnumerator Returns an enumerator for the entire ArrayList collection.
Public Method GetHashCode (Inherited from Object.)
Public Method GetType (Inherited from Object.)
Public Method IndexOf Overloaded. Returns the zero-based index number of the first occurrence of a specified object (if any) in either the entire ArrayList collection or a specified portion of it.
Public Method Insert Inserts a specified object into the ArrayList collection at a specified index number.
Public Method ReferenceEquals (Inherited from Object.)
Public Method Remove Removes the first occurrence of a specified object from the ArrayList collection.
Public Method RemoveAt Removes the object at the specified index number in the ArrayList collection.
Public Method ToArray Overloaded. Copies objects from the ArrayList collection to a new array.
Public Method ToString (Inherited from Object.)

Protected Methods

Name Description
Protected Method Finalize (Inherited from Object.)
Protected Method MemberwiseClone (Inherited from Object.)

See Also

Reference

ArrayList Class
System.Collections Namespace