pub enum VertexAnchor {
Node(NodeIdType),
Curve(CurveIdType),
Surface(SurfaceIdType),
Body(BodyIdType),
}
Expand description
Geometrical mesh anchor.
This enum is used as an attribute to link mesh vertices to entities of the represented geometry.
The AttributeUpdate
implementation is used to enforce the dimensional conditions required to
merge two anchors. The merge-ability of two anchors also depends on their intersection; we
expect this to be handled outside of the merge functor, as doing it inside would require leaking
map data into the trait’s methods.
Variants§
Node(NodeIdType)
Vertex is linked to a node.
Curve(CurveIdType)
Vertex is linked to a curve.
Surface(SurfaceIdType)
Vertex is linked to a surface.
Body(BodyIdType)
Vertex is linked to a 3D body.
Trait Implementations§
Source§impl AttributeBind for VertexAnchor
impl AttributeBind for VertexAnchor
Source§const BIND_POLICY: OrbitPolicy = OrbitPolicy::Vertex
const BIND_POLICY: OrbitPolicy = OrbitPolicy::Vertex
[
OrbitPolicy
] determining the kind of topological entity to which the attribute
is associated.Source§type StorageType = AttrSparseVec<VertexAnchor>
type StorageType = AttrSparseVec<VertexAnchor>
Storage type used for the attribute.
Source§type IdentifierType = u32
type IdentifierType = u32
Identifier type of the entity the attribute is bound to.
Source§impl AttributeUpdate for VertexAnchor
impl AttributeUpdate for VertexAnchor
Source§fn merge(attr1: Self, attr2: Self) -> Result<Self, AttributeError>
fn merge(attr1: Self, attr2: Self) -> Result<Self, AttributeError>
Merging routine, i.e. how to obtain a new value from two existing ones. Read more
Source§fn split(attr: Self) -> Result<(Self, Self), AttributeError>
fn split(attr: Self) -> Result<(Self, Self), AttributeError>
Splitting routine, i.e. how to obtain the two new values from a single one. Read more
§fn merge_incomplete(_: Self) -> Result<Self, AttributeError>
fn merge_incomplete(_: Self) -> Result<Self, AttributeError>
Fallback merging routine, i.e. how to obtain a new value from a single existing one. Read more
§fn merge_from_none() -> Result<Self, AttributeError>
fn merge_from_none() -> Result<Self, AttributeError>
Fallback merging routine, i.e. how to obtain a new value from no existing one. Read more
§fn split_from_none() -> Result<(Self, Self), AttributeError>
fn split_from_none() -> Result<(Self, Self), AttributeError>
Fallback splitting routine, i.e. how to obtain two new values from no existing one. Read more
Source§impl Clone for VertexAnchor
impl Clone for VertexAnchor
Source§fn clone(&self) -> VertexAnchor
fn clone(&self) -> VertexAnchor
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for VertexAnchor
impl Debug for VertexAnchor
Source§impl Hash for VertexAnchor
impl Hash for VertexAnchor
Source§impl PartialEq for VertexAnchor
impl PartialEq for VertexAnchor
impl Copy for VertexAnchor
impl Eq for VertexAnchor
impl StructuralPartialEq for VertexAnchor
Auto Trait Implementations§
impl Freeze for VertexAnchor
impl RefUnwindSafe for VertexAnchor
impl Send for VertexAnchor
impl Sync for VertexAnchor
impl Unpin for VertexAnchor
impl UnwindSafe for VertexAnchor
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Converts
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
, which can then be
downcast
into Box<dyn ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Converts
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
, which can then be further
downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Converts
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Converts
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSend for T
impl<T> DowncastSend for T
§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more