pub struct XmlParser<R: BufRead> { /* private fields */ }Expand description
Wrapper around quick-xml Reader for parsing XSL-FO documents
Implementations§
Source§impl<R: BufRead> XmlParser<R>
impl<R: BufRead> XmlParser<R>
Sourcepub fn reader_mut(&mut self) -> &mut Reader<R>
pub fn reader_mut(&mut self) -> &mut Reader<R>
Get a mutable reference to the underlying reader
Sourcepub fn entity_resolver(&self) -> &EntityResolver
pub fn entity_resolver(&self) -> &EntityResolver
Get the entity resolver
Sourcepub fn entity_resolver_mut(&mut self) -> &mut EntityResolver
pub fn entity_resolver_mut(&mut self) -> &mut EntityResolver
Get a mutable reference to the entity resolver
Sourcepub fn processing_instructions(&self) -> &[ProcessingInstruction]
pub fn processing_instructions(&self) -> &[ProcessingInstruction]
Get processing instructions
Sourcepub fn read_event(&mut self) -> Result<Event<'static>>
pub fn read_event(&mut self) -> Result<Event<'static>>
Read the next event
Sourcepub fn update_namespaces(&mut self, start: &BytesStart<'_>)
pub fn update_namespaces(&mut self, start: &BytesStart<'_>)
Update namespace map from element attributes
Sourcepub fn extract_name(
&self,
start: &BytesStart<'_>,
) -> Result<(String, Namespace)>
pub fn extract_name( &self, start: &BytesStart<'_>, ) -> Result<(String, Namespace)>
Extract element name and namespace from a BytesStart event
Sourcepub fn extract_attributes(
&self,
start: &BytesStart<'_>,
) -> Result<Vec<(String, String)>>
pub fn extract_attributes( &self, start: &BytesStart<'_>, ) -> Result<Vec<(String, String)>>
Extract attributes from a BytesStart event
Sourcepub fn extract_text(&self, text: &[u8]) -> Result<String>
pub fn extract_text(&self, text: &[u8]) -> Result<String>
Extract text content from Text event (with entity resolution)
Sourcepub fn extract_cdata(&self, cdata: &[u8]) -> Result<String>
pub fn extract_cdata(&self, cdata: &[u8]) -> Result<String>
Extract CDATA content (no entity resolution)
Auto Trait Implementations§
impl<R> Freeze for XmlParser<R>where
R: Freeze,
impl<R> RefUnwindSafe for XmlParser<R>where
R: RefUnwindSafe,
impl<R> Send for XmlParser<R>where
R: Send,
impl<R> Sync for XmlParser<R>where
R: Sync,
impl<R> Unpin for XmlParser<R>where
R: Unpin,
impl<R> UnsafeUnpin for XmlParser<R>where
R: UnsafeUnpin,
impl<R> UnwindSafe for XmlParser<R>where
R: 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