pub struct FixedHandleImpl<Type, InnerOuter: InnerOuterMarker> { /* private fields */ }
Expand description

Internal type definition that is only exposed for documentation purposes.

Rust will currently not generate documentation for type definitions depending pub(crate) types, see #32077.

Do not use these types. Their removal will not be considered a breaking change.

Implementations§

source§

impl FixedHandleImpl<VertexTag, InnerTag>

source

pub fn from_index(index: usize) -> Self

Creates a new vertex handle from a usize.

Ideally, this method should only be used in advanced scenarios as it allows to create invalid vertex handles. When possible, attempt to retrieve handles by other means instead (see crate::handles).

Panics

Panics if index >= 2^32

source§

impl<Type: Default, InnerOuter: InnerOuterMarker> FixedHandleImpl<Type, InnerOuter>

source

pub fn index(&self) -> usize

Returns the internal index of this element.

Indices of the same handle type are guaranteed to be unique (e.g. different vertices will have different indices from each other).

Indices will always be in the interval 0 .. number_of_elements (e.g. the number of directed edges).

Adding vertices will not change any indices. Vertex removal does affect indices - the index of elements may change to swap-fill any gaps that were created.

source§

impl FixedHandleImpl<DirectedEdgeTag, InnerTag>

source

pub fn rev(self) -> Self

Returns this edge with its direction reversed.

If this edge points from v0 to v1, the returned edge would point from v1 to v0. Calling rev twice will always return the original vertex.

source

pub fn as_undirected(self) -> FixedUndirectedEdgeHandle

Converts this directed edge handle into an undirected edge handle.

See also the handles module for more information.

source§

impl FixedHandleImpl<FaceTag, PossiblyOuterTag>

source

pub fn is_outer(&self) -> bool

Returns true if this face is the single outer face.

source

pub fn as_inner(&self) -> Option<FixedFaceHandle<InnerTag>>

Converts this face handle to an inner face.

Returns None if this handle refers to the single outer face.

source§

impl FixedHandleImpl<UndirectedEdgeTag, InnerTag>

source

pub fn as_directed(&self) -> FixedDirectedEdgeHandle

Converts this directed edge into an undirected edge handle.

Any of the two directed edges may be returned.

See also FixedDirectedEdgeHandle::as_undirected

source

pub fn directed_edges(&self) -> [FixedDirectedEdgeHandle; 2]

Returns the two directed edges of this undirected edge in any order.

Trait Implementations§

source§

impl<Type: Clone, InnerOuter: Clone + InnerOuterMarker> Clone for FixedHandleImpl<Type, InnerOuter>

source§

fn clone(&self) -> FixedHandleImpl<Type, InnerOuter>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<Type, InnerOuter: InnerOuterMarker> Debug for FixedHandleImpl<Type, InnerOuter>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<Type: Hash, InnerOuter: Hash + InnerOuterMarker> Hash for FixedHandleImpl<Type, InnerOuter>

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<Type: Ord, InnerOuter: Ord + InnerOuterMarker> Ord for FixedHandleImpl<Type, InnerOuter>

source§

fn cmp(&self, other: &FixedHandleImpl<Type, InnerOuter>) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl<Type: PartialEq, InnerOuter: PartialEq + InnerOuterMarker> PartialEq for FixedHandleImpl<Type, InnerOuter>

source§

fn eq(&self, other: &FixedHandleImpl<Type, InnerOuter>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<Type: PartialOrd, InnerOuter: PartialOrd + InnerOuterMarker> PartialOrd for FixedHandleImpl<Type, InnerOuter>

source§

fn partial_cmp( &self, other: &FixedHandleImpl<Type, InnerOuter> ) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl<Type: Copy, InnerOuter: Copy + InnerOuterMarker> Copy for FixedHandleImpl<Type, InnerOuter>

source§

impl<Type: Eq, InnerOuter: Eq + InnerOuterMarker> Eq for FixedHandleImpl<Type, InnerOuter>

source§

impl<Type, InnerOuter: InnerOuterMarker> StructuralEq for FixedHandleImpl<Type, InnerOuter>

source§

impl<Type, InnerOuter: InnerOuterMarker> StructuralPartialEq for FixedHandleImpl<Type, InnerOuter>

Auto Trait Implementations§

§

impl<Type, InnerOuter> RefUnwindSafe for FixedHandleImpl<Type, InnerOuter>
where InnerOuter: RefUnwindSafe, Type: RefUnwindSafe,

§

impl<Type, InnerOuter> Send for FixedHandleImpl<Type, InnerOuter>
where InnerOuter: Send, Type: Send,

§

impl<Type, InnerOuter> Sync for FixedHandleImpl<Type, InnerOuter>
where InnerOuter: Sync, Type: Sync,

§

impl<Type, InnerOuter> Unpin for FixedHandleImpl<Type, InnerOuter>
where InnerOuter: Unpin, Type: Unpin,

§

impl<Type, InnerOuter> UnwindSafe for FixedHandleImpl<Type, InnerOuter>
where InnerOuter: UnwindSafe, Type: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.