Class AbstractInterpreter
Abstract class for machine control program interpretation.
Implements
Inherited Members
Namespace: DotNet.Interpreter.Helper
Assembly: DotNet.Interpreter.Helper.dll
Syntax
public abstract class AbstractInterpreter : INCT_Interpreter
Constructors
AbstractInterpreter()
Initializes a new instance of the AbstractInterpreter class.
Declaration
public AbstractInterpreter()
Fields
_commands
Command manager used by the interpreter to manage program commands.
Declaration
protected CommandManager _commands
Field Value
Type | Description |
---|---|
CommandManager |
_isEndOfProgram
Flag indicating whether program interpretation has been completed.
Declaration
protected bool _isEndOfProgram
Field Value
Type | Description |
---|---|
bool |
_registers
Register manager used by the interpreter to manage registers.
Declaration
protected RegisterManager _registers
Field Value
Type | Description |
---|---|
RegisterManager |
Properties
Analyzer
Returns the analyzer object for the control program.
Declaration
public INCT_Analyzer2 Analyzer { get; }
Property Value
Type | Description |
---|---|
INCT_Analyzer2 |
Remarks
Provides access to control program text analysis settings.
AxesBrakes
Returns the AutoAxesBrakes interface for controlling automatic axis brake output commands.
Declaration
public INCT_CLData_AutoAxesBrakes AxesBrakes { get; }
Property Value
Type | Description |
---|---|
INCT_CLData_AutoAxesBrakes |
Remarks
Used when there is no need to output information about enabling or disabling axis brakes to CLData.
BEA
Returns the execution array object for control program blocks.
Declaration
public INCT_BlockExecArray BEA { get; }
Property Value
Type | Description |
---|---|
INCT_BlockExecArray |
Remarks
Provides access to the list of objects in the current block for interpretation.
CLD
Returns the CLData interface (Cutter Location Data) for interacting with toolpath data
Declaration
public INCT_CLData2 CLD { get; }
Property Value
Type | Description |
---|---|
INCT_CLData2 |
Remarks
Provides access to toolpath generation functionality, allowing creation and manipulation of cutter location data for machining operations. Uses machine-based CLData rather than geometric CLData for toolpath formation.
Commands
Returns the command manager used by the interpreter to manage program commands.
Declaration
public CommandManager Commands { get; }
Property Value
Type | Description |
---|---|
CommandManager |
Comment
Returns the Comment interface for handling program comments and annotations.
Declaration
public INCT_CLData_Comment Comment { get; }
Property Value
Type | Description |
---|---|
INCT_CLData_Comment |
Remarks
Enables adding explanations to individual commands or groups of commands. Provides functionality for including service information for technologists or machine operators.
Connect
Returns the Connect interface for accessing secured data from protected files.
Declaration
public INCT_Connect Connect { get; }
Property Value
Type | Description |
---|---|
INCT_Connect |
Remarks
Required for licensed secure interpreter containers.
CurrentLine
Gets or sets the current processed block (line) of the machine control program.
Declaration
public string CurrentLine { get; set; }
Property Value
Type | Description |
---|---|
string |
CutTo5d
Returns the CutTo5d interface for generating tool paths along normal vectors.
Declaration
public INCT_CLData_CutTo5d CutTo5d { get; }
Property Value
Type | Description |
---|---|
INCT_CLData_CutTo5d |
Remarks
Enables creation of 5-axis toolpaths by generating movements along surface normal vectors, facilitating advanced machining operations on complex geometries.
EQ
Returns the equipment object of the machine.
Declaration
public INCT_Equipment2 EQ { get; }
Property Value
Type | Description |
---|---|
INCT_Equipment2 |
Remarks
Provides access to various machine equipment parameters.
GCLD
Returns the GeomCLData interface for generating tool path movements using geometric axes.
Declaration
public INCT_GeomCLData GCLD { get; }
Property Value
Type | Description |
---|---|
INCT_GeomCLData |
Remarks
Provides functionality for creating toolpath movements using geometric coordinate system axes.
Kernel
Returns the system kernel interface.
Declaration
public INCT_Kernel2 Kernel { get; }
Property Value
Type | Description |
---|---|
INCT_Kernel2 |
Remarks
Provides functionality for working with control program text, subprograms, logging messages to the CAM system protocol, displaying popup notifications, and restarting the interpreter in contour extraction mode.
OriginShiftRotate
Returns the AddOriginByShiftAndRotate interface for coordinate system shifting and rotation according to specified parameters.
Declaration
public INCT_AddOriginByShiftAndRotate OriginShiftRotate { get; }
Property Value
Type | Description |
---|---|
INCT_AddOriginByShiftAndRotate |
Remarks
Enables precise manipulation of the coordinate system through translation and rotation operations based on user-defined parameters.
ParentInterpreter
Returns the parent interpreter interface.
Declaration
public INCT_Interpreter ParentInterpreter { get; }
Property Value
Type | Description |
---|---|
INCT_Interpreter |
Remarks
Provides access to the parent interpreter's functionality, enabling hierarchical interpretation and allowing this interpreter to utilize capabilities of the parent interpreter when needed.
PocketCycleFormer
Returns the PocketCycleFormer interface for simplifying the generation of movements for circular pocket milling cycles.
Declaration
public INCT_CLData_PocketCycleFormer PocketCycleFormer { get; }
Property Value
Type | Description |
---|---|
INCT_CLData_PocketCycleFormer |
Remarks
Provides functionality for automating toolpath generation in pocket milling operations, reducing the complexity of programming circular pocket machining sequences.
SS
Returns the system state object of the machine.
Declaration
public INCT_SysState2 SS { get; }
Property Value
Type | Description |
---|---|
INCT_SysState2 |
Remarks
Provides access to the formed register list (taking into account the settings file, program library, and parent interpreters).
Methods
AfterInterprete()
Method that performs actions after interpreting each block.
Declaration
public virtual void AfterInterprete()
BeforeInterprete()
Method that performs actions before starting the interpretation of each block.
Declaration
public abstract void BeforeInterprete()
CanExecuteParameterCommand(nint)
Checks if a command with the specified parameter can be executed.
Declaration
protected virtual bool CanExecuteParameterCommand(nint executionParameter)
Parameters
Type | Name | Description |
---|---|---|
nint | executionParameter | Pointer to the command parameter. |
Returns
Type | Description |
---|---|
bool |
|
CanExecuteRegisterCommand(INCT_BaseReg)
Checks if a command can be executed for the specified register.
Declaration
protected virtual bool CanExecuteRegisterCommand(INCT_BaseReg baseRegister)
Parameters
Type | Name | Description |
---|---|---|
INCT_BaseReg | baseRegister | Base register. |
Returns
Type | Description |
---|---|
bool |
|
CanUpdateEmptyValue(INCT_BaseReg)
Checks if an empty value can be updated in the register.
Declaration
protected virtual bool CanUpdateEmptyValue(INCT_BaseReg baseRegister)
Parameters
Type | Name | Description |
---|---|---|
INCT_BaseReg | baseRegister | Base register. |
Returns
Type | Description |
---|---|
bool |
|
ClearInterfaces()
Clears references to used interfaces.
Declaration
protected virtual void ClearInterfaces()
CreateRegisters()
Creates a set of registers for the interpreter.
Declaration
protected virtual void CreateRegisters()
DefineRegister(string, out int)
Determines the register index by its address.
Declaration
public virtual bool DefineRegister(string address, out int index)
Parameters
Type | Name | Description |
---|---|---|
string | address | Register address. |
int | index | Output parameter containing the register index. |
Returns
Type | Description |
---|---|
bool |
|
EndOfProgram()
Checks if the program is completed.
Declaration
public virtual bool EndOfProgram()
Returns
Type | Description |
---|---|
bool |
|
ExecuteParameterCommand(nint)
Executes a command associated with the parameter in the context of program interpretation.
Declaration
protected abstract void ExecuteParameterCommand(nint executionParameter)
Parameters
Type | Name | Description |
---|---|---|
nint | executionParameter | Pointer to the command parameter. |
~AbstractInterpreter()
Destructor for the AbstractInterpreter class.
Declaration
protected ~AbstractInterpreter()
GetIdentifier()
Returns the unique identifier of the interpreter.
Declaration
public virtual string GetIdentifier()
Returns
Type | Description |
---|---|
string | Identifier string. |
GetRegisters()
Returns the register list of the interpreter.
Declaration
public virtual INCT_RegisterList GetRegisters()
Returns
Type | Description |
---|---|
INCT_RegisterList | Register list object implementing INCT_RegisterList. |
Initialize()
Initializes the interpreter.
Declaration
public virtual void Initialize()
Interprete(int)
Performs interpretation of a command by its number in the execution array.
Declaration
public virtual void Interprete(int executionNumber)
Parameters
Type | Name | Description |
---|---|---|
int | executionNumber | Command number for execution. |
NextOperation()
Performs actions required after transitioning to the next operation.
Declaration
public abstract void NextOperation()
SetInterface(object)
Sets the interfaces required for interpreter operation.
Declaration
public virtual void SetInterface(object interfaceObj)
Parameters
Type | Name | Description |
---|---|---|
object | interfaceObj | Interface object. |
TransLine(string, out int, out bool, out bool)
Processes a control program string, returning the number of processed characters and signals to move to the next line or interrupt the current line.
Declaration
public virtual void TransLine(string currentLine, out int processedChars, out bool nextLine, out bool breakLine)
Parameters
Type | Name | Description |
---|---|---|
string | currentLine | Current line of the control program. |
int | processedChars | Number of processed characters. |
bool | nextLine | Flag indicating the need to move to the next line. |
bool | breakLine | Flag indicating the need to interrupt the processing of the current line. |