pub struct Expandable {
pub is_protected: bool,
pub is_long: bool,
pub is_outer: bool,
pub has_cc_arg: bool,
pub alias: Option<String>,
pub locator: Locator,
pub cs: Token,
pub paramlist: Option<Parameters>,
pub expansion: Option<ExpansionBody>,
}Fields§
§is_protected: bool§is_long: bool§is_outer: bool§has_cc_arg: bool§alias: Option<String>§locator: Locator§cs: Token§paramlist: Option<Parameters>§expansion: Option<ExpansionBody>Implementations§
Source§impl Expandable
impl Expandable
pub fn new( cs: Token, paramlist: Option<Parameters>, expansion_opt: Option<ExpansionBody>, traits: Option<ExpandableOptions>, ) -> Result<Self>
Trait Implementations§
Source§impl Clone for Expandable
impl Clone for Expandable
Source§fn clone(&self) -> Expandable
fn clone(&self) -> Expandable
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Expandable
impl Debug for Expandable
Source§impl Default for Expandable
impl Default for Expandable
Source§impl Definition for Expandable
impl Definition for Expandable
Source§fn invoke(&self, once_only: bool) -> Result<Tokens>
fn invoke(&self, once_only: bool) -> Result<Tokens>
Expand the expandable control sequence. This should be carried out by the Gullet.
fn is_protected(&self) -> bool
fn get_parameters(&self) -> Option<&Parameters>
fn get_num_args(&self) -> usize
Source§fn get_cs(&self) -> Cow<'_, Token>
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
fn get_cs_name(&self) -> Cow<'_, str>
fn get_expansion(&self) -> Option<&ExpansionBody>
fn get_alias(&self) -> Option<&String>
fn invoke_primitive(&self) -> Result<Vec<Digested>>
fn before_digest(&self) -> Option<&Vec<BeforeDigestClosure>>
fn after_digest(&self) -> Option<&Vec<DigestionClosure>>
fn do_absorption( &self, _document: &mut Document, _whatsit: &Whatsit, ) -> Result<Vec<Node>>
fn get_cs_or_alias(&self) -> Cow<'_, Token>
fn get_sizer(&self) -> Option<SizingClosure>
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 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>
Source§fn set_value(
&self,
_value: RegisterValue,
_scope: Option<Scope>,
_args: Vec<ArgWrap>,
)
fn set_value( &self, _value: RegisterValue, _scope: Option<Scope>, _args: Vec<ArgWrap>, )
runs the setter to assign the value for a register
fn register_type(&self) -> Option<RegisterType>
fn get_reversion_spec(&self) -> Option<Reversion>
fn stringify_type(&self, deftype: &str) -> String
Source§impl From<Expandable> for Stored
Storing all definitions is expected - Expandable case
impl From<Expandable> for Stored
Storing all definitions is expected - Expandable case
Source§fn from(definition: Expandable) -> Self
fn from(definition: Expandable) -> Self
Converts to this type from the input type.
Source§impl Object for Expandable
impl Object for Expandable
fn is_definition(&self) -> bool
fn is_expandable(&self) -> bool
Source§fn get_locator(&self) -> Option<Locator>
fn get_locator(&self) -> Option<Locator>
The object’s stored source locator, if it has one.
None is the honest
“no recorded source position” (replacing the old Locator::default()
file!()/line!() sentinel). For “where the parser is now” (error
reporting, box creation), use the free fn gullet::get_locator().fn stringify(&self) -> String
fn isa_box(&self) -> bool
fn is_comment(&self) -> bool
fn be_digested(self) -> Result<Digested>
Auto Trait Implementations§
impl !RefUnwindSafe for Expandable
impl !Send for Expandable
impl !Sync for Expandable
impl !UnwindSafe for Expandable
impl Freeze for Expandable
impl Unpin for Expandable
impl UnsafeUnpin for Expandable
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