pub struct FeedMeta {Show 49 fields
pub title: Option<String>,
pub title_detail: Option<TextConstruct>,
pub link: Option<String>,
pub links: Vec<Link>,
pub subtitle: Option<String>,
pub subtitle_detail: Option<TextConstruct>,
pub summary: Option<String>,
pub summary_detail: Option<TextConstruct>,
pub updated: Option<DateTime<Utc>>,
pub updated_str: Option<String>,
pub published: Option<DateTime<Utc>>,
pub published_str: Option<String>,
pub author: Option<SmallString>,
pub author_detail: Option<Person>,
pub authors: Vec<Person>,
pub contributors: Vec<Person>,
pub publisher: Option<SmallString>,
pub publisher_detail: Option<Person>,
pub language: Option<SmallString>,
pub rights: Option<String>,
pub rights_detail: Option<TextConstruct>,
pub generator: Option<String>,
pub generator_detail: Option<Generator>,
pub image: Option<Image>,
pub icon: Option<String>,
pub logo: Option<String>,
pub tags: Vec<Tag>,
pub id: Option<String>,
pub ttl: Option<String>,
pub docs: Option<String>,
pub itunes: Option<Box<ItunesFeedMeta>>,
pub podcast: Option<Box<PodcastMeta>>,
pub dc_creator: Option<SmallString>,
pub dc_publisher: Option<SmallString>,
pub dc_rights: Option<String>,
pub license: Option<String>,
pub syndication: Option<Box<SyndicationMeta>>,
pub where: Option<Box<GeoLocation>>,
pub geo_lat: Option<String>,
pub geo_long: Option<String>,
pub next_url: Option<String>,
pub media_thumbnail: Vec<MediaThumbnail>,
pub media_content: Vec<MediaContent>,
pub media_rating: Option<MediaRating>,
pub media_keywords: Option<String>,
pub cloud: Option<Cloud>,
pub textinput: Option<TextInput>,
pub skiphours: Vec<u32>,
pub skipdays: Vec<String>,
}Expand description
Feed metadata
Fields§
§title: Option<String>Feed title
title_detail: Option<TextConstruct>Detailed title with metadata
link: Option<String>Primary feed link
links: Vec<Link>All links associated with this feed
subtitle: Option<String>Feed subtitle/description
subtitle_detail: Option<TextConstruct>Detailed subtitle with metadata
summary: Option<String>Feed summary (populated from itunes:summary when present)
summary_detail: Option<TextConstruct>Detailed summary with metadata
updated: Option<DateTime<Utc>>Last update date
updated_str: Option<String>Original update date string as found in the feed (timezone preserved)
published: Option<DateTime<Utc>>Initial publication date (RSS pubDate, Atom published)
published_str: Option<String>Original publication date string as found in the feed (timezone preserved)
Primary author name (stored inline for names ≤24 bytes)
Detailed author information
All authors
contributors: Vec<Person>Contributors
publisher: Option<SmallString>Publisher name (stored inline for names ≤24 bytes)
publisher_detail: Option<Person>Detailed publisher information
language: Option<SmallString>Feed language (e.g., “en-us”) - stored inline as lang codes are ≤24 bytes
rights: Option<String>Copyright/rights statement
rights_detail: Option<TextConstruct>Detailed rights with metadata
generator: Option<String>Generator name
generator_detail: Option<Generator>Detailed generator information
image: Option<Image>Feed image
icon: Option<String>Icon URL (small image)
logo: Option<String>Logo URL (larger image)
Feed-level tags/categories
id: Option<String>Unique feed identifier
ttl: Option<String>Time-to-live (update frequency hint) in minutes (kept as string for API compatibility)
docs: Option<String>URL of documentation for the RSS format used
itunes: Option<Box<ItunesFeedMeta>>iTunes podcast metadata (if present)
podcast: Option<Box<PodcastMeta>>Podcast 2.0 namespace metadata (if present)
dc_creator: Option<SmallString>Dublin Core creator (author fallback) - stored inline for names ≤24 bytes
dc_publisher: Option<SmallString>Dublin Core publisher (stored inline for names ≤24 bytes)
dc_rights: Option<String>Dublin Core rights (copyright)
license: Option<String>License URL (Creative Commons, etc.)
Syndication module metadata (RSS 1.0)
where: Option<Box<GeoLocation>>Geographic location from GeoRSS namespace (feed level, exposed as where per Python feedparser API)
geo_lat: Option<String>W3C Basic Geo latitude (geo:lat)
geo_long: Option<String>W3C Basic Geo longitude (geo:long)
next_url: Option<String>Pagination URL for the next page of results (JSON Feed next_url, RFC 5005 <link rel="next">)
media_thumbnail: Vec<MediaThumbnail>Media RSS thumbnails at feed/channel level
media_content: Vec<MediaContent>Media RSS content items at feed/channel level
media_rating: Option<MediaRating>Media RSS rating (media:rating) at feed level
media_keywords: Option<String>Media RSS keywords (media:keywords) at feed level, comma-separated string
cloud: Option<Cloud>RSS 2.0 <cloud> element — subscription endpoint for notifications
textinput: Option<TextInput>RSS 2.0 <textInput> element — text input form associated with the channel
skiphours: Vec<u32>RSS 2.0 <skipHours> — hours of the day when the channel may be skipped (0–23)
skipdays: Vec<String>RSS 2.0 <skipDays> — days of the week when the channel may be skipped
Implementations§
Source§impl FeedMeta
impl FeedMeta
Sourcepub fn with_rss_capacity() -> Self
pub fn with_rss_capacity() -> Self
Creates FeedMeta with capacity hints for typical RSS 2.0 feeds
Pre-allocates collections based on common RSS 2.0 field usage:
- 1-2 links (channel link, self link)
- 1 author (managingEditor)
- 0-3 tags (categories)
§Examples
use feedparser_rs::FeedMeta;
let meta = FeedMeta::with_rss_capacity();Sourcepub fn with_atom_capacity() -> Self
pub fn with_atom_capacity() -> Self
Creates FeedMeta with capacity hints for typical Atom 1.0 feeds
Pre-allocates collections based on common Atom 1.0 field usage:
- 3-5 links (alternate, self, related, etc.)
- 1-2 authors
- 1 contributor
- 3-5 tags (categories)
§Examples
use feedparser_rs::FeedMeta;
let meta = FeedMeta::with_atom_capacity();Sourcepub fn set_title(&mut self, text: TextConstruct)
pub fn set_title(&mut self, text: TextConstruct)
Sets title field with TextConstruct, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, TextConstruct};
let mut meta = FeedMeta::default();
meta.set_title(TextConstruct::text("Example Feed"));
assert_eq!(meta.title.as_deref(), Some("Example Feed"));Sourcepub fn set_subtitle(&mut self, text: TextConstruct)
pub fn set_subtitle(&mut self, text: TextConstruct)
Sets subtitle field with TextConstruct, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, TextConstruct};
let mut meta = FeedMeta::default();
meta.set_subtitle(TextConstruct::text("A great feed"));
assert_eq!(meta.subtitle.as_deref(), Some("A great feed"));Sourcepub fn set_summary(&mut self, text: TextConstruct)
pub fn set_summary(&mut self, text: TextConstruct)
Sets summary field with TextConstruct, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, TextConstruct};
let mut meta = FeedMeta::default();
meta.set_summary(TextConstruct::text("A detailed description"));
assert_eq!(meta.summary.as_deref(), Some("A detailed description"));Sourcepub fn set_rights(&mut self, text: TextConstruct)
pub fn set_rights(&mut self, text: TextConstruct)
Sets rights field with TextConstruct, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, TextConstruct};
let mut meta = FeedMeta::default();
meta.set_rights(TextConstruct::text("© 2025 Example"));
assert_eq!(meta.rights.as_deref(), Some("© 2025 Example"));Sourcepub fn set_generator(&mut self, generator: Generator)
pub fn set_generator(&mut self, generator: Generator)
Sets generator field with Generator, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, Generator};
let mut meta = FeedMeta::default();
let generator = Generator {
name: "Example Generator".to_string(),
href: None,
version: None,
};
meta.set_generator(generator);
assert_eq!(meta.generator.as_deref(), Some("Example Generator"));Sets author field with Person, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, Person};
let mut meta = FeedMeta::default();
meta.set_author(Person::from_name("John Doe"));
assert_eq!(meta.author.as_deref(), Some("John Doe"));Sourcepub fn set_publisher(&mut self, person: Person)
pub fn set_publisher(&mut self, person: Person)
Sets publisher field with Person, storing both simple and detailed versions
§Examples
use feedparser_rs::{FeedMeta, Person};
let mut meta = FeedMeta::default();
meta.set_publisher(Person::from_name("ACME Corp"));
assert_eq!(meta.publisher.as_deref(), Some("ACME Corp"));Sourcepub fn set_alternate_link(&mut self, href: String, max_links: usize)
pub fn set_alternate_link(&mut self, href: String, max_links: usize)
Sets the primary link and adds it to the links collection
This is a convenience method that:
- Sets the
linkfield (if not already set) - Adds an “alternate” link to the
linkscollection
§Examples
use feedparser_rs::FeedMeta;
let mut meta = FeedMeta::default();
meta.set_alternate_link("https://example.com".to_string(), 10);
assert_eq!(meta.link.as_deref(), Some("https://example.com"));
assert_eq!(meta.links.len(), 1);
assert_eq!(meta.links[0].rel.as_deref(), Some("alternate"));