This commit is contained in:
Nitload
2025-08-25 09:50:30 +08:00
parent bd0e31e922
commit 1359ff4ecc
1630 changed files with 738486 additions and 2399 deletions
@@ -28,24 +28,23 @@
//
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
using StgSharp.Model.Step;
using StgSharp.Script;
using StgSharp.Script.Express;
using System;
using System.Collections.Generic;
namespace StgSharp.Model.Step
namespace StgSharp.Modeling.Items
{
public class StepElementarySurface : StepSurface, IExpConvertableFrom<StepElementarySurface>
public abstract class StepElementarySurface : StepSurface
{
private StepAxis2Placement3D _position;
public StepElementarySurface( StepModel model ) : base( model ) { }
protected StepElementarySurface() : base( string.Empty ) { }
public StepElementarySurface( StepModel model, StepAxis2Placement3D position )
: base( model )
public StepElementarySurface( string name, StepAxis2Placement3D position )
: base( name )
{
Position = position;
}
@@ -55,15 +54,17 @@ namespace StgSharp.Model.Step
get { return _position; }
set
{
ArgumentNullException.ThrowIfNull( value );
if( value == null ) {
throw new ArgumentNullException();
}
_position = value;
}
}
public void FromInstance( StepElementarySurface entity )
internal override IEnumerable<StepRepresentationItem> GetReferencedItems()
{
base.FromInstance( entity );
_position = entity.Position;
yield return Position;
}
}