Skip to main content

Definition

Trait Definition 

Source
pub trait Definition: Object {
Show 31 methods // Required methods fn invoke(&self, once_only: bool) -> Result<Tokens>; fn invoke_primitive(&self) -> Result<Vec<Digested>>; fn get_cs(&self) -> Cow<'_, Token>; fn get_cs_name(&self) -> Cow<'_, str>; fn get_alias(&self) -> Option<&String>; fn get_parameters(&self) -> Option<&Parameters>; fn do_absorption( &self, _document: &mut Document, _whatsit: &Whatsit, ) -> Result<Vec<Node>>; // Provided methods fn get_cs_or_alias(&self) -> Cow<'_, Token> { ... } fn get_sizer(&self) -> Option<SizingClosure> { ... } fn is_protected(&self) -> bool { ... } fn is_register(&self) -> bool { ... } fn is_prefix(&self) -> bool { ... } fn is_readonly(&self) -> bool { ... } fn get_test(&self) -> Option<&ConditionalClosure> { ... } fn get_conditional_type(&self) -> Option<ConditionalType> { ... } fn read_arguments(&self) -> Result<Vec<ArgWrap>> where Self: Sized { ... } fn invocation( &mut self, args: Vec<Option<Tokens>>, _gullet: &mut Gullet, ) -> Result<Tokens> { ... } fn get_num_args(&self) -> usize { ... } fn before_digest(&self) -> Option<&Vec<BeforeDigestClosure>> { ... } fn after_digest(&self) -> Option<&Vec<DigestionClosure>> { ... } fn after_digest_body(&self) -> Option<&Vec<DigestionClosure>> { ... } fn capture_body(&self) -> bool { ... } fn execute_before_digest(&self) -> Result<Vec<Digested>> { ... } fn execute_after_digest( &self, whatsit: &mut Whatsit, ) -> Result<Vec<Digested>> { ... } fn execute_after_digest_body( &self, whatsit: &mut Whatsit, ) -> Result<Vec<Digested>> { ... } fn value_of(&self, _args: Vec<ArgWrap>) -> Option<RegisterValue> { ... } fn set_value( &self, _value: RegisterValue, _scope: Option<Scope>, _args: Vec<ArgWrap>, ) { ... } fn register_type(&self) -> Option<RegisterType> { ... } fn get_reversion_spec(&self) -> Option<Reversion> { ... } fn get_expansion(&self) -> Option<&ExpansionBody> { ... } fn stringify_type(&self, deftype: &str) -> String { ... }
}

Required Methods§

Source

fn invoke(&self, once_only: bool) -> Result<Tokens>

Source

fn invoke_primitive(&self) -> Result<Vec<Digested>>

Source

fn get_cs(&self) -> Cow<'_, Token>

We can almost always return the CS by reference, except in a Register’s RefCell, where we are forced to clone

Source

fn get_cs_name(&self) -> Cow<'_, str>

Source

fn get_alias(&self) -> Option<&String>

Source

fn get_parameters(&self) -> Option<&Parameters>

Source

fn do_absorption( &self, _document: &mut Document, _whatsit: &Whatsit, ) -> Result<Vec<Node>>

Provided Methods§

Trait Implementations§

Source§

impl Display for dyn Definition

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for dyn Definition

Source§

fn eq(&self, other: &dyn Definition) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§