[−][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 into_owned(self) -> BytesDecl<'static>
[src]
Converts the event into an owned event.
Trait Implementations
impl<'a> Clone for BytesDecl<'a>
[src]
impl<'a> Debug for BytesDecl<'a>
[src]
impl<'a> Deref for BytesDecl<'a>
[src]
Auto Trait Implementations
impl<'a> RefUnwindSafe for BytesDecl<'a>
impl<'a> Send for BytesDecl<'a>
impl<'a> Sync for BytesDecl<'a>
impl<'a> Unpin for BytesDecl<'a>
impl<'a> UnwindSafe for BytesDecl<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
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, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,