Click or drag to resize

WritableCollection<T> Class

A collection of IWritable items which itself also implements IWritable.
Inheritance Hierarchy
System.Object
  Ookii.Jumbo.IO.WritableCollection<T>

Namespace:  Ookii.Jumbo.IO
Assembly:  Ookii.Jumbo (in Ookii.Jumbo.dll) Version: 2.0.0
Syntax
public sealed class WritableCollection<T> : IList<T>, 
	ICollection<T>, IEnumerable<T>, IEnumerable, IWritable, IList, 
	ICollection
where T : IWritable

Type Parameters

T
The type of the item.

The WritableCollection<T> type exposes the following members.

Constructors
  NameDescription
Public methodWritableCollection<T>()
Initializes a new instance of the WritableCollection<T> class that is empty and has the default initial capacity.
Public methodWritableCollection<T>(IEnumerable<T>)
Initializes a new instance of the WritableCollection<T> class that contains elements copied from the specified collection and has sufficient capacity to accommodate the number of elements copied.
Public methodWritableCollection<T>(Int32)
Initializes a new instance of the WritableCollection<T> class that is empty and has the specified initial capacity.
Top
Properties
  NameDescription
Public propertyCount
Gets the number of elements actually contained in the WritableCollection<T>.
Public propertyItem
Gets or sets the element at the specified index.
Top
Methods
  NameDescription
Public methodAdd
Adds an object to the end of the WritableCollection<T>.
Public methodAddRange
Adds the elements of the specified collection to the end of the WritableCollection<T>.
Public methodClear
Removes all elements from the WritableCollection<T>.
Public methodContains
Determines whether an element is in the WritableCollection<T>.
Public methodCopyTo
Copies the entire WritableCollection<T> to a compatible one-dimensional array, starting at the specified index of the target array.
Public methodEquals
Determines whether the specified Object is equal to this instance.
(Overrides Object.Equals(Object).)
Public methodGetEnumerator
Returns an enumerator that iterates through the WritableCollection<T>.
Public methodGetHashCode
Returns a hash code for this instance.
(Overrides Object.GetHashCode().)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIndexOf
Searches for the specified object and returns the zero-based index of the first occurrence within the range of elements in the WritableCollection<T> that extends from the specified index to the last element.
Public methodInsert
Inserts an element into the WritableCollection<T> at the specified index.
Public methodRead
Reads the object from the specified reader.
Public methodRemove
Removes the first occurrence of a specific object from the WritableCollection<T>.
Public methodRemoveAt
Removes the element at the specified index of the WritableCollection<T>.
Public methodToString
Returns a String that represents this instance.
(Overrides Object.ToString().)
Public methodWrite
Writes the object to the specified writer.
Top
Extension Methods
  NameDescription
Public Extension MethodGetSequenceHashCode<T>
Gets the hash code for the specified sequence of elements.
(Defined by ListExtensions.)
Public Extension MethodOrderBy<T, TKey>
Sorts the elements of a sequence in ascending or descending order according to a key.
(Defined by ListExtensions.)
Public Extension MethodRandomize<T>()Overloaded.
Randomizes the specified list.
(Defined by ListExtensions.)
Public Extension MethodRandomize<T>(Random)Overloaded.
Randomizes the specified list.
(Defined by ListExtensions.)
Public Extension MethodSwap<T>
Swaps two elements in the specified list.
(Defined by ListExtensions.)
Public Extension MethodToDelimitedString<T>()Overloaded.
Creates a string with the items of a list separated by a comma.
(Defined by ListExtensions.)
Public Extension MethodToDelimitedString<T>(String)Overloaded.
Creates a string with the items of a list separated by the specified delimiter.
(Defined by ListExtensions.)
Top
Remarks

You cannot add null as an item in this collection.

See Also