pub struct Builder { /* private fields */ }Expand description
Fluent builder for constructing token model schemas.
Implementations§
Source§impl Builder
impl Builder
Sourcepub fn constraint(self, id: &str, expr: &str) -> Self
pub fn constraint(self, id: &str, expr: &str) -> Self
Adds a constraint.
Sourcepub fn ast(&self) -> &SchemaNode
pub fn ast(&self) -> &SchemaNode
Returns the underlying AST node.
Sourcepub fn must_schema(self) -> Schema
pub fn must_schema(self) -> Schema
Builds and returns the tokenmodel Schema. Panics on error.
Auto Trait Implementations§
impl Freeze for Builder
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnsafeUnpin for Builder
impl UnwindSafe for Builder
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