Value points were added

This commit is contained in:
Evgeny Redikultsev
2024-03-02 21:40:13 +05:00
parent 2e8ebccc13
commit 4359b2c49b
41 changed files with 1127 additions and 439 deletions

View File

@@ -2,6 +2,7 @@
using LoaderCalculator.Data.Ndms;
using StructureHelper.Models.Materials;
using StructureHelperCommon.Models.Forces;
using StructureHelperCommon.Models.Parameters;
using StructureHelperCommon.Models.Shapes;
using StructureHelperLogics.Models.CrossSections;
using StructureHelperLogics.NdmCalculations.Triangulations;
@@ -72,5 +73,18 @@ namespace StructureHelperLogics.NdmCalculations.Primitives
if (distance > Diameter / 2) { return false; }
return true;
}
List<NamedValue<IPoint2D>> INdmPrimitive.GetValuePoints()
{
var points = new List<NamedValue<IPoint2D>>();
NamedValue<IPoint2D> newPoint;
newPoint = new NamedValue<IPoint2D>()
{
Name = "Center",
Value = Center.Clone() as Point2D
};
points.Add(newPoint);
return points;
}
}
}

View File

@@ -10,6 +10,7 @@ using System;
using StructureHelperCommon.Models.Forces;
using StructureHelperLogics.Models.CrossSections;
using StructureHelperLogics.NdmCalculations.Triangulations;
using StructureHelperCommon.Models.Parameters;
namespace StructureHelperLogics.NdmCalculations.Primitives
{
@@ -28,5 +29,6 @@ namespace StructureHelperLogics.NdmCalculations.Primitives
IVisualProperty VisualProperty {get; }
IEnumerable<INdm> GetNdms(ITriangulationOptions triangulationOptions);
List<NamedValue<IPoint2D>> GetValuePoints();
}
}

View File

@@ -1,6 +1,7 @@
using LoaderCalculator.Data.Ndms;
using StructureHelper.Models.Materials;
using StructureHelperCommon.Models.Forces;
using StructureHelperCommon.Models.Parameters;
using StructureHelperCommon.Models.Shapes;
using StructureHelperLogics.Models.CrossSections;
using StructureHelperLogics.NdmCalculations.Primitives;
@@ -54,5 +55,18 @@ namespace StructureHelperLogics.Models.Primitives
var logic = new PointTriangulationLogic(options);
return logic.GetNdmCollection();
}
public List<NamedValue<IPoint2D>> GetValuePoints()
{
var points = new List<NamedValue<IPoint2D>>();
NamedValue<IPoint2D> newPoint;
newPoint = new NamedValue<IPoint2D>()
{
Name = "Center",
Value = Center.Clone() as Point2D
};
points.Add(newPoint);
return points;
}
}
}

View File

@@ -3,6 +3,7 @@ using LoaderCalculator.Data.Ndms;
using StructureHelper.Models.Materials;
using StructureHelperCommon.Infrastructures.Interfaces;
using StructureHelperCommon.Models.Forces;
using StructureHelperCommon.Models.Parameters;
using StructureHelperCommon.Models.Shapes;
using StructureHelperLogics.Models.CrossSections;
using StructureHelperLogics.Models.Materials;
@@ -75,5 +76,18 @@ namespace StructureHelperLogics.NdmCalculations.Primitives
var logic = new RebarTriangulationLogic(options);
return logic.GetNdmCollection();
}
public List<NamedValue<IPoint2D>> GetValuePoints()
{
var points = new List<NamedValue<IPoint2D>>();
NamedValue<IPoint2D> newPoint;
newPoint = new NamedValue<IPoint2D>()
{
Name = "Center",
Value = Center.Clone() as Point2D
};
points.Add(newPoint);
return points;
}
}
}

View File

@@ -2,6 +2,7 @@
using LoaderCalculator.Data.Ndms;
using StructureHelper.Models.Materials;
using StructureHelperCommon.Models.Forces;
using StructureHelperCommon.Models.Parameters;
using StructureHelperCommon.Models.Shapes;
using StructureHelperLogics.Models.CrossSections;
using StructureHelperLogics.NdmCalculations.Triangulations;
@@ -80,5 +81,24 @@ namespace StructureHelperLogics.NdmCalculations.Primitives
{ return false; }
return true;
}
public List<NamedValue<IPoint2D>> GetValuePoints()
{
var points = new List<NamedValue<IPoint2D>>();
NamedValue<IPoint2D> newPoint;
newPoint = new NamedValue<IPoint2D>()
{
Name = "Center",
Value = Center.Clone() as Point2D
};
points.Add(newPoint);
newPoint = new NamedValue<IPoint2D>()
{
Name = "LeftTop",
Value = new Point2D() { X = Center.X - Width / 2d, Y = Center.Y + Height / 2d}
};
points.Add(newPoint);
return points;
}
}
}