Struct html5ever::serialize::HtmlSerializer
source · pub struct HtmlSerializer<Wr: Write> {
pub writer: Wr,
/* private fields */
}
Fields§
§writer: Wr
Implementations§
source§impl<Wr: Write> HtmlSerializer<Wr>
impl<Wr: Write> HtmlSerializer<Wr>
pub fn new(writer: Wr, opts: SerializeOpts) -> Self
Trait Implementations§
source§impl<Wr: Write> Serializer for HtmlSerializer<Wr>
impl<Wr: Write> Serializer for HtmlSerializer<Wr>
source§fn start_elem<'a, AttrIter>(
&mut self,
name: QualName,
attrs: AttrIter,
) -> Result<()>
fn start_elem<'a, AttrIter>( &mut self, name: QualName, attrs: AttrIter, ) -> Result<()>
Serialize the start of an element, for example
<div class="test">
.source§fn end_elem(&mut self, name: QualName) -> Result<()>
fn end_elem(&mut self, name: QualName) -> Result<()>
Serialize the end of an element, for example
</div>
.source§fn write_comment(&mut self, text: &str) -> Result<()>
fn write_comment(&mut self, text: &str) -> Result<()>
Serialize a comment node, for example
<!-- comment -->
.Auto Trait Implementations§
impl<Wr> Freeze for HtmlSerializer<Wr>where
Wr: Freeze,
impl<Wr> RefUnwindSafe for HtmlSerializer<Wr>where
Wr: RefUnwindSafe,
impl<Wr> Send for HtmlSerializer<Wr>where
Wr: Send,
impl<Wr> Sync for HtmlSerializer<Wr>where
Wr: Sync,
impl<Wr> Unpin for HtmlSerializer<Wr>where
Wr: Unpin,
impl<Wr> UnwindSafe for HtmlSerializer<Wr>where
Wr: UnwindSafe,
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