edu.cmu.ri.createlab.rss
Class FeedEntry

java.lang.Object
  extended by edu.cmu.ri.createlab.rss.FeedEntry

public final class FeedEntry
extends Object

FeedEntry represents a single entry from an RSS feed.

Author:
Chris Bartley (bartley@cmu.edu)

Constructor Summary
FeedEntry(String author, String title, String link, String description, Date publishedDate)
           
 
Method Summary
 boolean equals(Object o)
           
 String getAuthor()
          Returns the author, or an empty String if no author exists.
 String getDescription()
          Returns the description, or an empty String if no description exists.
 String getLink()
          Returns the link, or an empty String if no link exists.
 long getPublishedTimestamp()
          Returns the published timestamp, or 0 if no timestamp exists.
 Date getPublishedTimestampAsDate()
          Returns the published timestamp as a Date.
 String getTitle()
          Returns the title, or an empty String if no title exists.
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FeedEntry

public FeedEntry(String author,
                 String title,
                 String link,
                 String description,
                 Date publishedDate)
Method Detail

getAuthor

public String getAuthor()
Returns the author, or an empty String if no author exists. Guaranteed to not return null.


getTitle

public String getTitle()
Returns the title, or an empty String if no title exists. Guaranteed to not return null.


getLink

public String getLink()
Returns the link, or an empty String if no link exists. Guaranteed to not return null.


getDescription

public String getDescription()
Returns the description, or an empty String if no description exists. Guaranteed to not return null.


getPublishedTimestamp

public long getPublishedTimestamp()
Returns the published timestamp, or 0 if no timestamp exists.


getPublishedTimestampAsDate

public Date getPublishedTimestampAsDate()
Returns the published timestamp as a Date. Note that the date will be the "epoch" date if no timestamp actually exists.

See Also:
Date

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object