compas_cadwork.materials
¤
Attributes¤
AnyLayerStack
module-attribute
¤
AnyLayerStack: TypeAlias = FloorLayerStack | RoofLayerStack | WallLayerStack
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
-
API Reference
compas_cadwork ClassesProject Methods:
-
API Reference
compas_cadwork ClassesProject Methods:
Classes¤
FloorLayerStack
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
-
API Reference
materials AttributesAnyLayerStack
Layer
dataclass
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Material layer.
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
-
API Reference
materials ClassesLayerStack Methods:
-
API Reference
materials ClassesLayerStack Methods:
Attributes¤
material
instance-attribute
¤
material: Material
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Layer material.
name
instance-attribute
¤
name: str
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Layer name.
thickness
instance-attribute
¤
thickness: float
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Layer thickness in millimeters.
type
instance-attribute
¤
type: LayerType
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Layer type.
Methods:¤
__post_init__
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
LayerStack
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
A collection of material layers to be used in elements with multi-layer support.
In Cadwork, these are called multi-layer covers or sets.
Create new instance wrapping a Cadwork multi-layer set.
Note
Avoid calling directly, use Project.layer_stack() instead to get an error in case of invalid ID.
Parameters:
-
cadwork_id(MultiLayerSetId) –Cadwork multi-layer set ID.
Attributes¤
id
instance-attribute
¤
id: Final[MultiLayerSetId] = cadwork_id
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
name
property
writable
¤
name: str
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Layer stack name.
Methods:¤
__delitem__
¤
| Software compatibility: | ||
|---|---|---|
| ❌ Cadwork 2024 | ❌ Cadwork 2025 | ✅ Cadwork 2026 |
__eq__
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
__getitem__
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
__iter__
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
LayerType
¤
Layer type.
Attributes¤
AIR
class-attribute
instance-attribute
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
COVERING
class-attribute
instance-attribute
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
LATHING
class-attribute
instance-attribute
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
PANEL
class-attribute
instance-attribute
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
STRUCTURE
class-attribute
instance-attribute
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
UNDEFINED
class-attribute
instance-attribute
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Methods:¤
from_cadwork
classmethod
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Get value from Cadwork multi layer type.
Parameters:
-
raw_type(multi_layer_type) –Cadwork multi layer type.
Returns:
-
LayerType–Layer type.
Raises:
-
ValueError–If cannot determine the correct mapping type.
to_cadwork
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Convert value to Cadwork multi layer type.
Returns:
-
multi_layer_type–Cadwork multi layer type.
Material
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
A material used in a Cadwork project.
Create new instance wrapping a Cadwork material.
Note
Avoid calling directly, use Project.material() instead to get an error in case of invalid ID.
Parameters:
-
cadwork_id(MaterialId) –Cadwork material ID.
- API Reference
Attributes¤
group
property
writable
¤
group: str | None
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Material group name.
id
instance-attribute
¤
id: Final[MaterialId] = cadwork_id
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
name
property
writable
¤
name: str
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Material name.
Note
This has to be unique, no other material in the project can have the same name.
Methods:¤
__eq__
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
create
classmethod
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
Create new material.
Parameters:
-
name(str) –New material name.
-
raise_on_duplicate(bool, default:True) –Whether to raise an error if the material name is already in use. Otherwise, returns the existing material.
Returns:
-
Material–New material instance.
Raises:
-
ValueError–If material name is empty or already in use.
RoofLayerStack
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
-
API Reference
materials AttributesAnyLayerStack
WallLayerStack
¤
| Software compatibility: | ||
|---|---|---|
| ✅ Cadwork 2024 | ✅ Cadwork 2025 | ✅ Cadwork 2026 |
-
API Reference
materials AttributesAnyLayerStack