mil.dod.th.ose.lexicon.doc/src/mil/dod/th/ose/lexicon/doc/parser/LexiconParser.java
private void traverseNodes(final NodeList nodeList, final Element parentElement, final LexiconBase lexiconField)
    {
        for (int i = 0; i < nodeList.getLength(); i++)
        {
            final Node node = nodeList.item(i);
            if (node.getNodeType() == Node.ELEMENT_NODE)
            {
                final Element element = (Element)node;
                final String nodeName = element.getNodeName();
                final String elementName = 
                        element.getAttribute(NAME_ATTR);
                
                if (nodeName.equals("xs:complexType"))
                {
                    handleComplexType(element, elementName, parentElement);
                }
                else if (nodeName.equals("xs:simpleType") && !Strings.isNullOrEmpty(elementName))
                {
                    handleSimpleType(element, elementName);
                }
                else if (nodeName.equals("xs:element") && lexiconField instanceof LexiconComplexType)
                {
                    handleElement(element, elementName, (LexiconComplexType)lexiconField);
                }
                else if (nodeName.equals("xs:attribute") && lexiconField instanceof LexiconComplexType)
                {
                    handleAttribute(element, elementName, (LexiconComplexType)lexiconField);
                }
                else if (nodeName.equals("xs:enumeration") && lexiconField instanceof LexiconSimpleType)
                {
                    handleEnumeration(element, (LexiconSimpleType)lexiconField);
                }
                else
                {
                    handleOtherElement(element, nodeName, lexiconField);
                }
            }
        }
    }
/**
     * Traverse the list of specified nodes.
     * 
     * @param nodeList
     *      List of nodes to parse.
     * @param parentElement
     *      Parent element of the list of nodes.
     * @param lexiconField
     *      Lexicon object the nodes belong to.
     */
Traverse the list of specified nodes.

@param nodeList
List of nodes to parse.
@param parentElement
Parent element of the list of nodes.
@param lexiconField
Lexicon object the nodes belong to.
Traverse the list of specified nodes . @param nodeList List of nodes to parse . @param parentElement Parent element of the list of nodes . @param lexiconField Lexicon object the nodes belong to .
private void traverseNodes(final NodeList nodeList, final Element parentElement, final LexiconBase lexiconField)
    {
        for (int i = 0; i < nodeList.getLength(); i++)
        {
            final Node node = nodeList.item(i);
            if (node.getNodeType() == Node.ELEMENT_NODE)
            {
                final Element element = (Element)node;
                final String nodeName = element.getNodeName();
                final String elementName = 
                        element.getAttribute(NAME_ATTR);
                if (nodeName.equals("xs:complexType"))
                {
                    handleComplexType(element, elementName, parentElement);
                }
                else if (nodeName.equals("xs:simpleType") && !Strings.isNullOrEmpty(elementName))
                {
                    handleSimpleType(element, elementName);
                }
                else if (nodeName.equals("xs:element") && lexiconField instanceof LexiconComplexType)
                {
                    handleElement(element, elementName, (LexiconComplexType)lexiconField);
                }
                else if (nodeName.equals("xs:attribute") && lexiconField instanceof LexiconComplexType)
                {
                    handleAttribute(element, elementName, (LexiconComplexType)lexiconField);
                }
                else if (nodeName.equals("xs:enumeration") && lexiconField instanceof LexiconSimpleType)
                {
                    handleEnumeration(element, (LexiconSimpleType)lexiconField);
                }
                else
                {
                    handleOtherElement(element, nodeName, lexiconField);
                }
            }
        }
    }
private void traverseNodes ( final NodeList nodeList , final Element parentElement , final LexiconBase lexiconField ) { for ( int i = 0 ; i < nodeList . getLength ( ) ; i ++ ) { final Node node = nodeList . item ( i ) ; if ( node . getNodeType ( ) == Node . ELEMENT_NODE ) { final Element element = ( Element ) node ; final String nodeName = element . getNodeName ( ) ; final String elementName = element . getAttribute ( NAME_ATTR ) ; if ( nodeName . equals ( "xs:complexType" ) ) { handleComplexType ( element , elementName , parentElement ) ; } else if ( nodeName . equals ( "xs:simpleType" ) && ! Strings . isNullOrEmpty ( elementName ) ) { handleSimpleType ( element , elementName ) ; } else if ( nodeName . equals ( "xs:element" ) && lexiconField instanceof LexiconComplexType ) { handleElement ( element , elementName , ( LexiconComplexType ) lexiconField ) ; } else if ( nodeName . equals ( "xs:attribute" ) && lexiconField instanceof LexiconComplexType ) { handleAttribute ( element , elementName , ( LexiconComplexType ) lexiconField ) ; } else if ( nodeName . equals ( "xs:enumeration" ) && lexiconField instanceof LexiconSimpleType ) { handleEnumeration ( element , ( LexiconSimpleType ) lexiconField ) ; } else { handleOtherElement ( element , nodeName , lexiconField ) ; } } } }
Traverse the list of specified nodes.
Traverse the list of specified nodes .