Enum earth::feed::Text
[−]
[src]
pub enum Text { Plain(String), Html(String), }
Text construct defined in :rfc:4287#section-3.1
(section 3.1).
RFC: https://tools.ietf.org/html/rfc4287#section-3.1
Note: It currently does not support xhtml
.
Variants
Plain(String)
The plain text content. It corresponds to :rfc:4287#section-3.1.1.1
(section 3.1.1.1).
Html(String)
The HTML content. It corresponds to :rfc:4287#section-3.1.1.2
(section 3.1.1.2).
Methods
impl Text
[src]
fn new<T>(type_: &str, value: T) -> Text where
T: Into<String>,
T: Into<String>,
fn plain<T>(value: T) -> Text where
T: Into<String>,
T: Into<String>,
fn html<T>(value: T) -> Text where
T: Into<String>,
T: Into<String>,
fn type_(&self) -> &'static str
The type of the text. It corresponds to :rfc:4287#section-3.1.1
(section 3.1.1).
Trait Implementations
impl PartialEq for Text
[src]
fn eq(&self, __arg_0: &Text) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Text) -> bool
This method tests for !=
.
impl Eq for Text
[src]
impl Debug for Text
[src]
impl Default for Text
[src]
impl Display for Text
[src]
impl Blob for Text
[src]
fn mimetype(&self) -> MimeType
fn is_text(&self) -> bool
fn as_bytes(&self) -> &[u8]
fn as_str(&self) -> Option<&str>
impl FromSchemaReader for Text
[src]
fn read_from<B: BufRead>(&mut self, element: XmlElement<B>) -> DecodeResult<()>
fn build_from<B: BufRead>(element: XmlElement<B>) -> DecodeResult<Self>
fn match_child<B: BufRead>(
&mut self,
_name: &XmlName,
_child: XmlElement<B>
) -> DecodeResult<()>
&mut self,
_name: &XmlName,
_child: XmlElement<B>
) -> DecodeResult<()>
impl Mergeable for Text
[src]
fn merge_with(&mut self, other: Self)
Merge data with the given value to renew itself as a latest state. Read more