Class RssChannel

java.lang.Object
io.micronaut.rss.RssChannel
Direct Known Subclasses:
ItunesPodcast

public class RssChannel extends Object
Since:
1.0
Author:
Sergio del Amo
See Also:
  • Constructor Details

    • RssChannel

      public RssChannel()
  • Method Details

    • getTitle

      public String getTitle()
      The name of the channel.

      It's how people refer to your service. If you have an HTML website that contains the same information as your RSS file, the title of your channel should be the same as the title of your website.

      Returns:
      The name of the channel.
    • getLink

      public String getLink()
      Returns:
      The URL to the HTML website corresponding to the channel.
    • getDescription

      public String getDescription()
      Phrase or sentence describing the channel.
      Returns:
      Phrase or sentence describing the channel.
    • getLanguage

      public Optional<RssLanguage> getLanguage()
      The language the channel is written in. This allows aggregators to group all Italian language sites, for example, on a single page. A list of allowable values for this element, as provided by Netscape, is here. You may also use values defined by the W3C
      Returns:
      The language the channel is written in.
    • getCopyright

      public Optional<String> getCopyright()
      Copyright notice for content in the channel.
      Returns:
      Copyright notice for content in the channel.
    • getManagingEditor

      public Optional<String> getManagingEditor()
      Returns:
      Email address for person responsible for editorial content.
    • getWebMaster

      public Optional<String> getWebMaster()
      Returns:
      Email address for person responsible for technical issues relating to channel.
    • getPubDate

      public Optional<ZonedDateTime> getPubDate()
      The publication date for the content in the channel. For example, the New York Times publishes on a daily basis, the publication date flips once every 24 hours. That's when the pubDate of the channel changes. All date-times in RSS conform to the Date and Time Specification of RFC 822, with the exception that the year may be expressed with two characters or four characters (four preferred).
      Returns:
      The publication date for the content in the channel.
    • getLastBuildDate

      public Optional<ZonedDateTime> getLastBuildDate()
      The last time the content of the channel changed.
      Returns:
      The last time the content of the channel changed.
    • getCategory

      public Optional<List<List<String>>> getCategory()
      Specify one or more categories that the channel belongs to. Follows the same rules as the <item>-level category element. More info.
      Returns:
      Specify one or more categories that the channel belongs to.
    • getGenerator

      public Optional<String> getGenerator()
      A string indicating the program used to generate the channel.
      Returns:
      A string indicating the program used to generate the channel.
    • getDocs

      public Optional<String> getDocs()
      A URL that points to the documentation for the format used in the RSS file. It's probably a pointer to this page. It's for people who might stumble across an RSS file on a Web server 25 years from now and wonder what it is.
      Returns:
      A URL that points to the documentation for the format used in the RSS file
    • getCloud

      public Optional<String> getCloud()
      Allows processes to register with a cloud to be notified of updates to the channel, implementing a lightweight publish-subscribe protocol for RSS feeds. More info here.
      Returns:
      Allows processes to register with a cloud to be notified of updates to the channel, implementing a lightweight publish-subscribe protocol for RSS feeds.
    • getTtl

      public Optional<Integer> getTtl()
      ttl stands for time to live. It's a number of minutes that indicates how long a channel can be cached before refreshing from the source. More info here.
      Returns:
      It's a number of minutes that indicates how long a channel can be cached before refreshing from the source.
    • getImage

      public Optional<RssChannelImage> getImage()
      Specifies a GIF, JPEG or PNG image that can be displayed with the channel. More info here.
      Returns:
      Specifies a GIF, JPEG or PNG image that can be displayed with the channel.
    • getRating

      public Optional<String> getRating()
      The PICS rating for the channel.
      Returns:
      The PICS rating for the channel.
    • getTextInput

      public Optional<RssTextInput> getTextInput()
      Specifies a text input box that can be displayed with the channel.
      Returns:
      An optional RssTextInput
    • getSkipHours

      public Optional<List<RssSkipHours>> getSkipHours()
      A hint for aggregators telling them which hours they can skip.
      Returns:
      A hint for aggregators telling them which hours they can skip.
    • getSkipDays

      public Optional<List<RssSkipDays>> getSkipDays()
      A hint for aggregators telling them which days they can skip.
      Returns:
      A hint for aggregators telling them which days they can skip.
    • getItem

      public Optional<List<RssItem>> getItem()
      An item may represent a "story" -- much like a story in a newspaper or magazine; if so its description is a synopsis of the story, and the link points to the full story.
      Returns:
      An optional List of RssItem
    • addItem

      public void addItem(RssItem item)
      Parameters:
      item - a RSS Item
    • setSkipDays

      public void setSkipDays(List<RssSkipDays> skipDays)
      Parameters:
      skipDays - a List of RssSkipDays
    • setSkipHours

      public void setSkipHours(List<RssSkipHours> skipHours)
      Parameters:
      skipHours - a List of RssSkipHours.
    • setTextInput

      public void setTextInput(RssTextInput textInput)
      Parameters:
      textInput - A RssTextInput.
    • setRating

      public void setRating(String rating)
      Parameters:
      rating - A PICS Rating.
    • setImage

      public void setImage(RssChannelImage image)
      Parameters:
      image - GIF, JPEG or PNG image that can be displayed with the channel.
    • setTtl

      public void setTtl(Integer ttl)
      Parameters:
      ttl - time to live expressed in minutes.
    • setCloud

      public void setCloud(String cloud)
      Parameters:
      cloud - A cloud.
    • setDocs

      public void setDocs(String docs)
      Parameters:
      docs - A URL that points to the documentation for the format used in the RSS file.
    • setGenerator

      public void setGenerator(String generator)
      Parameters:
      generator - A string indicating the program used to generate the channel.
    • setCategory

      public void setCategory(List<List<String>> category)
      Parameters:
      category - A list of categories to associate the RSS Channel with.
    • setLastBuildDate

      public void setLastBuildDate(ZonedDateTime lastBuildDate)
      Parameters:
      lastBuildDate - The last time the content of the channel changed.
    • setPubDate

      public void setPubDate(ZonedDateTime pubDate)
      Parameters:
      pubDate - The publication date for the content in the channel.
    • setWebMaster

      public void setWebMaster(String webMaster)
      Parameters:
      webMaster - Email address for person responsible for technical issues relating to channel.
    • setManagingEditor

      public void setManagingEditor(String managingEditor)
      Parameters:
      managingEditor - Email address for person responsible for editorial content.
    • setCopyright

      public void setCopyright(String copyright)
      Parameters:
      copyright - Copyright notice for content in the channel.
    • setLanguage

      public void setLanguage(RssLanguage language)
      Parameters:
      language - The language the channel is written in.
    • setDescription

      public void setDescription(String description)
      Parameters:
      description - Phrase or sentence describing the channel.
    • setLink

      public void setLink(String link)
      Parameters:
      link - The URL to the HTML website corresponding to the channel.
    • setTitle

      public void setTitle(String title)
      Parameters:
      title - The name of the channel.
    • setItem

      public void setItem(List<RssItem> item)
      Parameters:
      item - A RSS Item.
    • builder

      public static RssChannel.Builder builder(String title, String link, String description)
      Parameters:
      title - The name of the channel.
      link - The URL to the HTML website corresponding to the channel.
      description - Phrase or sentence describing the channel.
      Returns:
      A Builder to build a RssChannel.