Table of Contents

Class ExpressionsService

Namespace
JJMasterData.Core.DataManager.Expressions
Assembly
JJMasterData.Core.dll
public class ExpressionsService
Inheritance
ExpressionsService
Inherited Members

Constructors

ExpressionsService(IEnumerable<IExpressionProvider>, ExpressionParser, IEncryptionService, ILogger<ExpressionsService>)

public ExpressionsService(IEnumerable<IExpressionProvider> expressionProviders, ExpressionParser expressionParser, IEncryptionService encryptionService, ILogger<ExpressionsService> logger)

Parameters

expressionProviders IEnumerable<IExpressionProvider>
expressionParser ExpressionParser
encryptionService IEncryptionService
logger ILogger<ExpressionsService>

Methods

GetBoolValue(string?, FormStateData)

public bool GetBoolValue(string? expression, FormStateData formStateData)

Parameters

expression string
formStateData FormStateData

Returns

bool

GetDefaultValueAsync(FormElementFieldSelector, FormStateData)

public ValueTask<object?> GetDefaultValueAsync(FormElementFieldSelector fieldSelector, FormStateData formStateData)

Parameters

fieldSelector FormElementFieldSelector
formStateData FormStateData

Returns

ValueTask<object>

GetExpressionValue(string?, FormStateData)

public object? GetExpressionValue(string? expression, FormStateData formStateData)

Parameters

expression string
formStateData FormStateData

Returns

object

GetTriggerValueAsync(FormElementFieldSelector, FormStateData)

public ValueTask<object?> GetTriggerValueAsync(FormElementFieldSelector fieldSelector, FormStateData formStateData)

Parameters

fieldSelector FormElementFieldSelector
formStateData FormStateData

Returns

ValueTask<object>

ParseExpression(string, FormStateData)

public Dictionary<string, object?> ParseExpression(string expression, FormStateData formStateData)

Parameters

expression string
formStateData FormStateData

Returns

Dictionary<string, object>

ReplaceExpressionWithParsedValues(string?, FormStateData, bool)

public string? ReplaceExpressionWithParsedValues(string? expression, FormStateData formStateData, bool encryptValues = false)

Parameters

expression string
formStateData FormStateData
encryptValues bool

Returns

string