Class Motor
Assembly: RCaron.dll
Declaration
csharp
Declaration
csharp
Properties
Lines
Declaration
csharp
public IList<Line> Lines { get; set; }
Declaration
csharp
public IList<Line> Lines { get; set; }
BlockStack
Declaration
csharp
public NiceStack<Motor.StackThing> BlockStack { get; set; }
Declaration
csharp
public NiceStack<Motor.StackThing> BlockStack { get; set; }
MainFileScope
Declaration
csharp
public FileScope MainFileScope { get; set; }
Declaration
csharp
public FileScope MainFileScope { get; set; }
Options
Declaration
csharp
public MotorOptions Options { get; }
Declaration
csharp
public MotorOptions Options { get; }
ElseState
If true and meets an else(if), it will be skipped.
Declaration
csharp
public bool ElseState { get; set; }
Declaration
csharp
public bool ElseState { get; set; }
GlobalScope
Declaration
csharp
public LocalScope GlobalScope { get; set; }
Declaration
csharp
public LocalScope GlobalScope { get; set; }
CurrentLineIndex
Declaration
csharp
public int CurrentLineIndex { get; }
Declaration
csharp
public int CurrentLineIndex { get; }
Methods
UseContext(RCaronParserContext, bool)
Declaration
csharp
public void UseContext(RCaronParserContext parserContext, bool withFileScope = true)
Declaration
csharp
public void UseContext(RCaronParserContext parserContext, bool withFileScope = true)
Parameters
Run(int)
Declaration
csharp
public object? Run(int startIndex = 0)
Declaration
csharp
public object? Run(int startIndex = 0)
Returns
System.Object
Parameters
Type | Name |
---|
System.Int32 | startIndex |
GetLineNumber(FileScope?, int?)
Declaration
csharp
public int GetLineNumber(FileScope? fileScope = null, int? position = null)
Declaration
csharp
public int GetLineNumber(FileScope? fileScope = null, int? position = null)
Returns
System.Int32
Parameters
RunLine(Line)
Declaration
csharp
public (bool Exit, object? Result) RunLine(Line baseLine)
Declaration
csharp
public (bool Exit, object? Result) RunLine(Line baseLine)
Returns
System.ValueTuple<System.Boolean,System.Object>
Parameters
RunCodeBlock(CodeBlockToken)
Declaration
csharp
public object? RunCodeBlock(CodeBlockToken codeBlock)
Declaration
csharp
public object? RunCodeBlock(CodeBlockToken codeBlock)
Returns
System.Object
Parameters
RunLinesList(IList<Line>)
Declaration
csharp
public object? RunLinesList(IList<Line> lines)
Declaration
csharp
public object? RunLinesList(IList<Line> lines)
Returns
System.Object
Parameters
Type | Name |
---|
System.Collections.Generic.IList<RCaron.Line> | lines |
MethodCall(string, ArraySegment<PosToken>, CallLikePosToken?, object?, Pipeline?, bool)
Declaration
csharp
public object? MethodCall(string nameArg, ArraySegment<PosToken> argumentTokens = default, CallLikePosToken? callToken = null, object? instance = null, Pipeline? pipeline = null, bool isLeftOfPipeline = false)
Declaration
csharp
public object? MethodCall(string nameArg, ArraySegment<PosToken> argumentTokens = default, CallLikePosToken? callToken = null, object? instance = null, Pipeline? pipeline = null, bool isLeftOfPipeline = false)
Returns
System.Object
Parameters
GetAssigner(Span<PosToken>)
Declaration
csharp
public IAssigner GetAssigner(Span<PosToken> tokens)
Declaration
csharp
public IAssigner GetAssigner(Span<PosToken> tokens)
Returns
RCaron.IAssigner
Parameters
Type | Name |
---|
System.Span<RCaron.PosToken> | tokens |
EvaluateDotThingsAsPath(ReadOnlySpan<PosToken>)
Declaration
csharp
public static string EvaluateDotThingsAsPath(ReadOnlySpan<PosToken> tokens)
Declaration
csharp
public static string EvaluateDotThingsAsPath(ReadOnlySpan<PosToken> tokens)
Returns
System.String
Parameters
Type | Name |
---|
System.ReadOnlySpan<RCaron.PosToken> | tokens |
EvaluateDotThings(Span<PosToken>, Pipeline?)
Declaration
csharp
public object? EvaluateDotThings(Span<PosToken> instanceTokens, Pipeline? pipeline = null)
Declaration
csharp
public object? EvaluateDotThings(Span<PosToken> instanceTokens, Pipeline? pipeline = null)
Returns
System.Object
Parameters
EvaluateMultipleValues(in Span<PosToken>, int)
Declaration
csharp
public object?[] EvaluateMultipleValues(in Span<PosToken> tokens, int tokensStartIndex = 0)
Declaration
csharp
public object?[] EvaluateMultipleValues(in Span<PosToken> tokens, int tokensStartIndex = 0)
Returns
System.Object[]
Parameters
Type | Name |
---|
System.Span<RCaron.PosToken> | tokens |
System.Int32 | tokensStartIndex |
EvaluateVariable(string)
Declaration
csharp
public object? EvaluateVariable(string name)
Declaration
csharp
public object? EvaluateVariable(string name)
Returns
System.Object
Parameters
Type | Name |
---|
System.String | name |
EvaluateExpressionSingle(PosToken, bool, Pipeline?)
Declaration
csharp
public object? EvaluateExpressionSingle(PosToken token, bool isLeftOfPipeline = false, Pipeline? pipeline = null)
Declaration
csharp
public object? EvaluateExpressionSingle(PosToken token, bool isLeftOfPipeline = false, Pipeline? pipeline = null)
Returns
System.Object
Parameters
EvaluateExpressionValue(ArraySegment<PosToken>)
Declaration
csharp
[CollectionAccess(CollectionAccessType.Read)]
public object EvaluateExpressionValue(ArraySegment<PosToken> tokens)
Declaration
csharp
[CollectionAccess(CollectionAccessType.Read)]
public object EvaluateExpressionValue(ArraySegment<PosToken> tokens)
Returns
System.Object
Parameters
Type | Name |
---|
System.ArraySegment<RCaron.PosToken> | tokens |
EvaluateExpressionHigh(ArraySegment<PosToken>, Pipeline?, bool)
Declaration
csharp
public object? EvaluateExpressionHigh(ArraySegment<PosToken> tokens, Pipeline? pipeline = null, bool isLeftOfPipeline = false)
Declaration
csharp
public object? EvaluateExpressionHigh(ArraySegment<PosToken> tokens, Pipeline? pipeline = null, bool isLeftOfPipeline = false)
Returns
System.Object
Parameters
Type | Name |
---|
System.ArraySegment<RCaron.PosToken> | tokens |
RCaron.Pipeline | pipeline |
System.Boolean | isLeftOfPipeline |
FunctionCall(Function, CallLikePosToken?, ArraySegment<PosToken>, ClassInstance?, ClassDefinition?, Pipeline?)
Declaration
csharp
public object? FunctionCall(Function function, CallLikePosToken? callToken = null, ArraySegment<PosToken> argumentTokens = default, ClassInstance? classInstance = null, ClassDefinition? staticClassDefinition = null, Pipeline? pipeline = null)
Declaration
csharp
public object? FunctionCall(Function function, CallLikePosToken? callToken = null, ArraySegment<PosToken> argumentTokens = default, ClassInstance? classInstance = null, ClassDefinition? staticClassDefinition = null, Pipeline? pipeline = null)
Returns
System.Object
Parameters
EvaluateBool(PosToken[])
Declaration
csharp
public bool EvaluateBool(PosToken[] tokens)
Declaration
csharp
public bool EvaluateBool(PosToken[] tokens)
Returns
System.Boolean
Parameters
Type | Name |
---|
RCaron.PosToken[] | tokens |
EvaluateComparisonOperation(ComparisonValuePosToken)
Declaration
csharp
public bool EvaluateComparisonOperation(ComparisonValuePosToken comparisonValuePosToken)
Declaration
csharp
public bool EvaluateComparisonOperation(ComparisonValuePosToken comparisonValuePosToken)
Returns
System.Boolean
Parameters
EvaluateLogicalOperation(LogicalOperationValuePosToken)
Declaration
csharp
public bool EvaluateLogicalOperation(LogicalOperationValuePosToken comparisonValuePosToken)
Declaration
csharp
public bool EvaluateLogicalOperation(LogicalOperationValuePosToken comparisonValuePosToken)
Returns
System.Boolean
Parameters
RunLeftPipeline(PosToken[], Pipeline?)
Declaration
csharp
public Pipeline RunLeftPipeline(PosToken[] tokens, Pipeline? pipelineIn = null)
Declaration
csharp
public Pipeline RunLeftPipeline(PosToken[] tokens, Pipeline? pipelineIn = null)
Returns
RCaron.Pipeline
Parameters
GetVar(string)
Declaration
csharp
public object? GetVar(string name)
Declaration
csharp
public object? GetVar(string name)
Returns
System.Object
Parameters
Type | Name |
---|
System.String | name |
GetVarRef(string)
Declaration
csharp
public ref object? GetVarRef(string name)
Declaration
csharp
public ref object? GetVarRef(string name)
Returns
System.Object
Parameters
Type | Name |
---|
System.String | name |
SetVar(string, object?)
Declaration
csharp
public void SetVar(string name, object? value)
Declaration
csharp
public void SetVar(string name, object? value)
Parameters
Type | Name |
---|
System.String | name |
System.Object | value |
GetFileScope()
Declaration
csharp
public FileScope GetFileScope()
Declaration
csharp
public FileScope GetFileScope()
Returns
RCaron.FileScope
TryGetClassDefinition(string, FileScope, out ClassDefinition)
Declaration
csharp
public static bool TryGetClassDefinition(string name, FileScope fileScope, out ClassDefinition classDefinition)
Declaration
csharp
public static bool TryGetClassDefinition(string name, FileScope fileScope, out ClassDefinition classDefinition)
Returns
System.Boolean
Parameters
TryGetClassDefinition(List<ClassDefinition>?, string, out ClassDefinition)
Declaration
csharp
public static bool TryGetClassDefinition(List<ClassDefinition>? classDefinitions, string name, out ClassDefinition classDefinition)
Declaration
csharp
public static bool TryGetClassDefinition(List<ClassDefinition>? classDefinitions, string name, out ClassDefinition classDefinition)
Returns
System.Boolean
Parameters
TryGetFunction(string, FileScope, out Function)
Declaration
csharp
public bool TryGetFunction(string name, FileScope fileScope, out Function function)
Declaration
csharp
public bool TryGetFunction(string name, FileScope fileScope, out Function function)
Returns
System.Boolean
Parameters
TryCallFunction(string, FileScope, CallLikePosToken?, ArraySegment<PosToken>, ClassInstance?, out object?, ClassDefinition?, Pipeline?)
Declaration
csharp
public bool TryCallFunction(string name, FileScope fileScope, CallLikePosToken? callToken, ArraySegment<PosToken> argumentTokens, ClassInstance? classInstance, out object? result, ClassDefinition? classDefinition = null, Pipeline? pipeline = null)
Declaration
csharp
public bool TryCallFunction(string name, FileScope fileScope, CallLikePosToken? callToken, ArraySegment<PosToken> argumentTokens, ClassInstance? classInstance, out object? result, ClassDefinition? classDefinition = null, Pipeline? pipeline = null)
Returns
System.Boolean
Parameters
Extension Methods