Export (0) Print
Expand All

ImmutableArray Class

[This topic is preliminary and is subject to change.]

Provides methods for creating an array that is immutable; meaning it cannot be changed once it is created.

NuGet package: Microsoft.Bcl.Immutable (about immutable collections and how to install)

System.Object
  System.Collections.Immutable.ImmutableArray

Namespace:  System.Collections.Immutable
Assembly:  System.Collections.Immutable (in System.Collections.Immutable.dll)

public static class ImmutableArray

The ImmutableArray type exposes the following members.

  NameDescription
Public methodStatic memberBinarySearch<T>(ImmutableArray<T>, T) [This topic is preliminary and is subject to change.]
Searches the sorted immutable array for a specified element using the default comparer and returns the zero-based index of the element, if it’s found.
Public methodStatic memberBinarySearch<T>(ImmutableArray<T>, T, IComparer<T>) [This topic is preliminary and is subject to change.]
Searches a sorted immutable array for a specified element and returns the zero-based index of the element, if it’s found.
Public methodStatic memberBinarySearch<T>(ImmutableArray<T>, Int32, Int32, T) [This topic is preliminary and is subject to change.]
Searches a sorted immutable array for a specified element and returns the zero-based index of the element, if it’s found.
Public methodStatic memberBinarySearch<T>(ImmutableArray<T>, Int32, Int32, T, IComparer<T>) [This topic is preliminary and is subject to change.]
Searches a sorted immutable array for a specified element and returns the zero-based index of the element.
Public methodStatic memberCreate<T>() [This topic is preliminary and is subject to change.]
Creates an empty immutable array.
Public methodStatic memberCreate<T>(T) [This topic is preliminary and is subject to change.]
Creates an immutable array that contains the specified object.
Public methodStatic memberCreate<T>(T[]) [This topic is preliminary and is subject to change.]
Creates an immutable array from the specified array of objects.
Public methodStatic memberCreate<T>(IntPtr, Int32) [This topic is preliminary and is subject to change.]
Creates an ImmutableArray with the specified blittable elements from another array.
Public methodStatic memberCreate<T>(T, T) [This topic is preliminary and is subject to change.]
Creates an immutable array that contains the specified objects.
Public methodStatic memberCreate<T>(T, T, T) [This topic is preliminary and is subject to change.]
Creates an immutable array that contains the specified objects.
Public methodStatic memberCreate<T>(T[], Int32, Int32) [This topic is preliminary and is subject to change.]
Creates an immutable array with specified objects from another array.
Public methodStatic memberCreate<T>(ImmutableArray<T>, Int32, Int32) [This topic is preliminary and is subject to change.]
Creates an immutable array with the specified objects from another immutable array.
Public methodStatic memberCreate<T>(T, T, T, T) [This topic is preliminary and is subject to change.]
Creates an immutable array that contains the specified objects.
Public methodStatic memberCreate<T, TDerived>(ImmutableArray<TDerived>) [This topic is preliminary and is subject to change.]
Initializes a new instance of the ImmutableArray from the contents of the specified array, using a covariant static cast to reuse the existing array.
Public methodStatic memberCreateBuilder<T>() [This topic is preliminary and is subject to change.]
Creates a mutable array that can be converted to an ImmutableArray without allocating new memory.
Public methodStatic memberCreateBuilder<T>(Int32) [This topic is preliminary and is subject to change.]
Creates a mutable array that can be converted to an ImmutableArray without allocating new memory.
Public methodStatic memberCreateRange<T> [This topic is preliminary and is subject to change.]
Creates a new ImmutableArray<T> populated with the specified items.
Public methodStatic memberToImmutableArray<TSource> [This topic is preliminary and is subject to change.]
Creates an immutable array from the specified collection.
Top

This type is thread safe.

Show:
© 2014 Microsoft