@Override public void characters(char[] ch, int start, int length) throws SAXException { if (elementStack.peek().hashCode() != FILE_CODE) { return; } if (topRE.isFolder()) { return; } pcdata.append(new String(ch, start, length)); }
@Override public void endElement(String uri, String lname, String name) throws SAXException { if ((elementStack.peek().hashCode() == FILE_CODE) && !topRE.isFolder()) { String string = pcdata.toString().trim(); topRE.setContent(string.length() > 0 ? string.getBytes() : null, this.uri, weight); pcdata.setLength(0); } int controlCode = name.hashCode(); elementStack.pop(); if ((controlCode == FOLDER_CODE) || (controlCode == FILE_CODE)) { resElemStack.pop(); topRE = resElemStack.peek(); return; } }
public void characters(char[] ch, int start, int length) throws SAXException { if (elementStack.peek().hashCode() != FILE_CODE) return; if (topRE.isFolder ()) return; pcdata.append(new String(ch,start,length)); }
public void endElement(String name) throws SAXException { if (elementStack.peek().hashCode() == FILE_CODE && !topRE.isFolder ()) { String string = pcdata.toString().trim(); if (string.length() > 0) { topRE.setContent (string.getBytes()); } pcdata.setLength(0); } int controlCode = name.hashCode(); elementStack.pop(); if (controlCode == FOLDER_CODE || controlCode == FILE_CODE) { resElemStack.pop(); topRE = (ResourceElem)resElemStack.peek(); return ; } }
public void endElement(String name) throws SAXException { if (elementStack.peek().hashCode() == FILE_CODE && !topRE.isFolder ()) { String string = pcdata.toString().trim(); if (string.length() > 0) { topRE.setContent (string.getBytes()); } pcdata.setLength(0); } int controlCode = name.hashCode(); elementStack.pop(); if (controlCode == FOLDER_CODE || controlCode == FILE_CODE) { resElemStack.pop(); topRE = (ResourceElem)resElemStack.peek(); return ; } }
public void characters(char[] ch, int start, int length) throws SAXException { if (elementStack.peek().hashCode() != FILE_CODE) return; if (topRE.isFolder ()) return; pcdata.append(new String(ch,start,length)); }
public void initialize (ResourceElem res) { content = res.getContent (); XMLMapAttr tmp = res.getAttr (false); if (tmp != null && !tmp.isEmpty()) { foAttrs = tmp; } isFolder = (byte)(res.isFolder ()?1:0); if (content == null) content = res.getURI (); setUrlContext (res.getUrlContext ()); }
public void initialize (ResourceElem res) { content = res.getContent (); XMLMapAttr tmp = res.getAttr (false); if (tmp != null && !tmp.isEmpty()) { foAttrs = tmp; } isFolder = (byte)(res.isFolder ()?1:0); if (content == null) content = res.getURI (); setUrlContext (res.getUrlContext ()); }
public void initialize(ResourceElem res) { content = res.getContent(); XMLMapAttr tmp = res.getAttr(false); if ((tmp != null) && !tmp.isEmpty()) { foAttrs = tmp; } isFolder = (byte) (res.isFolder() ? 1 : 0); if (content == null) { content = res.getURI(); } setUrlContext(res.getUrlContext()); }