[][src]Struct nitric_component::impls::FlatUsize

pub struct FlatUsize { /* fields omitted */ }

A usize-based ID using the FlatAllocator and a FlatBitSet.

Examples

use nitric_component::impls::FlatUsize;

#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct ClientId(pub FlatUsize);

Methods

impl FlatUsize
[src]

Returns the inner usize.

Trait Implementations

impl Allocator<FlatUsize> for FlatAllocator
[src]

impl Create<FlatUsize> for FlatAllocator
[src]

impl CreateChecked<FlatUsize> for FlatAllocator
[src]

impl Delete<FlatUsize> for FlatAllocator
[src]

Makes sure id is deleted, ignoring the case where deletion fails due to an invalid ID. See Delete::delete. Read more

impl MergeDeleted<FlatUsize> for FlatAllocator
[src]

impl Id for FlatUsize
[src]

The allocator which manages IDs of this type.

The unique key of this ID.

impl MergingDeletion for FlatUsize
[src]

The merger for this ID. You should make sure that the merger cannot be duplicated. It's usually a good idea to use nitric_component::allocator::Merger for this. Read more

Checks if this ID is valid and returns a CheckedId which implements ValidId, or an error in case self is invalid. Read more

impl SparseLinear for FlatUsize
[src]

This is the bit set type that can be used by the storage. A storage which maps this ID type stores a field of type Self::BitSet, which will be used to check if a component exists for a particular ID. Read more

Convenience method for retrieving the usize key of this ID. This does not guarantee validity and is equivalent to as_key_unchecked. Read more

impl Into<usize> for FlatUsize
[src]

impl PartialOrd<FlatUsize> for FlatUsize
[src]

impl Ord for FlatUsize
[src]

Compares and returns the maximum of two values. Read more

Compares and returns the minimum of two values. Read more

impl PartialEq<FlatUsize> for FlatUsize
[src]

impl From<usize> for FlatUsize
[src]

impl Clone for FlatUsize
[src]

Performs copy-assignment from source. Read more

impl Copy for FlatUsize
[src]

impl Eq for FlatUsize
[src]

impl Debug for FlatUsize
[src]

impl Hash for FlatUsize
[src]

Feeds a slice of this type into the given [Hasher]. Read more

Auto Trait Implementations

impl Send for FlatUsize

impl Sync for FlatUsize

Blanket Implementations

impl<T> MergingDeletion for T where
    T: WrapperId,
    <T as WrapperId>::Original: Id,
    <T as WrapperId>::Original: MergingDeletion,
    <<T as WrapperId>::Original as Id>::Key == <T as Id>::Key
[src]

The merger for this ID. You should make sure that the merger cannot be duplicated. It's usually a good idea to use nitric_component::allocator::Merger for this. Read more

Checks if this ID is valid and returns a CheckedId which implements ValidId, or an error in case self is invalid. Read more

impl<T> SparseLinear for T where
    T: Id<Key = usize> + WrapperId,
    <T as WrapperId>::Original: SparseLinear
[src]

This is the bit set type that can be used by the storage. A storage which maps this ID type stores a field of type Self::BitSet, which will be used to check if a component exists for a particular ID. Read more

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

impl<T> From for T
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> BorrowMut for T where
    T: ?Sized
[src]