pub struct LaidOut { /* private fields */ }Expand description
A copy of a design and its layout, laid out once by Rocket::lay_out, to check it and
assemble it (LaidOut::into_assembly) without laying it out again. Its fields are private,
so the layout is always the design’s own.
Implementations§
Source§impl LaidOut
impl LaidOut
Sourcepub fn layout(&self) -> &Layout
pub fn layout(&self) -> &Layout
The layout (Rocket::layout).
Sourcepub fn into_assembly(
self,
configuration_id: &str,
) -> Result<(Rocket, Assembly), DesignError>
pub fn into_assembly( self, configuration_id: &str, ) -> Result<(Rocket, Assembly), DesignError>
As Rocket::assemble, on this layout, which it takes rather than copies, with the design
given back.
§Errors
- As
Layout::place_motors. DesignError::UnknownIdfor a configuration that doesn’t exist.
Sourcepub fn relay(&self, rocket: Rocket) -> Result<LaidOut, DesignError>
pub fn relay(&self, rocket: Rocket) -> Result<LaidOut, DesignError>
rocket laid out, as Rocket::lay_out lays it out. Where rocket differs from this
design only in its stages’ overrides (mass, center of mass, inertia) and its
configurations (motors), this layout’s parts are kept and only the stages are done again,
which gives the same layout bit for bit when the rest of the two designs is bitwise
equal, as a copy’s is (two values equal under == can still differ in a zero’s sign):
placing the parts is most of a layout’s cost, and a Monte Carlo sample changes nothing
else. Any other difference lays rocket out from the start.
§Errors
As Rocket::lay_out.