Show / Hide Table of Contents

Constructor ArcadeExpression

ArcadeExpression(String)

Initializes a new instance of the ArcadeExpression class with an expression script.

Declaration
public ArcadeExpression(string expression)
Parameters
Type Name Description
System.String expression

The expression to be evaluated. If set to an empty expression string then the evaluation will return null.

Remarks

The Title and Name will default to empty strings. The ReturnType will default to Automatic.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.11 - 100.15
.NET 6.0100.13 - 100.15
.NET 6.0 Windows100.13 - 100.15
.NET Framework100.11 - 100.15
.NET 5100.11 - 100.12
.NET Core 3.1100.11 - 100.12
Xamarin.Android100.11 - 100.15
Xamarin.iOS100.11 - 100.15
UWP100.11 - 100.15

ArcadeExpression(String, String, String)

Initializes a new instance of the ArcadeExpression class.

Declaration
public ArcadeExpression(string expression, string title, string name)
Parameters
Type Name Description
System.String expression

The expression to be evaluated. If set to an empty expression string then the evaluation will return null.

System.String title

The title of the expression.

System.String name

The name of the expression.

Remarks

The ReturnType will default to Automatic.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.11 - 100.15
.NET 6.0100.13 - 100.15
.NET 6.0 Windows100.13 - 100.15
.NET Framework100.11 - 100.15
.NET 5100.11 - 100.12
.NET Core 3.1100.11 - 100.12
Xamarin.Android100.11 - 100.15
Xamarin.iOS100.11 - 100.15
UWP100.11 - 100.15

ArcadeExpression(String, String, String, ArcadeExpressionReturnType)

Initializes a new instance of the ArcadeExpression class.

Declaration
public ArcadeExpression(string expression, string title, string name, ArcadeExpressionReturnType returnType)
Parameters
Type Name Description
System.String expression

The Arcade expression to be evaluated. If set to an empty expression string then the evaluation will return zero, false, an empty string, or null, depending on whether the returnType is Number, Boolean, String or anything else, respectively.

System.String title

The title of the expression.

System.String name

The name of the expression.

ArcadeExpressionReturnType returnType

Type of the evaluated value. If the Arcade expression creates results of a different type (e.g. a Date or an Array) then the result will be cast to the expected return type. If no sensible cast can be carried out, then the result will be null.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.11 - 100.15
.NET 6.0100.13 - 100.15
.NET 6.0 Windows100.13 - 100.15
.NET Framework100.11 - 100.15
.NET 5100.11 - 100.12
.NET Core 3.1100.11 - 100.12
Xamarin.Android100.11 - 100.15
Xamarin.iOS100.11 - 100.15
UWP100.11 - 100.15
In This Article
Back to top Copyright © 2022 Esri.