|
Copyright (c) 2000-2002 ChurchillObjects.com | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.xml.sax.helpers.DefaultHandler | +--churchillobjects.rss4j.parser.RssParser | +--churchillobjects.rss4j.parser.RssParserImpl090
Class to parse an RSS document according to the specifications of the RSS .90 standard. This object is created when the base parser already started parsing the document (and knows what the version number is), so it is given the document object and the known namespaces up to that point.
Field Summary | |
protected boolean |
inChannel
Indicates that the SAX handling process is currently in a channel. |
protected boolean |
inImage
Indicates that the SAX handling process is currently in an image. |
protected boolean |
inItem
Indicates that the SAX handling process is currently in an item. |
protected boolean |
inTextInput
Indicates that the SAX handling process is currently in a text input. |
private static java.lang.String |
VERSION
Hard-coded version number for this handler's RSS version. |
Fields inherited from class churchillobjects.rss4j.parser.RssParser |
currentChannel, currentImage, currentItem, currentTextInput, document, namespaces |
Fields inherited from interface churchillobjects.rss4j.model.RssVersion |
VERSION_10, VERSION_90, VERSION_91 |
Constructor Summary | |
(package private) |
RssParserImpl090(churchillobjects.rss4j.RssDocument document,
java.util.Vector namespaces)
Constructor for this RSS verion's parser. |
Method Summary | |
private void |
closeChannelElement()
Upon close of channel element, adds the current channel to the document, sets it to null and sets the inChannel flag to false. |
private void |
closeImageElement()
Upon close of image element, adds the current image to the channel, sets it to null and sets the inImage flag to false. |
private void |
closeItemElement()
Upon close of item element, adds the current item to the channel, sets it to null and sets the inItem flag to false. |
private void |
closeTextInputElement()
Upon close of TextInput element, adds the current text input to the channel, sets it to null and sets the inTextInput flag to false. |
void |
endElement(java.lang.String uri,
java.lang.String name,
java.lang.String qName)
SAX interface method. |
private void |
handleDescriptionAttribute()
Handles the description attribute by adding the characters to the current text input or channel, depending on the flags. |
private void |
handleLinkAttribute()
Handles the link attribute by adding the characters to the current text input, image, item or channel, depending on the flags. |
private void |
handleNameAttribute()
Handles the name attribute by adding the characters to the current text input if that flag is set. |
private void |
handleTitleAttribute()
Handles the title attribute by adding the characters to the current text input, image, item or channel, depending on the flags. |
private void |
handleUrlAttribute()
Handles the url attribute by adding the characters to the current image if that flag is set. |
void |
startElement(java.lang.String uri,
java.lang.String name,
java.lang.String qName,
org.xml.sax.Attributes attrs)
SAX interface method. |
Methods inherited from class churchillobjects.rss4j.parser.RssParser |
characters, cleanUp, getAttribute, getChars, hasChars, parseRss, parseRss, parseRss, parseRss, parseRss, resetChars, startPrefixMapping |
Methods inherited from class org.xml.sax.helpers.DefaultHandler |
endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, unparsedEntityDecl, warning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected boolean inChannel
protected boolean inItem
protected boolean inTextInput
protected boolean inImage
private static final java.lang.String VERSION
Constructor Detail |
RssParserImpl090(churchillobjects.rss4j.RssDocument document, java.util.Vector namespaces)
document
- namespaces
- Method Detail |
public void startElement(java.lang.String uri, java.lang.String name, java.lang.String qName, org.xml.sax.Attributes attrs) throws org.xml.sax.SAXException
startElement
in interface org.xml.sax.ContentHandler
startElement
in class RssParser
uri
- name
- qName
- attrs
-
org.xml.sax.SAXException
public void endElement(java.lang.String uri, java.lang.String name, java.lang.String qName) throws org.xml.sax.SAXException
endElement
in interface org.xml.sax.ContentHandler
endElement
in class org.xml.sax.helpers.DefaultHandler
uri
- name
- qName
-
org.xml.sax.SAXException
private void closeChannelElement()
private void closeItemElement()
private void closeTextInputElement()
private void closeImageElement()
private void handleTitleAttribute()
private void handleDescriptionAttribute()
private void handleLinkAttribute()
private void handleUrlAttribute()
private void handleNameAttribute()
|
Copyright (c) 2000-2002 ChurchillObjects.com | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |