|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.syndication.io.WireFeedOutput
Generates an XML document (String, File, OutputStream, Writer, W3C DOM document or JDOM document) out of an WireFeed (RSS/Atom).
It generates all flavors of RSS (0.90, 0.91, 0.92, 0.93, 0.94, 1.0 and 2.0) and Atom 0.3 feeds. Generators are plugable (they must implement the ModuleParser interface).
Constructor Summary | |
WireFeedOutput()
Creates a FeedOuput instance. |
Method Summary | |
static java.util.List |
getSupportedFeedTypes()
Returns the list of supported output feed types. |
void |
output(WireFeed feed,
java.io.File file)
Creates a File containing with the XML representation for the given WireFeed. |
void |
output(WireFeed feed,
java.io.Writer writer)
Writes to an Writer the XML representation for the given WireFeed. |
org.jdom.Document |
outputJDom(WireFeed feed)
Creates a JDOM document for the given WireFeed. |
java.lang.String |
outputString(WireFeed feed)
Creates a String with the XML representation for the given WireFeed. |
org.w3c.dom.Document |
outputW3CDom(WireFeed feed)
Creates a W3C DOM document for the given WireFeed. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public WireFeedOutput()
Method Detail |
public static java.util.List getSupportedFeedTypes()
for details on the format of these strings.
public java.lang.String outputString(WireFeed feed) throws java.lang.IllegalArgumentException, FeedException
NOTE: This method delages to the 'Document WireFeedOutput#outputJDom(WireFeed)'.
feed
- Abstract feed to create XML representation from. The type of the WireFeed must match
the type given to the FeedOuptut constructor.
java.lang.IllegalArgumentException
- thrown if the feed type of the WireFeedOutput and WireFeed don't match.
FeedException
- thrown if the XML representation for the feed could not be created.public void output(WireFeed feed, java.io.File file) throws java.lang.IllegalArgumentException, java.io.IOException, FeedException
NOTE: This method delages to the 'Document WireFeedOutput#outputJDom(WireFeed)'.
feed
- Abstract feed to create XML representation from. The type of the WireFeed must match
the type given to the FeedOuptut constructor.file
- the file where to write the XML representation for the given WireFeed.
java.lang.IllegalArgumentException
- thrown if the feed type of the WireFeedOutput and WireFeed don't match.
java.io.IOException
- thrown if there was some problem writing to the File.
FeedException
- thrown if the XML representation for the feed could not be created.public void output(WireFeed feed, java.io.Writer writer) throws java.lang.IllegalArgumentException, java.io.IOException, FeedException
NOTE: This method delages to the 'Document WireFeedOutput#outputJDom(WireFeed)'.
feed
- Abstract feed to create XML representation from. The type of the WireFeed must match
the type given to the FeedOuptut constructor.writer
- Writer to write the XML representation for the given WireFeed.
java.lang.IllegalArgumentException
- thrown if the feed type of the WireFeedOutput and WireFeed don't match.
java.io.IOException
- thrown if there was some problem writing to the Writer.
FeedException
- thrown if the XML representation for the feed could not be created.public org.w3c.dom.Document outputW3CDom(WireFeed feed) throws java.lang.IllegalArgumentException, FeedException
NOTE: This method delages to the 'Document WireFeedOutput#outputJDom(WireFeed)'.
feed
- Abstract feed to create W3C DOM document from. The type of the WireFeed must match
the type given to the FeedOuptut constructor.
java.lang.IllegalArgumentException
- thrown if the feed type of the WireFeedOutput and WireFeed don't match.
FeedException
- thrown if the W3C DOM document for the feed could not be created.public org.jdom.Document outputJDom(WireFeed feed) throws java.lang.IllegalArgumentException, FeedException
NOTE: All other output methods delegate to this method.
feed
- Abstract feed to create JDOM document from. The type of the WireFeed must match
the type given to the FeedOuptut constructor.
java.lang.IllegalArgumentException
- thrown if the feed type of the WireFeedOutput and WireFeed don't match.
FeedException
- thrown if the JDOM document for the feed could not be created.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |