pub struct Validator { /* private fields */ }Expand description
The agent’s view of a renderer: the catalogs it supports and the surfaces sent to it so far.
Implementations§
Source§impl Validator
impl Validator
Sourcepub fn new(
catalogs: impl IntoIterator<Item = Catalog>,
) -> Result<Self, CompileError>
pub fn new( catalogs: impl IntoIterator<Item = Catalog>, ) -> Result<Self, CompileError>
A validator for a renderer that supports catalogs. The first is used
to check messages that name no catalog (a function response).
Sourcepub fn set_rules(&mut self, rules: Rules)
pub fn set_rules(&mut self, rules: Rules)
The completeness rules batches are checked under from now on.
Sourcepub fn supported_catalog_ids(&self) -> Vec<&str>
pub fn supported_catalog_ids(&self) -> Vec<&str>
The ids of the catalogs this renderer supports, in the order given.
Sourcepub fn surface_ids(&self) -> impl Iterator<Item = &str>
pub fn surface_ids(&self) -> impl Iterator<Item = &str>
The surfaces created and not deleted, as of the last applied batch.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Validator
impl !UnwindSafe for Validator
impl Forget for Validator
impl Freeze for Validatorwhere
*const u8 is !null: Freeze,
PhantomData<Entry>: Freeze,
*const LeafNode<String, Surface> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(String, Surface)>>: Freeze,
impl Move for Validator
impl Send for Validatorwhere
RawVecInner: Send,
RawTable<usize>: Send,
NodeRef<Owned, String, ComponentDef, LeafOrInternal>: Send,
BoxRaw<(String, ComponentDef)>: Send,
NodeRef<Owned, String, FunctionDef, LeafOrInternal>: Send,
BoxRaw<(String, FunctionDef)>: Send,
Arc<SchemaNodeInner<SerdeJson>>: Send,
Arc<str>: Send,
&'static str: Send,
NodeRef<Owned, String, Surface, LeafOrInternal>: Send,
BoxRaw<(String, Surface)>: Send,
impl Sync for Validatorwhere
RawVecInner: Sync,
RawTable<usize>: Sync,
NodeRef<Owned, String, ComponentDef, LeafOrInternal>: Sync,
BoxRaw<(String, ComponentDef)>: Sync,
NodeRef<Owned, String, FunctionDef, LeafOrInternal>: Sync,
BoxRaw<(String, FunctionDef)>: Sync,
Arc<SchemaNodeInner<SerdeJson>>: Sync,
Arc<str>: Sync,
NodeRef<Owned, String, Surface, LeafOrInternal>: Sync,
BoxRaw<(String, Surface)>: Sync,
impl Unpin for Validatorwhere
*const u8 is !null: Unpin,
*const LeafNode<String, ComponentDef> is !null: Unpin,
Box<(String, ComponentDef)>: Unpin,
*const LeafNode<String, FunctionDef> is !null: Unpin,
Box<(String, FunctionDef)>: Unpin,
Arc<SchemaNodeInner<SerdeJson>>: Unpin,
Arc<str>: Unpin,
&'static str: Unpin,
*const LeafNode<String, Surface> is !null: Unpin,
Box<(String, Surface)>: Unpin,
impl UnsafeUnpin for Validatorwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<Entry>: UnsafeUnpin,
*const LeafNode<String, Surface> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, Surface)>>: UnsafeUnpin,
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