pub struct HtmlFlags {
pub single_quotes: bool,
pub double_quotes: bool,
pub ignore: bool,
pub substitute: bool,
pub disallowed: bool,
pub doctype: Doctype,
}Expand description
The $flags of the HTML functions, decoded from PHP’s bit mask.
Fields§
§single_quotes: boolENT_HTML_QUOTE_SINGLE (1): convert '.
double_quotes: boolENT_HTML_QUOTE_DOUBLE (2, ENT_COMPAT): convert ".
ignore: boolENT_IGNORE (4): drop invalid UTF-8 (wins over substitute).
substitute: boolENT_SUBSTITUTE (8): replace invalid UTF-8 with U+FFFD. Without it
(and without ignore) invalid UTF-8 makes the result empty.
disallowed: boolENT_DISALLOWED (128): replace code points the doctype disallows.
doctype: DoctypeThe document type (ENT_HTML401, ENT_XML1, ENT_XHTML or ENT_HTML5).
Implementations§
Trait Implementations§
impl Copy for HtmlFlags
Source§impl Default for HtmlFlags
impl Default for HtmlFlags
Source§fn default() -> Self
fn default() -> Self
PHP’s default flags, HtmlFlags::DEFAULT.
impl Eq for HtmlFlags
impl StructuralPartialEq for HtmlFlags
Auto Trait Implementations§
impl Forget for HtmlFlags
impl Freeze for HtmlFlags
impl Move for HtmlFlags
impl RefUnwindSafe for HtmlFlags
impl Send for HtmlFlags
impl Sync for HtmlFlags
impl Unpin for HtmlFlags
impl UnsafeUnpin for HtmlFlags
impl UnwindSafe for HtmlFlags
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.