|
VdexReload 1.1.3 API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.text.html.HTMLEditorKit.ParserCallback
uk.ac.reload.editor.contentpackaging.htmlparser.HTMLParser
Class used to parse a web page and find all dependant links contained within it. Additionally used to figure out how & where to copy files when a user wishes to import them
Field Summary | |
protected boolean |
_absoluteLocalLinkFound
We want to know if a user has put an absolute local link in a page |
protected java.util.Vector |
_allLinks
All Links |
protected boolean |
_firstPage
We need to check the first page and see if it refers to local links that are higher up in the folder structure than itself. |
protected boolean |
_higherLocalLinkFound
We want to know if a user has imported a page which has a local link higher up the directory tree structure than itself |
protected javax.swing.text.html.HTML.Attribute[] |
_htmlAttributes
|
protected java.io.File |
_htmlFile
The File to Parse |
protected java.util.Hashtable |
_htmlResourcesTable
Our main data structure to hold source/destination paths |
protected java.io.File |
_rootFolder
The Root Folder |
protected java.io.File |
_startPath
Hold the starting point for the webpage(s) |
Fields inherited from class javax.swing.text.html.HTMLEditorKit.ParserCallback |
IMPLIED |
Constructor Summary | |
HTMLParser(java.io.File htmlFile)
Basic Constructor. |
|
HTMLParser(java.io.File htmlFile,
java.io.File rootFolder,
boolean userWantsToImport)
Constructor. |
Method Summary | |
java.io.File[] |
getAllLinks()
Return all Links |
java.util.Hashtable |
getLinks()
Accessor method for links found in page |
java.lang.String |
getTagText(java.lang.String tagName)
|
boolean |
isAbsoluteLocalLinkFound()
Accessor method to see if any FULL absolute local links were found in the page(s) i.e. |
boolean |
isHigherLocalLinkFound()
Accessor method to see if any local links were found in the first page that are higher in the directory tree than itself. |
Methods inherited from class javax.swing.text.html.HTMLEditorKit.ParserCallback |
flush, handleComment, handleEndOfLineString, handleEndTag, handleError, handleSimpleTag, handleStartTag, handleText |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected javax.swing.text.html.HTML.Attribute[] _htmlAttributes
protected java.io.File _htmlFile
protected boolean _firstPage
protected java.io.File _rootFolder
protected boolean _higherLocalLinkFound
protected boolean _absoluteLocalLinkFound
protected java.util.Hashtable _htmlResourcesTable
protected java.io.File _startPath
protected java.util.Vector _allLinks
Constructor Detail |
public HTMLParser(java.io.File htmlFile)
public HTMLParser(java.io.File htmlFile, java.io.File rootFolder, boolean userWantsToImport)
htmlFile
- the html file concernedrootFolder
- folder into which files are to be copieduserWantsToImport
- true or false valueMethod Detail |
public java.io.File[] getAllLinks()
public java.util.Hashtable getLinks()
public boolean isAbsoluteLocalLinkFound()
public boolean isHigherLocalLinkFound()
public java.lang.String getTagText(java.lang.String tagName)
|
VdexReload 1.1.3 API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |