: Class RSSHandler
com.exploringxml.rss
Class RSSHandler
com.exploringxml.rss.RSSHandler
- public class RSSHandler
Receives the callback events from the XML parser and populates the associated
RSSChannel object with the retrieved data
currently depends on the Aelfred XML parser
|
Constructor Summary |
RSSHandler(RSSChannel channel)
creates a handler to populate a specific RSSChannel |
|
Method Summary |
void |
charData(char[] chars,
int from,
int to)
gets called by the XML parser when character data was encountered |
void |
endElement(java.lang.String tag)
gets called by the XML parser when an XML end tag was encountered |
void |
startElement(java.lang.String tag)
gets called by the XML parser when an XML start tag was encountered |
channel
RSSChannel channel
readingChannel
boolean readingChannel
readingImage
boolean readingImage
readingItem
boolean readingItem
readingTitle
boolean readingTitle
readingLink
boolean readingLink
readingDescription
boolean readingDescription
readingURL
boolean readingURL
addedTitle
boolean addedTitle
addedLink
boolean addedLink
itemCounter
int itemCounter
RSSHandler
public RSSHandler(RSSChannel channel)
- creates a handler to populate a specific RSSChannel
- Parameters:
channel - the RSSChannel to populate with parsed data
startElement
public void startElement(java.lang.String tag)
throws java.lang.Exception
- gets called by the XML parser when an XML start tag was encountered
- Parameters:
tag - the String that was parsed as a start tag
endElement
public void endElement(java.lang.String tag)
throws java.lang.Exception
- gets called by the XML parser when an XML end tag was encountered
- Parameters:
tag - the String that was parsed as an end tag
charData
public void charData(char[] chars,
int from,
int to)
throws java.lang.Exception
- gets called by the XML parser when character data was encountered
- Parameters:
chars - the characters that were parsedfrom - the start position of the characters within the arrayto - the end position of the characters within the array