Z-Index was added
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
using StructureHelperCommon.Models.Materials;
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
using LoaderCalculator.Data.Materials;
|
||||
using StructureHelperCommon.Models.Materials;
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
using StructureHelperCommon.Infrastructures.Enums;
|
||||
using StructureHelperCommon.Models.Materials;
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using StructureHelperLogics.Infrastructures.CommonEnums;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
13
StructureHelperLogics/Models/Materials/IPrimitiveMaterial.cs
Normal file
13
StructureHelperLogics/Models/Materials/IPrimitiveMaterial.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using StructureHelperCommon.Infrastructures.Enums;
|
||||
|
||||
namespace StructureHelperLogics.Models.Materials
|
||||
{
|
||||
public interface IPrimitiveMaterial
|
||||
{
|
||||
string Id { get;}
|
||||
MaterialTypes MaterialType { get; }
|
||||
CodeTypes CodeType { get; set; }
|
||||
string ClassName { get; }
|
||||
double Strength { get; }
|
||||
}
|
||||
}
|
||||
@@ -2,7 +2,7 @@
|
||||
using StructureHelperCommon.Infrastructures.Enums;
|
||||
using StructureHelperCommon.Infrastructures.Exceptions;
|
||||
using StructureHelperCommon.Infrastructures.Strings;
|
||||
using StructureHelperCommon.Models.Materials;
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
22
StructureHelperLogics/Models/Materials/PrimitiveMaterial.cs
Normal file
22
StructureHelperLogics/Models/Materials/PrimitiveMaterial.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using StructureHelper.Models.Materials;
|
||||
using StructureHelperCommon.Infrastructures.Enums;
|
||||
using System;
|
||||
|
||||
namespace StructureHelperLogics.Models.Materials
|
||||
{
|
||||
public class PrimitiveMaterial : IPrimitiveMaterial
|
||||
{
|
||||
public string Id { get; }
|
||||
public MaterialTypes MaterialType { get; set; }
|
||||
public CodeTypes CodeType { get; set; }
|
||||
IHeadMaterial HeadMaterial { get; set; }
|
||||
public string ClassName { get; set; }
|
||||
public double Strength { get; set; }
|
||||
|
||||
|
||||
public PrimitiveMaterial()
|
||||
{
|
||||
Id = Convert.ToString(Guid.NewGuid());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using StructureHelperCommon.Models.Shapes;
|
||||
|
||||
namespace StructureHelperLogics.Models.Primitives
|
||||
{
|
||||
public interface INdmPrimitive
|
||||
{
|
||||
ICenter Center { get; set; }
|
||||
IShape Shape { get; set; }
|
||||
IPrimitiveMaterial PrimitiveMaterial {get;set;}
|
||||
double NdmMaxSize { get; set; }
|
||||
int NdmMinDivision { get; set; }
|
||||
double PrestrainKx { get; set; }
|
||||
double PrestrainKy { get; set; }
|
||||
double PrestrainEpsZ { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using StructureHelperCommon.Models.Shapes;
|
||||
|
||||
namespace StructureHelperLogics.Models.Primitives
|
||||
{
|
||||
public class NdmPrimitive : INdmPrimitive
|
||||
{
|
||||
public ICenter Center { get; set; }
|
||||
public IShape Shape { get; set; }
|
||||
public IPrimitiveMaterial PrimitiveMaterial { get; set; }
|
||||
public double NdmMaxSize { get; set; }
|
||||
public int NdmMinDivision { get; set; }
|
||||
public double PrestrainKx { get; set; }
|
||||
public double PrestrainKy { get; set; }
|
||||
public double PrestrainEpsZ { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,8 +1,7 @@
|
||||
using StructureHelperCommon.Infrastructures.Exceptions;
|
||||
using StructureHelperCommon.Infrastructures.Strings;
|
||||
using StructureHelperCommon.Models.Entities;
|
||||
using StructureHelperCommon.Models.NdmPrimitives;
|
||||
using StructureHelperCommon.Models.Shapes;
|
||||
using StructureHelperLogics.Models.Primitives;
|
||||
|
||||
namespace StructureHelperLogics.NdmCalculations.Triangulations
|
||||
{
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
using System;
|
||||
using StructureHelperCommon.Infrastructures.Exceptions;
|
||||
using StructureHelperCommon.Infrastructures.Strings;
|
||||
using StructureHelperCommon.Models.Entities;
|
||||
using StructureHelperCommon.Models.Shapes;
|
||||
using StructureHelperLogics.Models.Primitives;
|
||||
|
||||
namespace StructureHelperLogics.NdmCalculations.Triangulations
|
||||
{
|
||||
|
||||
@@ -6,9 +6,9 @@ using LoaderCalculator.Data.Ndms;
|
||||
using StructureHelperCommon.Infrastructures.Enums;
|
||||
using StructureHelperCommon.Infrastructures.Exceptions;
|
||||
using StructureHelperCommon.Infrastructures.Strings;
|
||||
using StructureHelperCommon.Models.Entities;
|
||||
using StructureHelperCommon.Models.Materials;
|
||||
using StructureHelperLogics.Models.Materials;
|
||||
using StructureHelperCommon.Models.Shapes;
|
||||
using StructureHelperLogics.Models.Primitives;
|
||||
|
||||
namespace StructureHelperLogics.NdmCalculations.Triangulations
|
||||
{
|
||||
@@ -29,7 +29,11 @@ namespace StructureHelperLogics.NdmCalculations.Triangulations
|
||||
}
|
||||
return ndms;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns dictionary of unique materials by collection of primitives
|
||||
/// </summary>
|
||||
/// <param name="ndmPrimitives"></param>
|
||||
/// <returns></returns>
|
||||
private static Dictionary<string, IPrimitiveMaterial> GetPrimitiveMaterials(IEnumerable<INdmPrimitive> ndmPrimitives)
|
||||
{
|
||||
Dictionary<string, IPrimitiveMaterial> primitiveMaterials = new Dictionary<string, IPrimitiveMaterial>();
|
||||
@@ -40,7 +44,13 @@ namespace StructureHelperLogics.NdmCalculations.Triangulations
|
||||
}
|
||||
return primitiveMaterials;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Return dictionary of ndm-materials by dictionary of primirive materials
|
||||
/// </summary>
|
||||
/// <param name="PrimitiveMaterials"></param>
|
||||
/// <param name="options"></param>
|
||||
/// <returns></returns>
|
||||
/// <exception cref="StructureHelperException"></exception>
|
||||
private static Dictionary<string, IMaterial> GetMaterials(Dictionary<string, IPrimitiveMaterial> PrimitiveMaterials, ITriangulationOptions options)
|
||||
{
|
||||
Dictionary<string, IMaterial> materials = new Dictionary<string, IMaterial>();
|
||||
@@ -49,7 +59,7 @@ namespace StructureHelperLogics.NdmCalculations.Triangulations
|
||||
foreach (string id in keyCollection)
|
||||
{
|
||||
IPrimitiveMaterial primitiveMaterial;
|
||||
if (PrimitiveMaterials.TryGetValue(id, out primitiveMaterial) == false) { throw new Exception("Material dictionary is not valid"); }
|
||||
if (PrimitiveMaterials.TryGetValue(id, out primitiveMaterial) == false) { throw new StructureHelperException("Material dictionary is not valid"); }
|
||||
material = GetMaterial(primitiveMaterial, options);
|
||||
materials.Add(id, material);
|
||||
}
|
||||
|
||||
@@ -4,12 +4,12 @@ using LoaderCalculator;
|
||||
using LoaderCalculator.Data.Matrix;
|
||||
using LoaderCalculator.Data.Ndms;
|
||||
using LoaderCalculator.Data.SourceData;
|
||||
using StructureHelperCommon.Models.Entities;
|
||||
using StructureHelperLogics.NdmCalculations.Triangulations;
|
||||
using StructureHelperLogics.Infrastructures.CommonEnums;
|
||||
using StructureHelperLogics.Models.Calculations.CalculationsResults;
|
||||
using StructureHelperLogics.Models.Calculations.CalculationProperties;
|
||||
using System;
|
||||
using StructureHelperLogics.Models.Primitives;
|
||||
|
||||
namespace StructureHelperLogics.Services
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user