pub struct PlanSection { /* private fields */ }Expand description
The plan section several objects share: the intersection of their footprints, such as the clear shaft of spaces stacked into a light well.
Implementations§
Source§impl PlanSection
impl PlanSection
Sourcepub fn try_new(
objects: Vec<ObjectId>,
area: (f64, f64),
sides: Option<(PlanLength, PlanLength)>,
evidence: Evidence,
) -> Result<Self, PlanSpanError>
pub fn try_new( objects: Vec<ObjectId>, area: (f64, f64), sides: Option<(PlanLength, PlanLength)>, evidence: Evidence, ) -> Result<Self, PlanSpanError>
The section of objects, with an area in [lower, upper] square
metres and, unless it is empty, the short and long sides of its
least-area enclosing rectangle, the one PlanRectangle describes
for a footprint. A service states sides only for a unique
orientation (RectangleOrientation::Unique) and refuses a section
whose least-area rectangles may have other sides.
The evidence is exact exactly when the area is a point. An empty section (upper bound zero) has no rectangle, and any other has one.
Sourcepub fn area_lower(&self) -> f64
pub fn area_lower(&self) -> f64
Smallest the section’s area can be, in square metres.
Sourcepub fn area_upper(&self) -> f64
pub fn area_upper(&self) -> f64
Largest the section’s area can be, in square metres.
Sourcepub fn width(&self) -> Option<&PlanLength>
pub fn width(&self) -> Option<&PlanLength>
The short side of the section’s minimum-area enclosing rectangle,
its width; None for an empty section.
Sourcepub fn length(&self) -> Option<&PlanLength>
pub fn length(&self) -> Option<&PlanLength>
The long side of the section’s minimum-area enclosing rectangle;
None for an empty section.