NSArray.ToArray Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| ToArray() |
Converts this NSArray to a C# array of NSObject, where NSNull elements are converted to |
| ToArray<TKey>() |
Converts this NSArray to a strongly-typed C# array, where NSNull elements are converted to |
ToArray<TKey>()
public TKey[] ToArray<TKey>() where TKey : class, ObjCRuntime.INativeObject;
public TKey?[] ToArray<TKey>() where TKey : class, ObjCRuntime.INativeObject;
member this.ToArray : unit -> 'Key[] (requires 'Key : null and 'Key :> ObjCRuntime.INativeObject)
Type Parameters
- TKey
The element type for the returned array. Must be a class that implements INativeObject.
Returns
A C# array of TKey elements. Elements that are NSNull in the source array are represented as null.