pub struct PlacedSolid<'a> {
pub name: String,
pub instance: String,
pub reader: Reader<'a>,
pub model: Cow<'a, NamedModel>,
pub solid: SolidId,
pub pose: Option<Pose>,
}Expand description
A solid of a part, or of a part placed in it: named as the part names it
(/pin:extrude(pin) for one of the part placed as pin, see
Located::key), where it is.
Fields§
§name: String§instance: StringThe path of the part placed it is of: empty for the part’s own.
reader: Reader<'a>The part it is a solid of — whose material it is made of.
model: Cow<'a, NamedModel>§solid: SolidId§pose: Option<Pose>Where its part is placed; None for the part’s own solids.
Implementations§
Source§impl PlacedSolid<'_>
impl PlacedSolid<'_>
Sourcepub fn thickness(&self) -> Option<f64>
pub fn thickness(&self) -> Option<f64>
The thickness of the sheet it is bent from (mm), for a sheet-metal
body (see crate::SolidNote::thickness).
Sourcepub fn material(&self) -> Option<Material>
pub fn material(&self) -> Option<Material>
What it is made of: its part’s material, none where it is not given.
Sourcepub fn shape_properties(
&self,
shapes: &mut Shapes,
) -> GeopResult<MassProperties>
pub fn shape_properties( &self, shapes: &mut Shapes, ) -> GeopResult<MassProperties>
The mass properties of its shape alone, where it is: of density one,
so its mass is its volume and its centre the centroid — what it has
whatever it is made of. Its shape’s are taken from shapes.
Sourcepub fn mass_properties(
&self,
shapes: &mut Shapes,
) -> GeopResult<Option<MassProperties>>
pub fn mass_properties( &self, shapes: &mut Shapes, ) -> GeopResult<Option<MassProperties>>
Its mass properties, where it is, of its part’s material: none for a
solid of no material, which has no mass. Its shape’s are taken from
shapes.