[][src]Struct rss::Source

pub struct Source { /* fields omitted */ }

Represents the source of an RSS item.

Methods

impl Source[src]

pub fn url(&self) -> &str[src]

Return the URL of this source.

Examples

use rss::Source;

let mut source = Source::default();
source.set_url("http://example.com");
assert_eq!(source.url(), "http://example.com");

pub fn set_url<V>(&mut self, url: V) where
    V: Into<String>, 
[src]

Set the URL of this source.

Examples

use rss::Source;

let mut source = Source::default();
source.set_url("http://example.com");

pub fn title(&self) -> Option<&str>[src]

Return the title of this source.

Examples

use rss::Source;

let mut source = Source::default();
source.set_title("Source Title".to_string());
assert_eq!(source.title(), Some("Source Title"));

pub fn set_title<V>(&mut self, title: V) where
    V: Into<Option<String>>, 
[src]

Set the title of this source.

Examples

use rss::Source;

let mut source = Source::default();
source.set_title("Source Title".to_string());

impl Source[src]

pub fn from_xml<R: BufRead>(
    reader: &mut Reader<R>,
    atts: Attributes
) -> Result<Self, Error>
[src]

Builds a Source from source XML

Trait Implementations

impl PartialEq<Source> for Source[src]

impl Clone for Source[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Default for Source[src]

impl Debug for Source[src]

Auto Trait Implementations

impl Send for Source

impl Sync for Source

Blanket Implementations

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]