This commit is contained in:
parent
b3a333efc6
commit
df18285d65
29
Class1.cs
29
Class1.cs
|
@ -2,6 +2,7 @@
|
|||
using BITKit;
|
||||
using BITKit.CommandPattern;
|
||||
using BITKit.Mod;
|
||||
using System.Linq;
|
||||
|
||||
namespace BITFactory.Cutting
|
||||
{
|
||||
|
@ -36,20 +37,20 @@ namespace BITFactory.Cutting
|
|||
stringBuilder.AppendLine($"导出时间: {DateTime.Now}");
|
||||
foreach (var x in commands)
|
||||
{
|
||||
// switch (x)
|
||||
// {
|
||||
// case CuttingPointCommand pointCommand:
|
||||
// stringBuilder.AppendLine(
|
||||
// $"切削点: {pointCommand.PlanePoint.x} {pointCommand.PlanePoint.y} {pointCommand.PlanePoint.z}");
|
||||
// break;
|
||||
// case CuttingLineCommand lineCommand:
|
||||
// stringBuilder.AppendLine($"切削线:{lineCommand.Line.Length}");
|
||||
// foreach (var linePos in lineCommand.Line)
|
||||
// {
|
||||
// stringBuilder.AppendLine($"切削线点: {linePos.x} {linePos.y} {linePos.z}");
|
||||
// }
|
||||
// break;
|
||||
// }
|
||||
switch (x)
|
||||
{
|
||||
case CuttingPointCommand pointCommand:
|
||||
stringBuilder.AppendLine(
|
||||
$"切削点: {pointCommand.PlanePoint.x} {pointCommand.PlanePoint.y} {pointCommand.PlanePoint.z}");
|
||||
break;
|
||||
case CuttingLineCommand lineCommand:
|
||||
stringBuilder.AppendLine($"切削线:{lineCommand.Line.Length}");
|
||||
foreach (var linePos in lineCommand.Line)
|
||||
{
|
||||
stringBuilder.AppendLine($"切削线点: {linePos.x} {linePos.y} {linePos.z}");
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
File.WriteAllText(path, stringBuilder.ToString());
|
||||
|
|
Loading…
Reference in New Issue