예제 #1
0
        /**
         * This method is used at the beginning of every element in the XML document. All contents
         * of an element are reported, in order, prior to the invocation of the corresponding
         * endElement() method.
         *
         * @param uri is an empty string if the element has no Namespace URI or Namespace processing
         *     is not being performed. Otherwise, parameter is treated as a Namespace.
         * @param localName if Namespace processing is not being performed, parameter is an empty
         *     string.
         * @param qName represents the qualified name and if no qualified names are available,
         *     parameter is an empty string.
         * @param attributes are attached to the xml elements. This parameter is treated as an empty
         *     Attributes object, if no attributes are available.
         * @throws SAXException for any SAX exception.
         */
        public void startElement(String uri, String localName, String qName, Attributes attributes)
            throws SAXException {

          if (qName.equals("arguments")) {
            ap.addProgram(aname, adescription);
          }

          if (qName.equalsIgnoreCase("name")) {
            name = true;
          }

          if (qName.equalsIgnoreCase("type")) {
            type = true;
          }

          if (qName.equalsIgnoreCase("description")) {
            description = true;
          }

          if (qName.equalsIgnoreCase("default")) {
            defaults = true;
          }
          if (qName.equalsIgnoreCase("shorthand")) {
            shorthand = true;
          }
        }