Fix max spacing of stirrups

This commit is contained in:
Evgeny Redikultsev
2025-05-25 20:51:30 +05:00
parent add2ed8777
commit 4a6127d7fd
11 changed files with 175 additions and 19 deletions

View File

@@ -1,10 +1,5 @@
using Newtonsoft.Json;
using StructureHelperCommon.Models.Calculators;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DataAccess.DTOs
{

View File

@@ -0,0 +1,41 @@
using Newtonsoft.Json;
using StructureHelperCommon.Models;
using StructureHelperCommon.Models.Calculators;
using StructureHelperLogics.Models.BeamShears;
//Copyright (c) 2025 Redikultsev Evgeny, Ekaterinburg, Russia
//All rights reserved.
namespace DataAccess.DTOs.DTOEntities
{
internal class BeamShearCalculatorDTO : IBeamShearCalculator
{
[JsonProperty("Id")]
public Guid Id { get; }
[JsonProperty("Name")]
public string Name { get; set; } = string.Empty;
[JsonProperty("InputData")]
public IBeamShearCalculatorInputData InputData { get; set; }
[JsonProperty("ShowTraceData")]
public bool ShowTraceData { get; set; }
[JsonIgnore]
public IResult Result => throw new NotImplementedException();
[JsonIgnore]
public IShiftTraceLogger? TraceLogger { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
public BeamShearCalculatorDTO(Guid id)
{
Id = id;
}
public object Clone()
{
return this;
}
public void Run()
{
throw new NotImplementedException();
}
}
}

View File

@@ -0,0 +1,18 @@
using Newtonsoft.Json;
using StructureHelperCommon.Models.Forces;
using StructureHelperLogics.Models.BeamShears;
namespace DataAccess.DTOs.DTOEntities
{
internal class BeamShearCalculatorInputDataDTO : IBeamShearCalculatorInputData
{
[JsonProperty("Id")]
public Guid Id { get; }
[JsonProperty("Actions")]
public List<IBeamShearAction> Actions { get; } = new();
[JsonProperty("Sections")]
public List<IBeamShearSection> Sections { get; } = new();
[JsonProperty("Stirrups")]
public List<IStirrup> Stirrups { get; } = new();
}
}

View File

@@ -17,10 +17,14 @@ namespace DataAccess.DTOs.DTOEntities
public List<IBeamShearSection> Sections { get; } = new();
[JsonProperty("Stirrups")]
public List<IStirrup> Stirrups { get; } = new();
public BeamShearRepositoryDTO(Guid id)
{
Id = id;
}
public object Clone()
{
throw new NotImplementedException();
return this;
}
}
}

View File

@@ -0,0 +1,33 @@
using Newtonsoft.Json;
using StructureHelperCommon.Models.Shapes;
using StructureHelperLogics.Models.BeamShears;
using StructureHelperLogics.Models.Materials;
//Copyright (c) 2025 Redikultsev Evgeny, Ekaterinburg, Russia
//All rights reserved.
namespace DataAccess.DTOs.DTOEntities
{
public class BeamShearSectionDTO : IBeamShearSection
{
[JsonProperty("Id")]
public Guid Id { get; }
[JsonProperty("Name")]
public string? Name { get; set; }
[JsonProperty("Shape")]
public IShape Shape { get; set; }
[JsonProperty("Material")]
public IConcreteLibMaterial Material { get; set; }
[JsonProperty("CenterCover")]
public double CenterCover { get; set; }
public BeamShearSectionDTO(Guid id)
{
Id = id;
}
public object Clone()
{
return this;
}
}
}

View File

@@ -0,0 +1,23 @@
using Newtonsoft.Json;
using StructureHelperLogics.Models.BeamShears;
namespace DataAccess.DTOs.DTOEntities
{
public class StirrupByDensityDTO : IStirrupByDensity
{
[JsonProperty("Id")]
public Guid Id { get; }
[JsonProperty("Name")]
public string? Name { get; set; } = string.Empty;
[JsonProperty("StirrupDensity")]
public double StirrupDensity { get; set; }
[JsonProperty("CompressedGap")]
public double CompressedGap { get; set; }
public object Clone()
{
throw new NotImplementedException();
}
}
}

View File

@@ -0,0 +1,34 @@
using Newtonsoft.Json;
using StructureHelperLogics.Models.BeamShears;
using StructureHelperLogics.Models.Materials;
namespace DataAccess.DTOs.DTOEntities
{
public class StirrupByRebarDTO : IStirrupByRebar
{
[JsonProperty("Id")]
public Guid Id { get; }
[JsonProperty("Name")]
public string? Name { get; set; }
[JsonProperty("LegCount")]
public double LegCount { get; set; }
[JsonProperty("Diameter")]
public double Diameter { get; set; }
[JsonProperty("Material")]
public IReinforcementLibMaterial Material { get; set; }
[JsonProperty("Spacing")]
public double Spacing { get; set; }
[JsonProperty("CompressedGap")]
public double CompressedGap { get; set; }
public StirrupByRebarDTO(Guid id)
{
Id = id;
}
public object Clone()
{
return this;
}
}
}