public class XMLMenuBuilder extends XMLInterpreter implements MenuBuilder
| Modifier and Type | Field and Description |
|---|---|
protected String |
baseClasspath |
protected String |
defaultPackage |
protected Hashtable |
equivalenceLabelList |
static boolean |
INCLUDE_DEFAULT_LABELS |
protected JMenuBar |
menuBar |
protected static ExtendedMenuXmlParser |
menuParser |
IMPORT_TAG, LABELS_FILE, SILENT| Constructor and Description |
|---|
XMLMenuBuilder(Hashtable labelEquivalences) |
XMLMenuBuilder(Hashtable labelEquivalences,
String guiClassesPackage) |
XMLMenuBuilder(String uriLabelsFile) |
XMLMenuBuilder(String uriLabelsFile,
String guiClassesPackage) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendMenu(JMenuBar menuBar,
String xmlDefinition) |
JMenuBar |
buildMenu(String fileURI)
Creates a JMenuBar with the components specified in the file.
|
JMenuBar |
buildMenu(StringBuffer fileContent) |
protected Object |
findAttr(Object parent,
String attr) |
String |
getBaseClasspath() |
protected Document |
performExtendedMenu(Document doc,
String fileURI) |
protected void |
processChildren(CustomNode node,
Object parent) |
protected void |
processChildren(CustomNode node,
Object parent,
boolean dynamic,
boolean module) |
void |
processModules(CustomNode node,
Object parent) |
void |
setBaseClasspath(String baseClasspath) |
protected Object |
translateTag(CustomNode childNode,
Object parent,
String packageName,
Hashtable equivalenceList) |
protected Object |
translateTag(CustomNode childNode,
Object parent,
String packageName,
Hashtable equivalenceList,
boolean dynamic,
boolean module) |
createComponent, getDefaultLabelList, getDocumentModel, getDocumentModel, getDocumentModel, getDocumentTreeModel, getExtendedDocument, getExtendedDocument, getRoot, interpreterTag, processLabelFilepublic static boolean INCLUDE_DEFAULT_LABELS
protected String defaultPackage
protected Hashtable equivalenceLabelList
protected JMenuBar menuBar
protected static ExtendedMenuXmlParser menuParser
protected String baseClasspath
public XMLMenuBuilder(String uriLabelsFile) throws Exception
uriLabelsFile - URI to the labels file. Example 'http://.../xml/labels.xml'.Exceptionpublic XMLMenuBuilder(String uriLabelsFile, String guiClassesPackage) throws Exception
uriLabelsFile - URI to the labels file. Example 'http://.../xml/labels.xml'.guiClassesPackage - Package where all classes specified in the xml file are storedExceptionpublic XMLMenuBuilder(Hashtable labelEquivalences) throws Exception
Exceptionpublic void appendMenu(JMenuBar menuBar, String xmlDefinition)
appendMenu in interface MenuBuilderpublic JMenuBar buildMenu(String fileURI)
MenuBuilderbuildMenu in interface MenuBuilderpublic JMenuBar buildMenu(StringBuffer fileContent) throws Exception
Exceptionprotected void processChildren(CustomNode node, Object parent)
protected void processChildren(CustomNode node, Object parent, boolean dynamic, boolean module)
public void processModules(CustomNode node, Object parent)
protected Object translateTag(CustomNode childNode, Object parent, String packageName, Hashtable equivalenceList)
protected Object translateTag(CustomNode childNode, Object parent, String packageName, Hashtable equivalenceList, boolean dynamic, boolean module)
public String getBaseClasspath()
public void setBaseClasspath(String baseClasspath)
Copyright © 2016 Imatia Innovation S.L.. All rights reserved.