Interface ICLDFile
A separate file of a CLData. Contains the list of CLData commands.
Namespace: SprutTechnology.SCPostprocessor
Assembly: SCPostprocessor.dll
Syntax
public interface ICLDFile
Properties
Caption
Textual label with a short description of the file.
Declaration
string Caption { get; }
Property Value
Type | Description |
---|---|
System.String |
Cmd
The list of commands in the CLData file. Allows to get a command by the index Cmd[0..CmdCount-1].
Declaration
ICLDFileCmdIndexer Cmd { get; }
Property Value
Type | Description |
---|---|
ICLDFileCmdIndexer |
CmdCount
The count of commands in this CLData file.
Declaration
int CmdCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Enabled
The Enabled flag determines whether this file should be postprocessed or not.
Declaration
bool Enabled { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
FileType
Describes the type of the CLData file (TechOperation, NCSub or CAMProject).
Declaration
CLDFileType FileType { get; }
Property Value
Type | Description |
---|---|
CLDFileType |
ID
Unique textual identifier of the file in the project.
Declaration
string ID { get; }
Property Value
Type | Description |
---|---|
System.String |
Index
The index of this file in the list of files of the CLData project.
Declaration
int Index { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Item[Int32]
The list of commands in the CLData file. Allows to get a command by the index [0..CmdCount-1].
Declaration
ICLDCommand this[int Index] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | Index | Index of the CLData command to get [0..CmdCount-1]. |
Property Value
Type | Description |
---|---|
ICLDCommand | Returns the CLData command with the given index. If the index is incorrect it returns "Null". |
Project
Reference to the SprutCAM's CLData project in which this file is located.
Declaration
ICLDProject Project { get; }
Property Value
Type | Description |
---|---|
ICLDProject |
Methods
FindCommand(CLDCmdType, Int32)
Finds a CLData command with the given type starting from the specified index in this file.
Declaration
ICLDCommand FindCommand(CLDCmdType commandType, int searchFrom)
Parameters
Type | Name | Description |
---|---|---|
CLDCmdType | commandType | The type of command to find. |
System.Int32 | searchFrom | Searching start index. |
Returns
Type | Description |
---|---|
ICLDCommand | If the search is successful, it returns the found command, otherwise it returns "Null". |
FindCommand(CLDCmdType, Int32, Int32)
Finds a CLData command with the given type in the range of commands in this file.
Declaration
ICLDCommand FindCommand(CLDCmdType commandType, int searchFrom, int searchTo)
Parameters
Type | Name | Description |
---|---|---|
CLDCmdType | commandType | The type of command to find. |
System.Int32 | searchFrom | Searching start index. |
System.Int32 | searchTo | Searching finish index. |
Returns
Type | Description |
---|---|
ICLDCommand | If the search is successful, it returns the found command, otherwise it returns "Null". |
GetCommandType(Int32)
Let's define the type of CLData command with the given index.
Declaration
CLDCmdType GetCommandType(int Index)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | Index | Index of the command to define the type. |
Returns
Type | Description |
---|---|
CLDCmdType | Returns the type of CLData command with the given index. If the index is incorrect then it returns "CLDCmdType.Unknown" |
IndexOfCmd(CLDCmdType, Int32, Int32)
Finds an index of command with the given type in the range of commands in this file.
Declaration
int IndexOfCmd(CLDCmdType CommandType, int SearchFrom, int SearchTo)
Parameters
Type | Name | Description |
---|---|---|
CLDCmdType | CommandType | The type of command to find. |
System.Int32 | SearchFrom | Searching start index. |
System.Int32 | SearchTo | Searching finish index. |
Returns
Type | Description |
---|---|
System.Int32 | If the search is successful, it returns the index of the found command, otherwise it returns "-1". |
IndexOfCmdName(String, Int32, Int32)
Finds an index of command with the given type name in the range of commands in this file.
Declaration
int IndexOfCmdName(string CommandTypeName, int SearchFrom, int SearchTo)
Parameters
Type | Name | Description |
---|---|---|
System.String | CommandTypeName | The type name of command to find. |
System.Int32 | SearchFrom | Searching start index. |
System.Int32 | SearchTo | Searching finish index. |
Returns
Type | Description |
---|---|
System.Int32 | If the search is successful, it returns the index of the found command, otherwise it returns "-1". |