Files
AJ 7c5b4ded5f chore(PepLib.Core): remove unused using directives and clean up formatting
Remove unnecessary System, System.Collections.Generic, System.IO, and
System.Linq using directives that were flagged by IDE analyzers. Also
includes minor whitespace and code style normalization.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-14 07:52:17 -05:00

57 lines
1.3 KiB
C#

using PepLib.Codes;
namespace PepLib
{
public class Loop : Program
{
public Loop()
{
Mode = ProgrammingMode.Incremental;
}
public string Name { get; set; }
public Vector ReferencePoint { get; set; }
public DateTime LastReferenceDate { get; set; }
public string DrawingName { get; set; }
public string DxfPath { get; set; }
public override void Rotate(double angle)
{
base.Rotate(angle);
ReferencePoint = ReferencePoint.Rotate(angle);
}
public override void Rotate(double angle, Vector origin)
{
base.Rotate(angle, origin);
ReferencePoint = ReferencePoint.Rotate(angle);
}
public object Clone()
{
var loop = new Loop()
{
Name = this.Name,
ReferencePoint = this.ReferencePoint,
LastReferenceDate = this.LastReferenceDate,
DrawingName = this.DrawingName,
DxfPath = this.DxfPath,
Rotation = this.Rotation
};
var codes = new ICode[this.Count];
for (int i = 0; i < this.Count; ++i)
codes[i] = this[i].Clone();
loop.AddRange(codes);
return loop;
}
}
}