pub struct Tag {
pub name: String,
pub parameters: Option<String>,
}Expand description
A parsed markup tag.
Fields§
§name: String§parameters: Option<String>Implementations§
Source§impl Tag
impl Tag
pub fn new(name: impl Into<String>) -> Self
pub fn with_params(name: impl Into<String>, params: impl Into<String>) -> Self
Sourcepub fn is_closing(&self) -> bool
pub fn is_closing(&self) -> bool
Check if this is a closing tag (/name or /).
Sourcepub fn closing_name(&self) -> &str
pub fn closing_name(&self) -> &str
Get the name without the leading / for closing tags.
Trait Implementations§
impl StructuralPartialEq for Tag
Auto Trait Implementations§
impl Freeze for Tag
impl RefUnwindSafe for Tag
impl Send for Tag
impl Sync for Tag
impl Unpin for Tag
impl UnsafeUnpin for Tag
impl UnwindSafe for Tag
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