Struct bones_asset::SchemaRegistry
pub struct SchemaRegistry {
pub schemas: AppendOnlyVec<Schema>,
/* private fields */
}
Expand description
A schema registry that alloates SchemaId
s for SchemaData
s and returns a registered
[&'static Schema
][Schema].
Fields§
§schemas: AppendOnlyVec<Schema>
The registered schemas.
Implementations§
§impl SchemaRegistry
impl SchemaRegistry
pub fn register(&self, schema_data: SchemaData) -> &Schema
pub fn register(&self, schema_data: SchemaData) -> &Schema
Register a schema with the registry.
Auto Trait Implementations§
impl !RefUnwindSafe for SchemaRegistry
impl Send for SchemaRegistry
impl Sync for SchemaRegistry
impl Unpin for SchemaRegistry
impl !UnwindSafe for SchemaRegistry
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