Enum write_html::Compactability 
source · pub enum Compactability {
    No,
    Yes {
        final_slash: bool,
    },
}Expand description
Represents the compactability of a tag.
Variants§
No
The tag is not compactable.
This means that the tag will always be written as <tag></tag>.
Yes
The tag is compactable.
This means that the tag will be written as <tag/> if it has no contents.
The final_slash parameter determines whether the tag will be written as <tag> or <tag/>.
Implementations§
source§impl Compactability
 
impl Compactability
sourcepub fn is_compactable(&self) -> bool
 
pub fn is_compactable(&self) -> bool
Returns wether the tag is compactable.
Trait Implementations§
source§impl Clone for Compactability
 
impl Clone for Compactability
source§fn clone(&self) -> Compactability
 
fn clone(&self) -> Compactability
Returns a copy 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 Compactability
 
impl Debug for Compactability
source§impl From<Compactability> for bool
 
impl From<Compactability> for bool
source§fn from(c: Compactability) -> Self
 
fn from(c: Compactability) -> Self
Converts to this type from the input type.
source§impl From<bool> for Compactability
 
impl From<bool> for Compactability
source§impl Hash for Compactability
 
impl Hash for Compactability
source§impl Ord for Compactability
 
impl Ord for Compactability
source§fn cmp(&self, other: &Compactability) -> Ordering
 
fn cmp(&self, other: &Compactability) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
    Self: Sized,
 
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<Compactability> for Compactability
 
impl PartialEq<Compactability> for Compactability
source§fn eq(&self, other: &Compactability) -> bool
 
fn eq(&self, other: &Compactability) -> bool
This method tests for 
self and other values to be equal, and is used
by ==.source§impl PartialOrd<Compactability> for Compactability
 
impl PartialOrd<Compactability> for Compactability
source§fn partial_cmp(&self, other: &Compactability) -> Option<Ordering>
 
fn partial_cmp(&self, other: &Compactability) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
 
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for 
self and other) and is used by the <=
operator. Read moreimpl Copy for Compactability
impl Eq for Compactability
impl StructuralEq for Compactability
impl StructuralPartialEq for Compactability
Auto Trait Implementations§
impl RefUnwindSafe for Compactability
impl Send for Compactability
impl Sync for Compactability
impl Unpin for Compactability
impl UnwindSafe for Compactability
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