@Test public void start() { try { final XMLtuple tRead = new XMLtuple(); final XMLtuple tWrite = new XMLtuple(new Integer(1), new String("un")); final File temp = File.createTempFile("xw-junit", "itf"); final FileOutputStream fout = new FileOutputStream(temp); final DataOutputStream dos = new DataOutputStream(fout); tWrite.setLoggerLevel(LoggerLevel.DEBUG); tWrite.setDUMPNULLS(true); final XMLWriter writer = new XMLWriter(dos); writer.write(tWrite); final XMLReader reader = new XMLReader(tRead); reader.read(new FileInputStream(temp)); tRead.setDUMPNULLS(true); assertTrue(tWrite.toXml().equals(tRead.toXml())); } catch (final Exception e) { e.printStackTrace(); assert(false); } }
@Override public String toXml() { String ret = "<" + getXMLTag() + ">"; if (key != null) { ret += key.toXml(); } if (value != null) { ret += value.toXml(); } ret += "</" + getXMLTag() + ">"; return ret; }
XMLtuple extends XMLable { @Override public String toXml() { String ret = "<" + getXMLTag() + ">"; if (key != null) { ret += key.toXml(); } if (value != null) { ret += value.toXml(); } ret += "</" + getXMLTag() + ">"; return ret; } }
XMLtuple extends XMLable { @Override public String toXml() { String ret = "<" + getXMLTag() + ">"; if (key != null) { ret += key.toXml(); } if (value != null) { ret += value.toXml(); } ret += "</" + getXMLTag() + ">"; return ret; } XMLtuple();  XMLtuple(final XMLKey k, final XMLValue v);  XMLtuple(final Object k, final Object v);  XMLtuple(final DataInputStream input);  XMLtuple(final Attributes attrs); }
XMLtuple extends XMLable { @Override public String toXml() { String ret = "<" + getXMLTag() + ">"; if (key != null) { ret += key.toXml(); } if (value != null) { ret += value.toXml(); } ret += "</" + getXMLTag() + ">"; return ret; } XMLtuple();  XMLtuple(final XMLKey k, final XMLValue v);  XMLtuple(final Object k, final Object v);  XMLtuple(final DataInputStream input);  XMLtuple(final Attributes attrs); @Override void fromXml(final Attributes attrs); @Override String toXml(); @Override void xmlElementStart(final String uri, final String tag, final String qname, final Attributes attrs); @Override void xmlElementStop(final String uri, final String tag, final String qname); @Override String toString(); @Override String toString(final boolean csv); XMLKey getXMLKey(); XMLValue getXMLValue(); Object getKey(); Object getValue(); void setKey(final Object k); void setValue(final Object v); void setKey(final XMLKey k); void setValue(final XMLValue v); static void main(final String[] argv); }
XMLtuple extends XMLable { @Override public String toXml() { String ret = "<" + getXMLTag() + ">"; if (key != null) { ret += key.toXml(); } if (value != null) { ret += value.toXml(); } ret += "</" + getXMLTag() + ">"; return ret; } XMLtuple();  XMLtuple(final XMLKey k, final XMLValue v);  XMLtuple(final Object k, final Object v);  XMLtuple(final DataInputStream input);  XMLtuple(final Attributes attrs); @Override void fromXml(final Attributes attrs); @Override String toXml(); @Override void xmlElementStart(final String uri, final String tag, final String qname, final Attributes attrs); @Override void xmlElementStop(final String uri, final String tag, final String qname); @Override String toString(); @Override String toString(final boolean csv); XMLKey getXMLKey(); XMLValue getXMLValue(); Object getKey(); Object getValue(); void setKey(final Object k); void setValue(final Object v); void setKey(final XMLKey k); void setValue(final XMLValue v); static void main(final String[] argv); static final String THISTAG; }