fixed per izzy's suggestion for naming convention + circular dependency
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
"""Builtin Speckle object kit."""
|
||||
|
||||
from specklepy.objects.structural.analysis import *
|
||||
from specklepy.objects.structural.properties import *
|
||||
from specklepy.objects.structural.material import *
|
||||
from specklepy.objects.structural.geometry import *
|
||||
from specklepy.objects.structural.loading import *
|
||||
from specklepy.objects.structural.axis import Axis
|
||||
|
||||
__all__ = [
|
||||
"Element1D",
|
||||
"Element2D",
|
||||
"Element3D",
|
||||
"Axis",
|
||||
"Node",
|
||||
"Restraint",
|
||||
"Load",
|
||||
"LoadBeam",
|
||||
"LoadCase",
|
||||
"LoadCombinations",
|
||||
"LoadFace",
|
||||
"LoadGravity",
|
||||
"LoadNode",
|
||||
"Model",
|
||||
"ModelInfo",
|
||||
"ModelSettings",
|
||||
"ModelUnits",
|
||||
"Concrete",
|
||||
"Material",
|
||||
"Steel",
|
||||
"Timber",
|
||||
"Property",
|
||||
"Property1D",
|
||||
"Property2D",
|
||||
"Property3D",
|
||||
"PropertyDamper",
|
||||
"PropertyMass",
|
||||
"PropertySpring",
|
||||
"SectionProfile",
|
||||
]
|
||||
@@ -2,11 +2,9 @@ from enum import Enum
|
||||
import enum
|
||||
from typing import Any, List, Optional
|
||||
|
||||
from .base import Base
|
||||
from .encoding import CurveArray, CurveTypeEncoding, ObjectArray
|
||||
from .units import get_encoding_from_units, get_units_from_encoding
|
||||
from .geometry import *
|
||||
from .structural_properties import *
|
||||
from ..base import Base
|
||||
from ..geometry import *
|
||||
from .properties import *
|
||||
|
||||
STRUCTURAL_ANALYSIS = "Objects.Structural.Analysis."
|
||||
|
||||
@@ -27,7 +25,7 @@ class ModelUnits(Base, speckle_type=STRUCTURAL_ANALYSIS + "ModelUnits"):
|
||||
strain: str = None
|
||||
|
||||
|
||||
class ModelSetttings(Base, speckle_type=STRUCTURAL_ANALYSIS + "ModelSettings"):
|
||||
class ModelSettings(Base, speckle_type=STRUCTURAL_ANALYSIS + "ModelSettings"):
|
||||
modelUnits: ModelUnits = None
|
||||
steelCode: str = None
|
||||
concreteCode: str = None
|
||||
@@ -39,7 +37,7 @@ class ModelInfo(Base, speckle_type=STRUCTURAL_ANALYSIS + "ModelInfo"):
|
||||
description: str = None
|
||||
projectNumber: str = None
|
||||
projectName: str = None
|
||||
settings: ModelSetttings = None
|
||||
settings: ModelSettings = None
|
||||
initials: str = None
|
||||
application: str = None
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
from ..base import Base
|
||||
from ..geometry import Plane
|
||||
|
||||
|
||||
class Axis(Base, speckle_type="Objects.Structural.Geometry.Axis"):
|
||||
name: str = None
|
||||
axisType: str = None
|
||||
plane: Plane = None
|
||||
+4
-14
@@ -2,17 +2,15 @@ from enum import Enum
|
||||
import enum
|
||||
from typing import Any, List, Optional
|
||||
|
||||
from .base import Base
|
||||
from .encoding import CurveArray, CurveTypeEncoding, ObjectArray
|
||||
from .units import get_encoding_from_units, get_units_from_encoding
|
||||
from .geometry import *
|
||||
from .structural_properties import *
|
||||
from ..base import Base
|
||||
from ..geometry import *
|
||||
from .properties import *
|
||||
from .axis import Axis
|
||||
|
||||
STRUCTURAL_GEOMETRY = "Objects.Structural.Geometry"
|
||||
|
||||
|
||||
class ElementType1D(int, Enum):
|
||||
|
||||
Beam = 0
|
||||
Brace = 1
|
||||
Bar = 2
|
||||
@@ -30,7 +28,6 @@ class ElementType1D(int, Enum):
|
||||
|
||||
|
||||
class ElementType2D(int, Enum):
|
||||
|
||||
Quad4 = 0
|
||||
Quad8 = 1
|
||||
Triangle3 = 2
|
||||
@@ -38,7 +35,6 @@ class ElementType2D(int, Enum):
|
||||
|
||||
|
||||
class ElementType3D(int, Enum):
|
||||
|
||||
Brick8 = 0
|
||||
Wedge6 = 1
|
||||
Pyramid5 = 2
|
||||
@@ -111,9 +107,3 @@ class Element3D(Base, speckle_type=STRUCTURAL_GEOMETRY + ".Element3D"):
|
||||
|
||||
|
||||
# class Storey needs ependency on built elements first
|
||||
|
||||
|
||||
class Axis(Base, speckle_type=STRUCTURAL_GEOMETRY + ".Axis"):
|
||||
name: str = None
|
||||
axisType: str = None
|
||||
plane: Plane = None
|
||||
@@ -1,10 +1,8 @@
|
||||
from enum import Enum
|
||||
from typing import Any, List, Optional
|
||||
|
||||
from .base import Base
|
||||
from .encoding import CurveArray, CurveTypeEncoding, ObjectArray
|
||||
from .units import get_encoding_from_units, get_units_from_encoding
|
||||
from .structural_geometry import *
|
||||
from ..base import Base
|
||||
from .geometry import *
|
||||
|
||||
STRUCTURAL_LOADING = "Objects.Structural.Loading."
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
from enum import Enum
|
||||
from typing import Any, List, Optional
|
||||
|
||||
from .base import Base
|
||||
from .encoding import CurveArray, CurveTypeEncoding, ObjectArray
|
||||
from .units import get_encoding_from_units, get_units_from_encoding
|
||||
from ..base import Base
|
||||
|
||||
|
||||
STRUCTURAL_MATERIALS = "Objects.Structural.Materials"
|
||||
|
||||
+16
-18
@@ -1,13 +1,11 @@
|
||||
from enum import Enum
|
||||
from typing import Any, List, Optional
|
||||
|
||||
from .structural_geometry import Axis
|
||||
|
||||
from .base import Base
|
||||
from .encoding import CurveArray, CurveTypeEncoding, ObjectArray
|
||||
from .units import get_encoding_from_units, get_units_from_encoding
|
||||
from ..base import Base
|
||||
|
||||
from .structural_material import *
|
||||
from .material import *
|
||||
from .axis import Axis
|
||||
|
||||
|
||||
STRUCTURAL_PROPERTY = "Objectives.Structural.Properties"
|
||||
@@ -96,6 +94,18 @@ class Property(Base, speckle_type=STRUCTURAL_PROPERTY):
|
||||
name: str = None
|
||||
|
||||
|
||||
class SectionProfile(Base, speckle_type=STRUCTURAL_PROPERTY + ".SectionProfile"):
|
||||
name: str = None
|
||||
shapeType: ShapeType = None
|
||||
area: float = 0.0
|
||||
Iyy: float = 0.0
|
||||
Izz: float = 0.0
|
||||
J: float = 0.0
|
||||
Ky: float = 0.0
|
||||
weight: float = 0.0
|
||||
units: str = None
|
||||
|
||||
|
||||
class Property1D(Property, speckle_type=STRUCTURAL_PROPERTY + ".Property1D"):
|
||||
memberType: MemberType = None
|
||||
Material: Material = None
|
||||
@@ -174,18 +184,6 @@ class PropertySpring(Property, speckle_type=STRUCTURAL_PROPERTY + ".PropertySpri
|
||||
frictionCoefficient: float = 0.0
|
||||
|
||||
|
||||
class SectionProfile(Base, speckle_type=STRUCTURAL_PROPERTY + ".SectionProfile"):
|
||||
name: str = None
|
||||
shapeType: ShapeType = None
|
||||
area: float = 0.0
|
||||
Iyy: float = 0.0
|
||||
Izz: float = 0.0
|
||||
J: float = 0.0
|
||||
Ky: float = 0.0
|
||||
weight: float = 0.0
|
||||
units: str = None
|
||||
|
||||
|
||||
class ReferenceSurfaceEnum(int, Enum):
|
||||
Concrete = 0
|
||||
Steel = 1
|
||||
@@ -213,4 +211,4 @@ class shapeType(int, Enum):
|
||||
Rebar = 8
|
||||
Tendon = 9
|
||||
ColdFormed = 10
|
||||
Other = 11
|
||||
Other = 11
|
||||
Reference in New Issue
Block a user