Class Not
- Namespace
- BotManager.Runtime.Expressions
- Assembly
- BotManager.Runtime.dll
Inverts the given boolean expression.
Return type is bool.
false:
{ "$Not": true }
This json example returns true:
{ "$Not": false }
[JsonConverter(typeof(NotConverter))]
public sealed class Not : IExpression
- Inheritance
-
Not
- Implements
- Inherited Members
Constructors
Not()
Empty constructor for serialization.
public Not()
Not(IExpression?)
Creates an expression that inverts the given expression.
public Not(IExpression? expression)
Parameters
expressionIExpression
Properties
Expression
Gets and sets the expression
[JsonRootProperty]
public IExpression? Expression { get; set; }
Property Value
Methods
ExecuteAsync(RuntimeContext, Type?)
Executes the expression in the given RuntimeContext. Please do not use this method to run an expression. Use ExecuteAsync(IExpression?) instead.
public Task<object?> ExecuteAsync(RuntimeContext context, Type? returnType)
Parameters
contextRuntimeContextThe current runtime context.
returnTypeTypeThe expected return type. Use
typeof(object)for a generic result. Usenullif you don't need the return value.