Table of Contents

Class FunctionData

Namespace
NCalc.Handlers
Assembly
NCalc.Core.dll
public class FunctionData : IReadOnlyList<LogicalExpression>, IReadOnlyCollection<LogicalExpression>, IEnumerable<LogicalExpression>, IEnumerable
Inheritance
FunctionData
Implements
Inherited Members

Constructors

FunctionData(Guid, LogicalExpressionList, ExpressionContext, ILogicalExpressionVisitor<object?>, ILogicalExpressionVisitor<Task<object?>>?, CancellationToken)

public FunctionData(Guid id, LogicalExpressionList arguments, ExpressionContext context, ILogicalExpressionVisitor<object?> syncVisitor, ILogicalExpressionVisitor<Task<object?>>? asyncVisitor, CancellationToken cancellationToken)

Parameters

id Guid
arguments LogicalExpressionList
context ExpressionContext
syncVisitor ILogicalExpressionVisitor<object>
asyncVisitor ILogicalExpressionVisitor<Task<object>>
cancellationToken CancellationToken

Properties

CancellationToken

public CancellationToken CancellationToken { get; }

Property Value

CancellationToken

Context

public ExpressionContext Context { get; }

Property Value

ExpressionContext

Count

Gets the number of elements in the collection.

public int Count { get; }

Property Value

int

The number of elements in the collection.

Id

public Guid Id { get; }

Property Value

Guid

this[int]

Gets the element at the specified index in the read-only list.

public LogicalExpression this[int index] { get; }

Parameters

index int

The zero-based index of the element to get.

Property Value

LogicalExpression

The element at the specified index in the read-only list.

Methods

Evaluate(int)

public object? Evaluate(int index)

Parameters

index int

Returns

object

EvaluateAsync(int)

public Task<object?> EvaluateAsync(int index)

Parameters

index int

Returns

Task<object>

GetEnumerator()

Returns an enumerator that iterates through the collection.

public IEnumerator<LogicalExpression> GetEnumerator()

Returns

IEnumerator<LogicalExpression>

An enumerator that can be used to iterate through the collection.