JArrayExtensions.GetGuid method

Version 1.1.28
.NET Framework 4.8
Namespace Skybrud.Essentials.Json.Extensions
Assembly Skybrud.Essentials.dll

GetGuid(JArray, int)

Extension method

Gets the GUID value from array at the specified index.

public static Guid GetGuid(this JArray array, int index)

Parameters

array JArray

The array.

index int

The index of the item holding the GUID value.

Returns

An instance of Guid .

GetGuid(JArray, string)

Extension method

Gets the GUID value of the token matching the specified path, or System.Guid.Empty if path doesn't match a token.

public static Guid GetGuid(this JArray array, string path)

Parameters

array JArray

The array.

path String

A String that contains a JPath expression.

Returns

An instance of Guid .

GetGuid(JArray, int, Guid)

Extension method

Gets the GUID value from array at the specified index.

public static Guid GetGuid(this JArray array, int index, Guid fallback)

Parameters

array JArray

The array.

index int

The index of the item holding the GUID value.

fallback Guid

The fallback value.

Returns

An instance of Guid .

GetGuid(JArray, string, Guid)

Extension method

Gets the GUID value of the token matching the specified path, or the value of fallback if path doesn't match a token.

public static Guid GetGuid(this JArray array, string path, Guid fallback)

Parameters

array JArray

The array.

path String

A String that contains a JPath expression.

fallback Guid

The fallback value.

Returns

An instance of Guid .