StructuralCurveMemberVarying Class |
[This is preliminary documentation and is subject to change.]
Namespace: ModelExchanger.AnalysisDataModel.StructuralElements
public sealed class StructuralCurveMemberVarying : StructuralAnalysisObjectBase, IEquatable<StructuralCurveMemberVarying>
The StructuralCurveMemberVarying type exposes the following members.
Name | Description | |
---|---|---|
StructuralCurveMemberVarying |
Create an arbitrary definition defined by the provided segments
|
Name | Description | |
---|---|---|
Id |
The ID of the Analysis object.
Needs to be unique within the entire model
(Inherited from StructuralAnalysisObjectBase.) | |
Name |
The name of the Analysis object.
Needs to be unique within it's type
(Inherited from StructuralAnalysisObjectBase.) | |
Segments |
The segments which make up the arbitrary definition
|
Name | Description | |
---|---|---|
Equals(Object) |
Check if this object is the same as the provided object.
(Overrides StructuralAnalysisObjectBaseEquals(Object).) | |
Equals(StructuralAnalysisObjectBase) |
Check if this object is the same as the provided object.
(Inherited from StructuralAnalysisObjectBase.) | |
Equals(StructuralCurveMemberVarying) | Indicates whether the current object is equal to another object of the same type. | |
GetHashCode |
Retrieves the hashcode of the object
(Overrides StructuralAnalysisObjectBaseGetHashCode.) |
Name | Description | |
---|---|---|
PropertyChanged | (Inherited from StructuralAnalysisObjectBase.) |
using System; using System.Collections.Generic; using System.Linq; using ModelExchanger.AnalysisDataModel.Enums; using ModelExchanger.AnalysisDataModel.Libraries; using ModelExchanger.AnalysisDataModel.Models; using ModelExchanger.AnalysisDataModel.StructuralElements; using ModelExchanger.AnalysisDataModel.Subtypes; namespace ModelExchanger.AnalysisDataModel.Example.StructuralElements { public sealed class StructuralCurveMemberVaryingExample : BaseExample<StructuralCurveMemberVarying> { protected override IReadOnlyCollection<StructuralCurveMemberVarying> CreateAnalysisObjects(AnalysisModel model) { IReadOnlyDictionary<string, StructuralCrossSection> crossSections = model.OfType<StructuralCrossSection>().ToDictionary(x => x.Name, x => x); return new List<StructuralCurveMemberVarying>() { new StructuralCurveMemberVarying(Guid.NewGuid(), "AD1", new [] { CreateArbitraryDefinitionSegment(crossSections["CS1"], 0.25, CurveAlignment.Centre), CreateArbitraryDefinitionSegment(crossSections["CS1"], crossSections["CS9"], 0.5, CurveAlignment.BottomLeft), CreateArbitraryDefinitionSegment(crossSections["CS1"], 0.25, CurveAlignment.BottomRight) }) }; } #region ArbitraryDefinitionSegment /// <summary> /// Create an arbitrary definition segment which consists out of single profile with a given span and alignment /// </summary> /// <param name="crossSection">The cross section of the segment</param> /// <param name="span">How much the segment spans across the beam, expressed in a relative number (0 ... 1)</param> /// <param name="alignment">Defines how the system line is positioned</param> /// <returns>A segment that is part of an arbitrary definition</returns> private ArbitraryDefinitionSegment CreateArbitraryDefinitionSegment(StructuralCrossSection crossSection, double span, CurveAlignment alignment) { return new ArbitraryDefinitionSegment(crossSection, span, alignment); } /// <summary> /// Create an arbitrary definition segment which consists out of two different profiles with a given span and alignment /// </summary> /// <param name="crossSectionBegin">The cross section at the beginning of the segment</param> /// <param name="crossSectionEnd">The cross section at the end of the segment</param> /// <param name="span">How much the segment spans across the beam, expressed in a relative number (0 ... 1)</param> /// <param name="alignment">Defines how the system line is positioned</param> /// <returns></returns> private ArbitraryDefinitionSegment CreateArbitraryDefinitionSegment(StructuralCrossSection crossSectionBegin, StructuralCrossSection crossSectionEnd, double span, CurveAlignment alignment) { return new ArbitraryDefinitionSegment(crossSectionBegin, crossSectionEnd, span, alignment); } #endregion } }