org.opennms.bb.eui.operator.utils
Class EUIMenuParser

java.lang.Object
  |
  +--org.opennms.bb.common.utils.BBParser
        |
        +--org.opennms.bb.eui.operator.utils.EUIMenuParser

public class EUIMenuParser
extends BBParser

 EUIMenuParser parses the EUI external menu xml and stores the data 
 read in a vectors. This can then be queried for the data using the 
 'get..' functions

 It throws an IOException if the xml file is not found or if it does not
 conform to its DTD 

Author:
Sowmya Modifications: 04/18/00 - Changed the parser to extend BBParser - Sowmya

Inner classes inherited from class org.opennms.bb.common.utils.BBParser
BBParser.BBErrorHandler
 
Field Summary
(package private)  String CLASSNAME
           
(package private)  String HOTKEY
           
(package private)  int INITIAL_CAPACITY
           
(package private)  String LABEL
           
(package private)  String MENU
           
(package private)  String MENUS
           
(package private)  Vector menusVector
           
(package private)  String SUBMENUS
           
(package private)  String TOPMENU
           
 
Fields inherited from class org.opennms.bb.common.utils.BBParser
ATTRIB_VALUE_PAIR_ERR, ATTRIB_VALUE_PAIR_ERR_STR, EXCEPTION, m_curElement, m_errNum, m_exceptionMsg, m_inpSource, m_parser, NULL_VALUE_ERR, NULL_VALUE_ERR_STR
 
Constructor Summary
EUIMenuParser()
          Creates the DOM parser
 
Method Summary
 Vector getMenuData()
          Returns the menu information - the data returned is a vector
protected  boolean processElement(org.w3c.dom.Element el, boolean isRoot)
          This is the method to be overridden by sub-classes to branch off and go through the DOM tree to handle elements specific to the XML they are parsing - does nothing here
protected  boolean processMenuElement(org.w3c.dom.Node menuNode, Vector subMenusVector)
           
protected  boolean processMenus(org.w3c.dom.Node menusNode)
           
protected  boolean processTopMenuElement(org.w3c.dom.Node topMenuNode)
           
 
Methods inherited from class org.opennms.bb.common.utils.BBParser
getErrorMessage, getErrorNumber, parse, parse, parse, parse, processDocument, processNode, processParmValue
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

menusVector

Vector menusVector

MENUS

final String MENUS

TOPMENU

final String TOPMENU

MENU

final String MENU

CLASSNAME

final String CLASSNAME

LABEL

final String LABEL

HOTKEY

final String HOTKEY

SUBMENUS

final String SUBMENUS

INITIAL_CAPACITY

final int INITIAL_CAPACITY
Constructor Detail

EUIMenuParser

public EUIMenuParser()
Creates the DOM parser
Method Detail

processElement

protected boolean processElement(org.w3c.dom.Element el,
                                 boolean isRoot)
Description copied from class: BBParser
This is the method to be overridden by sub-classes to branch off and go through the DOM tree to handle elements specific to the XML they are parsing - does nothing here
Overrides:
processElement in class BBParser
Following copied from class: org.opennms.bb.common.utils.BBParser
Returns:
true if processed sucessfully, false otherwise

processMenus

protected boolean processMenus(org.w3c.dom.Node menusNode)

processTopMenuElement

protected boolean processTopMenuElement(org.w3c.dom.Node topMenuNode)

processMenuElement

protected boolean processMenuElement(org.w3c.dom.Node menuNode,
                                     Vector subMenusVector)

getMenuData

public Vector getMenuData()
Returns the menu information - the data returned is a vector