Class PreservedPiecePack
Mono preserved piece optimization package: a piece whose feedrate is never changed; its StepAdjustment is seeded by the classifier.
public class PreservedPiecePack : ISingleAdjustmentPack, INcOptPiecePack
- Inheritance
-
PreservedPiecePack
- Implements
- Inherited Members
- Extension Methods
Remarks
Mirrors HiNc NcOptProc.PreservedLinePack (frozen HardNc baseline).
Constructors
PreservedPiecePack(SyntaxPiece, string, double, bool, bool, bool, ICutterOptOption, IndexSegment, StepAdjustment)
Ctor.
public PreservedPiecePack(SyntaxPiece piece, string toolId, double srcFeedrate_mmds, bool isArc, bool hasArcMotionEvent, bool isRapid, ICutterOptOption cutterOptLimit, IndexSegment stepIndexSegment, StepAdjustment stepAdjustment)
Parameters
pieceSyntaxPieceThe classified syntax piece.
toolIdstringThe active tool id in text form.
srcFeedrate_mmdsdoubleThe piece's effective modal feedrate in mm/s.
isArcboolWhether the piece runs under an arc command in the modal sense.
hasArcMotionEventboolWhether the piece carries one-shot arc data.
isRapidboolWhether the piece is a rapid (G00-modal) line.
cutterOptLimitICutterOptOptionCutter optimization limit. May be null.
stepIndexSegmentIndexSegmentThe step index segment of the piece.
stepAdjustmentStepAdjustmentThe adjustment seeded by the classifier.
Properties
CutterOptLimit
Cutter optimization limit of the tool active on this piece. May be null.
public ICutterOptOption CutterOptLimit { get; set; }
Property Value
HasArcMotionEvent
Whether the piece itself carries one-shot arc data: its
MotionEvent section is an arc form
(McArc/ClArc/McPolarArc, with the arc geometry
ArcCenter/IsCcw). Distinct from IsArc,
which is the modal latch: a zero-motion continuation line under a G02
modal has IsArc true and this false. The splition
fragment engine reads this to know whether per-fragment I/J/K
rebuilding applies.
public bool HasArcMotionEvent { get; set; }
Property Value
IsArc
Whether the piece runs under an arc command in the MODAL sense: the
effective Group-01 latch is G02/G03 — a zero-motion line under a
G02/G03 modal is still “on arc” — or, for CL-sourced pieces (which
carry no NC modal state), the one-shot motion event is an arc form.
Replaces the HardNc NcFlagBitArray.IsOnArcCommand() gate
(NcFlagUtil.cs:675-679: the modal G02/G03 flag bits).
public bool IsArc { get; set; }
Property Value
IsRapid
Whether the piece is a rapid (G00-modal) line by the classifier's rapid
predicate (one-shot MotionEvent.IsRapid or effective
MotionState G00). On such a line the effective modal feedrate is
the machine rapid feedrate, not SrcFeedrate_mmds
(replaces the HardNc NcFlagBitArray.IsRapid() read that routes
HardNcLine.Feedrate_mmds to RapidFeedrate_mmds,
HardNcLine.cs:206-211).
public bool IsRapid { get; set; }
Property Value
Piece
The SoftNc syntax piece this pack was classified from.
public SyntaxPiece Piece { get; set; }
Property Value
SrcFeedrate_mmds
The piece's effective modal feedrate in mm/s
(replaces the HardNc ncLine.Feedrate_mmds read).
public double SrcFeedrate_mmds { get; set; }
Property Value
StepAdjustment
The single adjustment of this pack.
public StepAdjustment StepAdjustment { get; set; }
Property Value
StepIndexSegment
Always not null.
public IndexSegment StepIndexSegment { get; set; }
Property Value
ToolId
The id (in text form) of the tool active on this piece, from the classifier's tool state machine. Used for tool house lookups.
public string ToolId { get; set; }
Property Value
Methods
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.