pub struct PartPattern;Expand description
Places copies of the part placed by the step part — the same part,
built once — wherever frames puts them (see Frames): in a row
or a grid, round an axis, along a curve, at points — the part at the
first — from a table of offsets, filling a face, or at the holes of a
feature, of the part or of a part placed in it. Each copy is a placed
part of its own, named part_pattern(P,i) for the step P and the
copy labelled i — 1, 2, …, or i.j in a grid or a fill —
its entities behind that name like any placed part’s:
part_pattern(bolts,2)/extrude(head,end).
A copy goes where the pattern puts it, relative to where the part is — no mate moves it, and when the part moves, its copies move with it. What the copies are laid out along, round or at is picked in the part or in a part placed in it, where it is as the copies are placed.
Trait Implementations§
Source§impl Clone for PartPattern
impl Clone for PartPattern
Source§fn clone(&self) -> PartPattern
fn clone(&self) -> PartPattern
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for PartPattern
Source§impl Debug for PartPattern
impl Debug for PartPattern
Source§impl Default for PartPattern
impl Default for PartPattern
Source§fn default() -> PartPattern
fn default() -> PartPattern
Source§impl<'de> Deserialize<'de> for PartPattern
impl<'de> Deserialize<'de> for PartPattern
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Editable for PartPattern
impl Editable for PartPattern
const INFO: OperationInfo = <PartPattern as ::geop_core_editor::part_operation::PartOperation>::INFO
Source§type EditingState = FormState<<PartPattern as PartOperation>::Session>
type EditingState = FormState<<PartPattern as PartOperation>::Session>
Source§fn new_args(context: &Context<'_>) -> Self::Args
fn new_args(context: &Context<'_>) -> Self::Args
Source§fn presentation(
context: &Context<'_>,
args: &Self::Args,
editing: &Self::EditingState,
) -> Form
fn presentation( context: &Context<'_>, args: &Self::Args, editing: &Self::EditingState, ) -> Form
Source§fn process_user_event(
context: &Context<'_>,
args: &Self::Args,
editing: &Self::EditingState,
event: Event,
) -> (Self::Args, Self::EditingState)
fn process_user_event( context: &Context<'_>, args: &Self::Args, editing: &Self::EditingState, event: Event, ) -> (Self::Args, Self::EditingState)
event.Source§impl Operation for PartPattern
impl Operation for PartPattern
Source§const KIND: &'static str = <PartPattern as ::geop_core_editor::part_operation::PartOperation>::KIND
const KIND: &'static str = <PartPattern as ::geop_core_editor::part_operation::PartOperation>::KIND
Source§type Args = <PartPattern as PartOperation>::Args
type Args = <PartPattern as PartOperation>::Args
Source§fn run(ctx: &mut StepContext<'_>, args: &Self::Args) -> __GeopResult<()>
fn run(ctx: &mut StepContext<'_>, args: &Self::Args) -> __GeopResult<()>
ctx (see
StepContext::produce): cheap, since it runs in every run. What
takes work is done in the makes, which run only when what they read
changed.Source§impl PartOperation for PartPattern
impl PartOperation for PartPattern
Source§fn new_args(context: &Context<'_>) -> PartPatternArgs
fn new_args(context: &Context<'_>) -> PartPatternArgs
The newest placed part, six round an axis still to pick.
Source§fn run(ctx: &mut StepContext<'_>, args: &PartPatternArgs) -> GeopResult<()>
fn run(ctx: &mut StepContext<'_>, args: &PartPatternArgs) -> GeopResult<()>
Places the copies, each where the pattern puts it after the part: the axis resolved in the part as the steps before left it.
Which copies there are, and where, is a node of its own ([plan]),
made from what it reads of the part: the step declares a copy for
each motion it holds and computes nothing itself.
Source§fn form<'a>(
context: &'a Context<'a>,
args: &PartPatternArgs,
_: &FormState<()>,
) -> EditForm<'a, PartPatternArgs>
fn form<'a>( context: &'a Context<'a>, args: &PartPatternArgs, _: &FormState<()>, ) -> EditForm<'a, PartPatternArgs>
The part to copy, and where the copies go.
const INFO: OperationInfo
Source§type Args = PartPatternArgs
type Args = PartPatternArgs
Source§type Session = ()
type Session = ()
() for most.