/** @see LogReadable#dumpLog */ public void dumpLog(StringBuffer sb, boolean verbose) { sb.append(beginTag()); super.dumpLog(sb, verbose); if (data != null) { sb.append("<data>"); sb.append(TreeUtils.dumpByteArray(data)); sb.append("</data>"); } dumpLogAdditional(sb, verbose); sb.append(endTag()); }
public String dumpString(int nSpaces, boolean dumpTags) { StringBuffer self = new StringBuffer(); if (dumpTags) { self.append(TreeUtils.indent(nSpaces)); self.append(beginTag()); self.append('\n'); } self.append(super.dumpString(nSpaces + 2, true)); self.append('\n'); if (data != null) { self.append(TreeUtils.indent(nSpaces + 2)); self.append("<data>"); self.append(TreeUtils.dumpByteArray(data)); self.append("</data>"); self.append('\n'); } if (dumpTags) { self.append(TreeUtils.indent(nSpaces)); self.append(endTag()); } return self.toString(); }