com.sun.syndication.feed.atom

Class Feed

public class Feed extends WireFeed

Bean for Atom feeds.

It handles Atom feeds version 0.3 without loosing any feed information.

Author: Alejandro Abdelnur Dave Johnson (updated for Atom 1.0)

Field Summary
List_alternateLinks
List_authors
List_categories
List_contributors
List_entries
Generator_generator
String_icon
String_id
Content_info
String_language
String_logo
List_modules
List_otherLinks
String_rights
Content_subtitle
Content_title
Date_updated
String_xmlBase
Constructor Summary
Feed()
Default constructor, for bean cloning purposes only.
Feed(String type)
Feed Constructor.
Method Summary
ListgetAlternateLinks()
Returns the feed alternate links.
ListgetAuthors()
Returns the feed author.
ListgetCategories()
Returns the categories

ListgetContributors()
Returns the feed contributors.
StringgetCopyright()
Returns the feed copyright (Atom 0.3, maps to getRights()).
ListgetEntries()
Returns the feed entries.
GeneratorgetGenerator()
Returns the feed generator.
StringgetIcon()
Returns the icon

StringgetId()
Returns the feed ID.
ContentgetInfo()
Returns the feed info (Atom 0.3 only)

StringgetLanguage()
Returns the feed language (Atom 0.3 only)

StringgetLogo()
Returns the logo

DategetModified()
Returns the feed modified date (Atom 0.3, maps to getUpdated()).
ModulegetModule(String uri)
Returns the module identified by a given URI.
ListgetModules()
Returns the feed modules.
ListgetOtherLinks()
Returns the feed other links (non-alternate ones).
StringgetRights()
Returns the rights

ContentgetSubtitle()
Returns the subtitle

ContentgetTagline()
Returns the feed tag line (Atom 0.3, maps to getSubtitle()).
StringgetTitle()
Returns the feed title.
ContentgetTitleEx()
Returns the feed title.
DategetUpdated()
Returns the updated

StringgetXmlBase()
Returns the xmlBase

voidsetAlternateLinks(List alternateLinks)
Sets the feed alternate links.
voidsetAuthors(List authors)
Sets the feed author.
voidsetCategories(List categories)
Set the categories

voidsetContributors(List contributors)
Sets the feed contributors.
voidsetCopyright(String copyright)
Sets the feed copyright (Atom 0.3, maps to setRights()).
voidsetEntries(List entries)
Sets the feed entries.
voidsetGenerator(Generator generator)
Sets the feed generator.
voidsetIcon(String icon)
Set the icon

voidsetId(String id)
Sets the feed ID.
voidsetInfo(Content info)
Sets the feed info (Atom 0.3 only)

voidsetLanguage(String language)
Sets the feed language (Atom 0.3 only)

voidsetLogo(String logo)
Set the logo

voidsetModified(Date modified)
Sets the feed modified date (Atom 0.3, maps to setUpdated()).
voidsetModules(List modules)
Sets the feed moduless.
voidsetOtherLinks(List otherLinks)
Sets the feed other links (non-alternate ones).
voidsetRights(String rights)
Set the rights

voidsetSubtitle(Content subtitle)
Set the subtitle

voidsetTagline(Content tagline)
Sets the feed tagline (Atom 0.3, maps to getSubtitle()).
voidsetTitle(String title)
Sets the feed title.
voidsetTitleEx(Content title)
Sets the feed title.
voidsetUpdated(Date updated)
Set the updated

voidsetXmlBase(String xmlBase)
Set the xmlBase

Field Detail

_alternateLinks

private List _alternateLinks

_authors

private List _authors

_categories

private List _categories

_contributors

private List _contributors

_entries

private List _entries

_generator

private Generator _generator

_icon

private String _icon

_id

private String _id

_info

private Content _info

_language

private String _language

private String _logo

_modules

private List _modules

_otherLinks

private List _otherLinks

_rights

private String _rights

_subtitle

private Content _subtitle

_title

private Content _title

_updated

private Date _updated

_xmlBase

private String _xmlBase

Constructor Detail

Feed

public Feed()
Default constructor, for bean cloning purposes only.

Feed

public Feed(String type)
Feed Constructor. All properties, except the type, are set to null.

Parameters: type the type of the Atom feed.

Method Detail

getAlternateLinks

public List getAlternateLinks()
Returns the feed alternate links.

Returns: a list of Link elements with the feed alternate links, an empty list if none.

getAuthors

public List getAuthors()
Returns the feed author.

Returns: the feed author, null if none.

getCategories

public List getCategories()
Returns the categories

Returns: Returns the categories.

Since: Atom 1.0

getContributors

public List getContributors()
Returns the feed contributors.

Returns: a list of Person elements with the feed contributors, an empty list if none.

getCopyright

public String getCopyright()
Returns the feed copyright (Atom 0.3, maps to getRights()).

Returns: the feed copyright, null if none.

getEntries

public List getEntries()
Returns the feed entries.

Returns: a list of Entry elements with the feed entries, an empty list if none.

getGenerator

public Generator getGenerator()
Returns the feed generator.

Returns: the feed generator, null if none.

getIcon

public String getIcon()
Returns the icon

Returns: Returns the icon.

Since: Atom 1.0

getId

public String getId()
Returns the feed ID.

Returns: the feed ID, null if none.

getInfo

public Content getInfo()
Returns the feed info (Atom 0.3 only)

Returns: the feed info, null if none.

getLanguage

public String getLanguage()
Returns the feed language (Atom 0.3 only)

Returns: the feed language, null if none.

getLogo

public String getLogo()
Returns the logo

Returns: Returns the logo.

Since: Atom 1.0

getModified

public Date getModified()
Returns the feed modified date (Atom 0.3, maps to getUpdated()).

Returns: the feed modified date, null if none.

getModule

public Module getModule(String uri)
Returns the module identified by a given URI.

Parameters: uri the URI of the ModuleImpl.

Returns: The module with the given URI, null if none.

getModules

public List getModules()
Returns the feed modules.

Returns: a list of ModuleImpl elements with the feed modules, an empty list if none.

getOtherLinks

public List getOtherLinks()
Returns the feed other links (non-alternate ones).

Returns: a list of Link elements with the feed other links (non-alternate ones), an empty list if none.

getRights

public String getRights()
Returns the rights

Returns: Returns the rights.

Since: Atom 1.0

getSubtitle

public Content getSubtitle()
Returns the subtitle

Returns: Returns the subtitle.

Since: Atom 1.0

getTagline

public Content getTagline()
Returns the feed tag line (Atom 0.3, maps to getSubtitle()).

Returns: the feed tag line, null if none.

getTitle

public String getTitle()
Returns the feed title.

Returns: the feed title, null if none.

getTitleEx

public Content getTitleEx()
Returns the feed title.

Returns: the feed title, null if none.

getUpdated

public Date getUpdated()
Returns the updated

Returns: Returns the updated.

Since: Atom 1.0

getXmlBase

public String getXmlBase()
Returns the xmlBase

Returns: Returns the xmlBase.

Since: Atom 1.0

setAlternateLinks

public void setAlternateLinks(List alternateLinks)
Sets the feed alternate links.

Parameters: alternateLinks the list of Link elements with the feed alternate links to set, an empty list or null if none.

setAuthors

public void setAuthors(List authors)
Sets the feed author.

Parameters: author the feed author to set, null if none.

setCategories

public void setCategories(List categories)
Set the categories

Parameters: categories The categories to set.

Since: Atom 1.0

setContributors

public void setContributors(List contributors)
Sets the feed contributors.

Parameters: contributors the list of Person elements with the feed contributors to set, an empty list or null if none.

setCopyright

public void setCopyright(String copyright)
Sets the feed copyright (Atom 0.3, maps to setRights()).

Parameters: copyright the feed copyright to set, null if none.

setEntries

public void setEntries(List entries)
Sets the feed entries.

Parameters: entries the list of Entry elements with the feed entries to set, an empty list or null if none.

setGenerator

public void setGenerator(Generator generator)
Sets the feed generator.

Parameters: generator the feed generator to set, null if none.

setIcon

public void setIcon(String icon)
Set the icon

Parameters: icon The icon to set.

Since: Atom 1.0

setId

public void setId(String id)
Sets the feed ID.

Parameters: id the feed ID to set, null if none.

setInfo

public void setInfo(Content info)
Sets the feed info (Atom 0.3 only)

Parameters: info the feed info to set, null if none.

setLanguage

public void setLanguage(String language)
Sets the feed language (Atom 0.3 only)

Parameters: language the feed language to set, null if none.

setLogo

public void setLogo(String logo)
Set the logo

Parameters: logo The logo to set.

Since: Atom 1.0

setModified

public void setModified(Date modified)
Sets the feed modified date (Atom 0.3, maps to setUpdated()).

Parameters: modified the feed modified date to set, null if none.

setModules

public void setModules(List modules)
Sets the feed moduless.

Parameters: modules the list of ModuleImpl elements with the feed moduless to set, an empty list or null if none.

setOtherLinks

public void setOtherLinks(List otherLinks)
Sets the feed other links (non-alternate ones).

Parameters: otherLinks the list of Link elements with the feed other links (non-alternate ones) to set, an empty list or null if none.

setRights

public void setRights(String rights)
Set the rights

Parameters: rights The rights to set.

Since: Atom 1.0

setSubtitle

public void setSubtitle(Content subtitle)
Set the subtitle

Parameters: subtitle The subtitle to set.

Since: Atom 1.0

setTagline

public void setTagline(Content tagline)
Sets the feed tagline (Atom 0.3, maps to getSubtitle()).

Parameters: tagline the feed tagline to set, null if none.

setTitle

public void setTitle(String title)
Sets the feed title.

Parameters: title the feed title to set, null if none.

setTitleEx

public void setTitleEx(Content title)
Sets the feed title.

Parameters: title the feed title to set, null if none.

setUpdated

public void setUpdated(Date updated)
Set the updated

Parameters: updated The updated to set.

Since: Atom 1.0

setXmlBase

public void setXmlBase(String xmlBase)
Set the xmlBase

Parameters: xmlBase The xmlBase to set.

Since: Atom 1.0

Copyright © Sun Microsystems. All Rights Reserved.