-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge Objects dui3/alpha -> dev (#14)
* merge DUI3/Alpha into sdk * formatting * Objects changes * Objects tests * Unit test project
- Loading branch information
Showing
28 changed files
with
1,073 additions
and
366 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
83 changes: 83 additions & 0 deletions
83
src/Speckle.Objects/BuiltElements/Archicad/ArchicadOpening.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
using System.Collections.Generic; | ||
using Objects.Geometry; | ||
using Speckle.Core.Kits; | ||
using Speckle.Core.Models; | ||
|
||
namespace Objects.BuiltElements.Archicad; | ||
|
||
public class ArchicadOpening : Opening | ||
{ | ||
[SchemaInfo("ArchicadOpening", "Creates an Archicad opening.", "Archicad", "Structure")] | ||
public ArchicadOpening() { } | ||
|
||
public string parentApplicationId { get; set; } | ||
|
||
// Element base | ||
public string? elementType { get; set; } /*APINullabe*/ | ||
|
||
public List<Classification>? classifications { get; set; } /*APINullabe*/ | ||
public Base? elementProperties { get; set; } | ||
public Base? componentProperties { get; set; } | ||
|
||
// Floor Plan Parameters | ||
public string? floorPlanDisplayMode { get; set; } /*APINullabe*/ | ||
public string? connectionMode { get; set; } /*APINullabe*/ | ||
|
||
// Cut Surfaces Parameters | ||
public bool? cutsurfacesUseLineOfCutElements { get; set; } /*APINullabe*/ | ||
public short? cutsurfacesLinePenIndex { get; set; } /*APINullabe*/ | ||
public string? cutsurfacesLineIndex { get; set; } /*APINullabe*/ | ||
|
||
// Outlines Parameters | ||
public string? outlinesStyle { get; set; } /*APINullabe*/ | ||
public bool? outlinesUseLineOfCutElements { get; set; } /*APINullabe*/ | ||
public string? outlinesUncutLineIndex { get; set; } /*APINullabe*/ | ||
public string? outlinesOverheadLineIndex { get; set; } /*APINullabe*/ | ||
public short? outlinesUncutLinePenIndex { get; set; } /*APINullabe*/ | ||
public short? outlinesOverheadLinePenIndex { get; set; } /*APINullabe*/ | ||
|
||
// Opening Cover Fills Parameters | ||
public bool? useCoverFills { get; set; } /*APINullabe*/ | ||
public bool? useFillsOfCutElements { get; set; } /*APINullabe*/ | ||
public string? coverFillIndex { get; set; } /*APINullabe*/ | ||
public short? coverFillPenIndex { get; set; } /*APINullabe*/ | ||
public short? coverFillBackgroundPenIndex { get; set; } /*APINullabe*/ | ||
public string? coverFillOrientation { get; set; } /*APINullabe*/ // Kérdéses.. | ||
|
||
// Cover Fill Transformation Parameters | ||
public double? coverFillTransformationOrigoX { get; set; } | ||
public double? coverFillTransformationOrigoY { get; set; } | ||
public double? coverFillTransformationOrigoZ { get; set; } | ||
public double? coverFillTransformationXAxisX { get; set; } | ||
public double? coverFillTransformationXAxisY { get; set; } | ||
public double? coverFillTransformationXAxisZ { get; set; } | ||
public double? coverFillTransformationYAxisX { get; set; } | ||
public double? coverFillTransformationYAxisY { get; set; } | ||
public double? coverFillTransformationYAxisZ { get; set; } | ||
|
||
// Reference Axis Parameters | ||
public bool? showReferenceAxis { get; set; } /*APINullabe*/ | ||
public short? referenceAxisPenIndex { get; set; } /*APINullabe*/ | ||
public string? referenceAxisLineTypeIndex { get; set; } /*APINullabe*/ | ||
public double? referenceAxisOverhang { get; set; } /*APINullabe*/ | ||
|
||
// Extrusion Geometry Parameters | ||
// Plane Frame | ||
public Point extrusionGeometryBasePoint { get; set; } | ||
public Vector extrusionGeometryXAxis { get; set; } | ||
public Vector extrusionGeometryYAxis { get; set; } | ||
public Vector extrusionGeometryZAxis { get; set; } | ||
|
||
// Opening Extrustion Parameters | ||
public string? basePolygonType { get; set; } /*APINullabe*/ | ||
public double? width { get; set; } /*APINullabe*/ | ||
public double? height { get; set; } /*APINullabe*/ | ||
public string? constraint { get; set; } /*APINullabe*/ | ||
public string? anchor { get; set; } /*APINullabe */ | ||
public int? anchorIndex { get; set; } /*APINullabe*/ | ||
public double? anchorAltitude { get; set; } /*APINullabe*/ | ||
public string? limitType { get; set; } /*APINullabe*/ | ||
public double? extrusionStartOffSet { get; set; } /*APINullabe*/ | ||
public double? finiteBodyLength { get; set; } /*APINullabe*/ | ||
public string? linkedStatus { get; set; } /*APINullabe*/ | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
using Speckle.Core.Models; | ||
using Speckle.Newtonsoft.Json; | ||
|
||
namespace Objects.BuiltElements; | ||
|
||
public abstract class Baseline : Base | ||
{ | ||
protected Baseline() { } | ||
|
||
protected Baseline(string name, bool isFeaturelineBased) | ||
{ | ||
this.name = name; | ||
this.isFeaturelineBased = isFeaturelineBased; | ||
} | ||
|
||
/// <summary> | ||
/// The name of this baseline | ||
/// </summary> | ||
public string name { get; set; } | ||
|
||
/// <summary> | ||
/// The horizontal component of this baseline | ||
/// </summary> | ||
public abstract Alignment? alignment { get; internal set; } | ||
|
||
/// <summary> | ||
/// The vertical component of this baseline | ||
/// </summary> | ||
public abstract Profile? profile { get; internal set; } | ||
|
||
[DetachProperty] | ||
public Featureline? featureline { get; internal set; } | ||
|
||
public bool isFeaturelineBased { get; set; } | ||
} | ||
|
||
/// <summary> | ||
/// Generic instance class | ||
/// </summary> | ||
public abstract class Baseline<TA, TP> : Baseline | ||
where TA : Alignment | ||
where TP : Profile | ||
{ | ||
protected Baseline(string name, TA alignment, TP profile, Featureline? featureline, bool isFeaturelineBased) | ||
: base(name, isFeaturelineBased) | ||
{ | ||
this.name = name; | ||
typedAlignment = alignment; | ||
typedProfile = profile; | ||
this.featureline = featureline; | ||
this.isFeaturelineBased = isFeaturelineBased; | ||
} | ||
|
||
protected Baseline() | ||
: base(string.Empty, false) { } | ||
|
||
[JsonIgnore] | ||
public TA typedAlignment { get; set; } | ||
|
||
[JsonIgnore] | ||
public TP typedProfile { get; set; } | ||
|
||
[DetachProperty] | ||
public override Alignment? alignment | ||
{ | ||
get => typedAlignment; | ||
internal set | ||
{ | ||
if (value is TA typeA) | ||
{ | ||
typedAlignment = typeA; | ||
} | ||
} | ||
} | ||
|
||
[DetachProperty] | ||
public override Profile? profile | ||
{ | ||
get => typedProfile; | ||
internal set | ||
{ | ||
if (value is TP typeP) | ||
{ | ||
typedProfile = typeP; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
src/Speckle.Objects/BuiltElements/Civil/CivilAppliedAssembly.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
using System.Collections.Generic; | ||
using Speckle.Core.Models; | ||
|
||
namespace Objects.BuiltElements.Civil; | ||
|
||
public class CivilAppliedAssembly : Base | ||
{ | ||
public CivilAppliedAssembly() { } | ||
|
||
public CivilAppliedAssembly( | ||
List<CivilAppliedSubassembly> appliedSubassemblies, | ||
double adjustedElevation, | ||
string units | ||
) | ||
{ | ||
this.appliedSubassemblies = appliedSubassemblies; | ||
this.adjustedElevation = adjustedElevation; | ||
this.units = units; | ||
} | ||
|
||
public List<CivilAppliedSubassembly> appliedSubassemblies { get; set; } | ||
|
||
public double adjustedElevation { get; set; } | ||
|
||
public string units { get; set; } | ||
} |
37 changes: 37 additions & 0 deletions
37
src/Speckle.Objects/BuiltElements/Civil/CivilAppliedSubassembly.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
using System.Collections.Generic; | ||
using Objects.Geometry; | ||
using Objects.Other.Civil; | ||
using Speckle.Core.Models; | ||
|
||
namespace Objects.BuiltElements.Civil; | ||
|
||
public class CivilAppliedSubassembly : Base | ||
{ | ||
public CivilAppliedSubassembly() { } | ||
|
||
public CivilAppliedSubassembly( | ||
string subassemblyId, | ||
string subassemblyName, | ||
List<CivilCalculatedShape> shapes, | ||
Point stationOffsetElevationToBaseline, | ||
List<CivilDataField> parameters | ||
) | ||
{ | ||
this.subassemblyId = subassemblyId; | ||
this.subassemblyName = subassemblyName; | ||
this.shapes = shapes; | ||
this.stationOffsetElevationToBaseline = stationOffsetElevationToBaseline; | ||
this.parameters = parameters; | ||
} | ||
|
||
public string subassemblyId { get; set; } | ||
|
||
public string subassemblyName { get; set; } | ||
|
||
public List<CivilCalculatedShape> shapes { get; set; } | ||
|
||
public Point stationOffsetElevationToBaseline { get; set; } | ||
|
||
[DetachProperty] | ||
public List<CivilDataField> parameters { get; set; } | ||
} |
Oops, something went wrong.