pub enum InterpolationArg {
Literal(String),
Nested(Box<Interpolation>),
}Expand description
An argument to an interpolation (may itself contain interpolations)
Variants§
Implementations§
Source§impl InterpolationArg
impl InterpolationArg
Sourcepub fn is_literal(&self) -> bool
pub fn is_literal(&self) -> bool
Check if this argument is a simple literal
Sourcepub fn as_literal(&self) -> Option<&str>
pub fn as_literal(&self) -> Option<&str>
Get the literal value if this is a literal
Trait Implementations§
Source§impl Clone for InterpolationArg
impl Clone for InterpolationArg
Source§fn clone(&self) -> InterpolationArg
fn clone(&self) -> InterpolationArg
Returns a duplicate of the value. Read more
1.0.0 · 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 InterpolationArg
impl Debug for InterpolationArg
Source§impl PartialEq for InterpolationArg
impl PartialEq for InterpolationArg
impl StructuralPartialEq for InterpolationArg
Auto Trait Implementations§
impl Freeze for InterpolationArg
impl RefUnwindSafe for InterpolationArg
impl Send for InterpolationArg
impl Sync for InterpolationArg
impl Unpin for InterpolationArg
impl UnwindSafe for InterpolationArg
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