@Override public String toString() { final ByteArrayOutputStream buf = new ByteArrayOutputStream(); try { this.toXML(buf, true); } catch (IOException e) { throw new RuntimeException(e); } return new String(buf.toByteArray(), Charset.forName("UTF-8")) .replaceAll("(?s)<\\?xml version=\"1\\.0\" encoding=\"UTF-8\"\\?>\n", "").trim(); }
schemaModel.toXML(buf, false); } catch (IOException e) { throw new RuntimeException("unexpected exception", e);