[−][src]Struct quick_xml::events::BytesDecl
An XML declaration (Event::Decl
).
Methods
impl<'a> BytesDecl<'a>
[src]
pub fn from_start(start: BytesStart<'a>) -> BytesDecl<'a>
[src]
Creates a BytesDecl
from a BytesStart
pub fn version(&self) -> Result<Cow<[u8]>>
[src]
Gets xml version, including quotes (' or ")
pub fn encoding(&self) -> Option<Result<Cow<[u8]>>>
[src]
Gets xml encoding, including quotes (' or ")
pub fn standalone(&self) -> Option<Result<Cow<[u8]>>>
[src]
Gets xml standalone, including quotes (' or ")
pub fn new(
version: &[u8],
encoding: Option<&[u8]>,
standalone: Option<&[u8]>
) -> BytesDecl<'static>
[src]
version: &[u8],
encoding: Option<&[u8]>,
standalone: Option<&[u8]>
) -> BytesDecl<'static>
Constructs a new XmlDecl
from the (mandatory) version (should be 1.0
or 1.1
),
the optional encoding (e.g., UTF-8
) and the optional standalone (yes
or no
)
attribute.
Does not escape any of its inputs. Always uses double quotes to wrap the attribute values. The caller is responsible for escaping attribute values. Shouldn't usually be relevant since the double quote character is not allowed in any of the attribute values.
pub fn encoder(&self) -> Option<&'static Encoding>
[src]
Gets the decoder struct
pub fn into_owned(self) -> BytesDecl<'static>
[src]
Converts the event into an owned event.
Trait Implementations
impl<'a> Clone for BytesDecl<'a>
[src]
fn clone(&self) -> BytesDecl<'a>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<'a> Debug for BytesDecl<'a>
[src]
impl<'a> Deref for BytesDecl<'a>
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,