Class CsvNcStep
Represents a numerical control step loaded from a CSV file, with support for interpolation and arithmetic operations.
public class CsvNcStep : IGetFileLineIndex, IAdditionOperators<CsvNcStep, CsvNcStep, CsvNcStep>, IMultiplyOperators<CsvNcStep, double, CsvNcStep>
- Inheritance
-
CsvNcStep
- Implements
- Inherited Members
- Extension Methods
Constructors
CsvNcStep(FileLineIndex, TimeSpan, DVec3d, List<double>)
Initializes a new instance of the CsvNcStep class with the specified parameters.
public CsvNcStep(FileLineIndex fileLineIndex, TimeSpan time, DVec3d mcXyzabc, List<double> doubleFlexList)
Parameters
fileLineIndexFileLineIndexThe file and line index information.
timeTimeSpanThe time value for this step.
mcXyzabcDVec3dThe machine coordinates for this step.
doubleFlexListList<double>The list of additional double values.
Properties
ActualTime
Gets or sets the time value for this step.
public TimeSpan ActualTime { get; set; }
Property Value
DoubleFlexList
Gets or sets the list of additional double values associated with this step.
public List<double> DoubleFlexList { get; set; }
Property Value
FileLineIndex
Gets or sets the file and line index information.
public FileLineIndex FileLineIndex { get; set; }
Property Value
McXyzabc
Gets the machine coordinates (XYZ and ABC) for this step.
public DVec3d McXyzabc { get; }
Property Value
Methods
GetFileLineIndex()
Get FileLineIndex.
public FileLineIndex GetFileLineIndex()
Returns
MapSingleByCsvFile(ClStrip, string, string, IProgress<object>)
Embed single data per step by CSV file. It is one (step) - one (embedded-data) mapping. Time interpolation is applied. It is time-based mapping. Builds a collection of CsvNcStep instances from a CSV file.
public static void MapSingleByCsvFile(ClStrip clStrip, string baseDirectory, string relFile, IProgress<object> messageHost)
Parameters
clStripClStripThe cutter location strip to populate.
baseDirectorystringThe base directory for the file path.
relFilestringThe relative file path to the CSV file.
messageHostIProgress<object>The message host for logging.
Operators
operator +(CsvNcStep, CsvNcStep)
Adds two CsvNcStep instances together.
public static CsvNcStep operator +(CsvNcStep left, CsvNcStep right)
Parameters
Returns
- CsvNcStep
A new CsvNcStep instance with values that are the sum of the two input instances.
operator *(CsvNcStep, double)
Multiplies a CsvNcStep instance by a scalar value.
public static CsvNcStep operator *(CsvNcStep src, double scale)
Parameters
Returns
- CsvNcStep
A new CsvNcStep instance with values scaled by the specified factor.