/** * Start a package. Parses out package attribute by default. * Return false to skip package element and its contents. */ protected boolean startPackage(String elem, Attributes attrs) throws SAXException { if (getPackageAttributeName() != null) { _package = attrs.getValue(getPackageAttributeName()); if (_package == null) _package = ""; } return true; }
/** * Start a package. Parses out package attribute by default. * Return false to skip package element and its contents. */ protected boolean startPackage(String elem, Attributes attrs) throws SAXException { if (getPackageAttributeName() != null) { _package = attrs.getValue(getPackageAttributeName()); if (_package == null) _package = ""; } return true; }
/** * Start a package. Parses out package attribute by default. * Return false to skip package element and its contents. */ protected boolean startPackage(String elem, Attributes attrs) throws SAXException { if (getPackageAttributeName() != null) { _package = attrs.getValue(getPackageAttributeName()); if (_package == null) _package = ""; } return true; }
/** * Start a package. Parses out package attribute by default. * Return false to skip package element and its contents. */ protected boolean startPackage(String elem, Attributes attrs) throws SAXException { if (getPackageAttributeName() != null) { _package = attrs.getValue(getPackageAttributeName()); if (_package == null) _package = ""; } return true; }
/** * End a package. Parses contained text by default. */ protected void endPackage(String elem) { if (getPackageAttributeName() != null) _package = null; else _package = currentText(); }
/** * End a package. Parses contained text by default. */ protected void endPackage(String elem) { if (getPackageAttributeName() != null) _package = null; else _package = currentText(); }
/** * End a package. Parses contained text by default. */ protected void endPackage(String elem) { if (getPackageAttributeName() != null) _package = null; else _package = currentText(); }
/** * End a package. Parses contained text by default. */ protected void endPackage(String elem) { if (getPackageAttributeName() != null) _package = null; else _package = currentText(); }
return startClassElement(name, attrs); if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) return startPackageElement(name, attrs); return startSystemElement(name, attrs);
endClassElement(name); else if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) endPackageElement(name); else
return startClassElement(name, attrs); if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) return startPackageElement(name, attrs); return startSystemElement(name, attrs);
return startClassElement(name, attrs); if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) return startPackageElement(name, attrs); return startSystemElement(name, attrs);
endClassElement(name); else if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) endPackageElement(name); else
endClassElement(name); else if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) endPackageElement(name); else
protected boolean startElement(String name, Attributes attrs) throws SAXException { // skip root element int depth = currentDepth(); if (depth == 0) return true; try { if (depth == getPackageElementDepth() && isPackageElementName(name)) return startPackage(name, attrs); if (depth == getClassElementDepth() && isClassElementName(name)) return startClass(name, attrs); if (depth > getClassElementDepth() && _class != null && getClassAttributeName() != null) return startClassElement(name, attrs); if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) return startPackageElement(name, attrs); return startSystemElement(name, attrs); } catch (SAXException se) { throw se; } catch (NullPointerException npe) { throw getException(_loc.get("parse-error", name), npe); } }
protected void endElement(String name) throws SAXException { // skip root element int depth = currentDepth(); if (depth == 0) return; try { if (depth == getPackageElementDepth() && isPackageElementName(name)) endPackage(name); else if (depth == getClassElementDepth() && isClassElementName(name)) endClass(name); else if (depth > getClassElementDepth() && _class != null && getClassAttributeName() != null) endClassElement(name); else if (depth > getPackageElementDepth() && _package != null && getPackageAttributeName() != null) endPackageElement(name); else endSystemElement(name); } catch (SAXException se) { throw se; } catch (NullPointerException npe) { throw getException(_loc.get("parse-error", name), npe); } }