|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwxtpages.scripthandler
An instance of scripthandler parses the script and generates the pagestructure as a list of unitGroup instances that in turn owns unitPage instances. The scripthandler is the interface to the GUI Each siteFrame in the GUI owns an instance of scripthandler. There is no reference back to the GUI.
Field Summary | |
protected java.util.HashMap |
m_programMap
All registered programs, as in program-elements in the script |
protected java.util.HashMap |
m_scriptOptionMap
All registered options that are scriptglobals |
Constructor Summary | |
scripthandler(java.lang.String script,
java.lang.String scriptPath,
reporter rep)
Creates a new instance of scripthandler Establish sitestructure |
Method Summary | |
boolean |
buildForced(javax.swing.JProgressBar pBar,
java.util.Vector units)
Building everything or selected units (pages or groups), unconditionally |
boolean |
buildForcedOnePage(java.lang.String pageID)
Building one page unconditionally, if we can find it Used when we build a single page from the commandline |
void |
buildStructure()
Assumes that the The DOM is established and has been checked for wellformedness. |
boolean |
buildUpdated(javax.swing.JProgressBar pBar)
Building the pages that have updated components, template and/or content-files and/or transformations. |
protected void |
cleanOutdatedElements(org.w3c.dom.Element e)
Removes all elements in the tree that have a datespan not covering to day |
protected void |
collectFromScript()
Collect values that are allowed at scriptlevel: version and programs and option logfile |
boolean |
controlLinks(java.util.Vector tagAttList,
javax.swing.JProgressBar pBar,
boolean includeAbsolutes)
Controlling links in all pages |
java.lang.String |
getDirectoryPath()
Get the path to the scripts directory |
java.util.Vector |
getFileList()
Return list of all groups and pages that will be built. |
unitGroup |
getGroupByName(java.lang.String groupName)
Return a group with a given name |
java.util.Vector |
getGroupList()
Return list of all grups that will be built. |
java.util.Vector |
getPageList()
Return list of all pages that will be built. |
java.lang.String |
getProgram(java.lang.String programName)
Get the path for a registered program |
reporter |
getReporter()
Get this scripthandler reporter |
org.w3c.dom.Document |
getScriptDoc()
Get the script as a document |
java.util.Vector |
makePagelistByXPath(org.w3c.dom.Node contextNode,
java.lang.String xpath)
Collect a pagelist from the script, based on an xpath |
void |
setLogFileAndToday()
Tell the reporter to set a new file to accumulate log Value set is either null, or taken from optionmap Tell accessutils-library which date we have to day |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.util.HashMap m_programMap
protected java.util.HashMap m_scriptOptionMap
Constructor Detail |
public scripthandler(java.lang.String script, java.lang.String scriptPath, reporter rep) throws java.lang.Exception
scriptPath
- The path to the scriptscript
- The script as textrep
- The reporter object that all reporting objects in this script will use
java.lang.Exception
- when we dont have a parsable scriptMethod Detail |
public org.w3c.dom.Document getScriptDoc()
public reporter getReporter()
public java.lang.String getProgram(java.lang.String programName)
programName
- the program we are looking for
public void setLogFileAndToday()
public java.lang.String getDirectoryPath()
public java.util.Vector getFileList()
public java.util.Vector getPageList()
public java.util.Vector getGroupList()
public unitGroup getGroupByName(java.lang.String groupName)
groupName
- The name of the group we are looking for
public boolean buildForced(javax.swing.JProgressBar pBar, java.util.Vector units)
pBar
- A progress bar that we want to update, null if we run without GUIunits
- The pages we want to build, all if null
public boolean buildForcedOnePage(java.lang.String pageID)
pageID
- The page or group we want to build
public boolean buildUpdated(javax.swing.JProgressBar pBar)
pBar
- A progress bar that we want to update, null if we run without GUI
public boolean controlLinks(java.util.Vector tagAttList, javax.swing.JProgressBar pBar, boolean includeAbsolutes)
tagAttList
- The list of tag/attributes to be checkedincludeAbsolutes
- true if absolute links should be checkedpBar
- A progress bar that we want to update, null if we run without GUI
public void buildStructure() throws java.lang.Exception
java.lang.Exception
- when we cannot parseprotected void collectFromScript() throws java.lang.Exception
java.lang.Exception
- if version is wrong or missingpublic java.util.Vector makePagelistByXPath(org.w3c.dom.Node contextNode, java.lang.String xpath)
xpath
- The xpath that selects pagescontextNode
- The contextnode
protected void cleanOutdatedElements(org.w3c.dom.Element e)
e
- The element we investigate
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |