NSArray.FromStrings Method

Definition

Overloads

Name Description
FromStrings(IReadOnlyList<String>)

Creates an NSArray from a list of C# strings.

FromStrings(String[])

Creates an NSArray from a C# array of strings.

FromStrings(IReadOnlyList<String>)

Creates an NSArray from a list of C# strings.

public static Foundation.NSArray FromStrings(System.Collections.Generic.IReadOnlyList<string> items);
public static Foundation.NSArray FromStrings(System.Collections.Generic.IReadOnlyList<string?> items);
static member FromStrings : System.Collections.Generic.IReadOnlyList<string> -> Foundation.NSArray

Parameters

items
IReadOnlyList<String>

List of C# strings.

Returns

A new NSArray containing the strings.

Remarks

If any string in items is null, a NSNull entry will be created for that element.

Applies to

FromStrings(String[])

Creates an NSArray from a C# array of strings.

public static Foundation.NSArray FromStrings(params string[] items);
public static Foundation.NSArray FromStrings(params string?[] items);
static member FromStrings : string[] -> Foundation.NSArray

Parameters

items
String[]

Array of C# strings.

Returns

A new NSArray containing the strings.

Remarks

If any string in items is null, a NSNull entry will be created for that element.

Applies to