Holger's
Java API

com.antelmann.net.web
Class RSSHandler

java.lang.Object
  extended by com.antelmann.net.web.RSSHandler
All Implemented Interfaces:
Serializable

public class RSSHandler
extends Object
implements Serializable

handles RSS data feeds in XML. Supported formats include rss version 0.91 and 2.0 as well as rdf:RDF.

Author:
Holger Antelmann
See Also:
RSSItem, RSSChannel, RSSMenu, Serialized Form

Constructor Summary
RSSHandler(File file)
           
RSSHandler(InputSource source)
           
RSSHandler(InputStream stream)
           
RSSHandler(String url)
           
RSSHandler(URL url)
           
RSSHandler(URL url, String user, char[] password)
           
 
Method Summary
 RSSChannel getChannel()
          returns the first available channel in this rss feed (if any)
 RSSChannel[] getChannels()
          returns all available channels in this rss feed
 Document getDocument()
           
 String getFormat()
           
 String getVersion()
           
 void init(InputSource source)
          initializes the handler with content from the given source
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RSSHandler

public RSSHandler(String url)
           throws MalformedURLException,
                  FormatException,
                  IOException
Throws:
MalformedURLException
FormatException
IOException

RSSHandler

public RSSHandler(URL url)
           throws FormatException,
                  IOException
Throws:
FormatException
IOException

RSSHandler

public RSSHandler(URL url,
                  String user,
                  char[] password)
           throws FormatException,
                  IOException
Throws:
FormatException
IOException

RSSHandler

public RSSHandler(File file)
           throws FormatException,
                  IOException
Throws:
FormatException
IOException

RSSHandler

public RSSHandler(InputStream stream)
           throws FormatException,
                  IOException
Throws:
FormatException
IOException

RSSHandler

public RSSHandler(InputSource source)
           throws FormatException,
                  IOException
Throws:
FormatException
IOException
Method Detail

init

public void init(InputSource source)
          throws IOException,
                 FormatException
initializes the handler with content from the given source

Throws:
IOException
FormatException

getDocument

public Document getDocument()

getFormat

public String getFormat()

getVersion

public String getVersion()

getChannel

public RSSChannel getChannel()
                      throws FormatException
returns the first available channel in this rss feed (if any)

Throws:
FormatException

getChannels

public RSSChannel[] getChannels()
                         throws FormatException
returns all available channels in this rss feed

Throws:
FormatException


(c) Holger Antelmann since 2001- all rights reserved (contact: info@antelmann.com)
see www.antelmann.com/developer for further details and available downloads