Expand description
Crate-agnostic general data structures.
This module provides general data structures you can use regardless of ECS.
The data structures might not be used directly on client code, but it may be
useful for general need. For instance, AnyVec in this module is a vector
which is able to contain type-erased values. That is useful when you need
to store vectors of various types in a single variable.
Modules§
- prelude
- Imports things that is likely needed in ECS functinos.
Macros§
- tinfo
- Creates
TypeInfofrom the given type and reflects whether the type implementsSend,Sync,Default, andCloneto the TypeInfo.
Structs§
- ATypeId
- A
TypeIdExtwith a salt type. - AnyVec
- A type-erased vector containing values of the same type.
- Array
- An array type like
[T; N], but providing some methods ofVec. - Array
Deque - An array type like
[T; N], but providing some methods ofVecDeque. - Borrowed
- A type generated by
Holderthat wraps a value in it shallowly. - Chunk
AnyVec - A type-erased vector containing values of the same type.
- Debug
Helper - A helper type for the
FnFmtRaw. - Dedup
Vec - Deduplicated vector.
- Flat
Iter - An iterator that can be created from
FlatRawIterwith concrete type and lifetime. - Flat
Iter Mut - A mutable iterator that can be created from
FlatRawIterwith concrete type and lifetime. - Flat
RawIter - A type-erased nested iterator.
- GenQueue
- A queue with generation.
- Getter
- A getter that can be created from
RawGetterwith concrete type and lifetime. - Getter
Mut - A mutable getter that can be created from
RawGetterwith concrete type and lifetime. - Group
Desc - A descriptor for
GroupMap. - Group
Map - A hash map containing Groups and Items.
- Holder
- A type that holds a value and allows us borrow the value.
- Indexed
Map - A hash map that you can find a value by an index as well.
- Into
Iter - An owning iterator over key-value pairs of
SetList. - Into
Values - An owning iteartor over values of
SetList. - Iter
- An iterator that can be created from
RawIterwith concrete type and lifetime. - IterMut
- A mutable iterator that can be created from
RawIterwith concrete type and lifetime. - ListPos
- A position to an item of
SetList. - Managed
Const Ptr - A wrapper of
NonNullExtthat can be used to manage a constant pointer. - Managed
MutPtr - A wrapper of
NonNullExtthat can be used to manage a mutable pointer. - NonNull
Ext - A pointer that is extended with type id or name.
- OptVec
- A vector containing optional values.
- ParFlat
Iter - A parallel nested iterator.
- ParFlat
Iter Mut - A parallel nested mutable iterator.
- ParFlat
RawIter - A type-erased parallel nested iterator.
- ParIter
- An iterator that can be created from
ParRawIterwith concrete type and lifetime. - ParIter
Mut - A mutable iterator that can be created from
ParRawIterwith concrete type and lifetime. - ParRaw
Iter - A type-erased parallel iterator of a slice.
- RawGetter
- A raw getter for a container of items.
- RawIter
- A type-erased iterator of a slice.
- Ready
Future - A handle to a ready future data.
- Send
Sync Ptr - A pointer that implements
SendandSyncregardless of whetherTimplements bothSendandSync. - SetList
- A list containg unique key-value pairs.
- SetValue
List - A list containing unique values.
- Signal
- A data structure that can be used to wake other workers.
- Simple
Holder - A
Holderthat lends its inner value itself by cloning. - Simple
VecPool - Simple vector pool.
- Type
Helper - A helper struct used to determine whether a type implements traits like
Send,Sync, andCloneby cooperating with helper traits likeNotSend,NotSync, andNotClone. - Type
IdExt - Represents an extended
TypeIdwith type name. - Type
Info - Type information such as
TypeId, name, size, and alignment. - Typed
AnyVec - A
Vec-like type you can get fromAnyVec. - Unsafe
Future - A handle to a future data.
- Values
- An iterator yielding shared references to values of
SetList. - Values
Mut - An iterator yielding mutable references to values of
SetList. - Xorshift
- A random number generator based on 32bits state.
Enums§
- Borrow
Error - An error type associated with borrow.
Traits§
- AsDedup
Vec - A trait for
DedupVec. - AsFlat
RawIter - A trait to create type-erased flatten iterators from nested types such as
Vec<Vec<T>>. - AsRaw
Iter - A trait to create type-erased iterators.
- Describe
Group - A trait for creating
GroupDesc. - NotClone
- A helper trait for
TypeHelperto detect notClonetypes. - NotDebug
- A helper trait for
TypeHelperto detect notDebugtypes. - NotDefault
- A helper trait for
TypeHelperto detect notDefaulttypes. - NotEqual
Type - A helper trait for
TypeHelperto detect not equal types. - NotSend
- A helper trait for
TypeHelperto detect notSendtypes. - NotSync
- A helper trait for
TypeHelperto detect notSynctypes. - NotUnwind
Safe - A helper trait for
TypeHelperto detect notUnwindSafetypes. - Wake
Send - A trait to wake a worker and send
UnsafeFutureto the worker.
Functions§
- block_
on - Runs the given future to completion on the current worker.
Type Aliases§
- Borrow
Result - Result type for
BorrowedwithBorrowErrorfor error propagation. - FnClone
Raw - Type-erased raw
Clone::clonefunction pointer type. - FnDefault
Raw - Type-erased raw
Default::defaultfunction pointer type. - FnDrop
Raw - Type-erased raw
Drop::dropfunction pointer type. - FnFmt
Raw - Type-erased raw
Debug::fmtfunction pointer type.