|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectjava.lang.Thread
net.sourceforge.rssowl.controller.thread.ExtendedThread
net.sourceforge.rssowl.controller.thread.FeedValidator
This thread is used to validate a newsfeed and give the results to the calling ValidateFeedDialog
| Field Summary | |
(package private) String |
dtdToValidate
|
private String |
feedPath
|
private String |
format
|
private String |
humanReadableFeedFormat
|
(package private) boolean |
isWarningOrError
|
(package private) boolean |
overrideDTD
|
(package private) ValidateFeedDialog |
rssOwlValidateFeedDialog
|
private static String |
TMP_XML_NAME
Temp name of the locally saved XML document |
| Fields inherited from class net.sourceforge.rssowl.controller.thread.ExtendedThread |
stopped |
| Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
| Constructor Summary | |
FeedValidator(ValidateFeedDialog rssOwlValidateFeedDialog,
String feedPath,
String format,
boolean overrideDTD)
Instantiate a new FeedValidator |
|
| Method Summary | |
private void |
autoDetectFormat(org.jdom.Document document)
Auto detect the format from the given document |
private void |
downloadFeed()
Download the newsfeed to save it locally. |
void |
run()
Download, Save and Validate given feed. |
private void |
saveFeed(org.jdom.Document document)
Write the document to disk. |
private void |
setDTDToValidate(org.jdom.Document document)
This method sets a null.dtd as Doctype to the document and then sets the DTD that should be used to validate the XML. |
void |
stopThread()
Stop the Feed Validator |
private void |
validateFeed()
Validate the newsfeed using JDom |
| Methods inherited from class net.sourceforge.rssowl.controller.thread.ExtendedThread |
isStopped, startThread |
| Methods inherited from class java.lang.Thread |
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
private static final String TMP_XML_NAME
private String feedPath
private String format
private String humanReadableFeedFormat
String dtdToValidate
boolean isWarningOrError
boolean overrideDTD
ValidateFeedDialog rssOwlValidateFeedDialog
| Constructor Detail |
public FeedValidator(ValidateFeedDialog rssOwlValidateFeedDialog,
String feedPath,
String format,
boolean overrideDTD)
rssOwlValidateFeedDialog - The calling validate feed dialogfeedPath - The path of the feed to validateformat - The feed format (may be auto-detection to let RSSOwl detect
it)overrideDTD - TRUE if the DTD declaration should get overriden| Method Detail |
public void run()
Runnable.run()public void stopThread()
stopThread in class ExtendedThread
private void autoDetectFormat(org.jdom.Document document)
throws NewsfeedFactoryException
document - The newsfeed as XMl document
NewsfeedFactoryException - If an error occurs
private void downloadFeed()
throws org.jdom.JDOMException,
IOException,
NewsfeedFactoryException,
IllegalArgumentException
org.jdom.JDOMException - If an error occurs
IOException - If an error occurs
NewsfeedFactoryException - If an error occurs
IllegalArgumentException - If an error occursprivate void saveFeed(org.jdom.Document document)
document - The document to save
private void setDTDToValidate(org.jdom.Document document)
throws NewsfeedFactoryException
document - The document to validate
NewsfeedFactoryException - If an error occurs
private void validateFeed()
throws org.jdom.JDOMException,
IOException,
IllegalArgumentException
org.jdom.JDOMException - If an error occurs
IOException - If an error occurs
IllegalArgumentException - If an error occurs
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||