pub struct SchemaRegistry { /* private fields */ }Implementations§
Source§impl SchemaRegistry
impl SchemaRegistry
pub fn new() -> Self
pub fn register(&self, schema: ComponentSchema) -> Result<()>
pub fn get(&self, component_id: &str) -> Result<ComponentSchema>
pub fn get_version( &self, component_id: &str, version: SchemaVersion, ) -> Result<ComponentSchema>
pub fn has(&self, component_id: &str) -> bool
pub fn get_all(&self) -> Result<Vec<ComponentSchema>>
pub fn get_version_history( &self, component_id: &str, ) -> Result<Vec<SchemaVersion>>
pub fn validate_compatibility( &self, old_version: SchemaVersion, new_version: SchemaVersion, ) -> bool
pub fn clear(&self) -> Result<()>
pub fn get_current_version(&self) -> SchemaVersion
pub fn set_current_version(&mut self, version: SchemaVersion)
Trait Implementations§
Source§impl Clone for SchemaRegistry
impl Clone for SchemaRegistry
Auto Trait Implementations§
impl Freeze for SchemaRegistry
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