@Test public void testDump() throws Throwable { PrintStream p = new PrintStream(new ByteArrayOutputStream(), true); new ISOField(100, "testISOFieldv").dump(p, "testISOFieldIndent"); assertTrue(true, "Test completed without Exception"); }
@Override public void dump (PrintStream p, String indent) { if (value != null) { if (value.indexOf('<') >= 0) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else if (value.startsWith("{")) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else { p.println(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\" " + XMLPackager.VALUE_ATTR + "=\"" + ISOUtil.normalize(value) + "\"/>"); } } }
ISOField extends ISOComponent implements Cloneable, Externalizable { @Override public void dump (PrintStream p, String indent) { if (value != null) { if (value.indexOf('<') >= 0) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else if (value.startsWith("{")) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else { p.println(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\" " + XMLPackager.VALUE_ATTR + "=\"" + ISOUtil.normalize(value) + "\"/>"); } } } }
ISOField extends ISOComponent implements Cloneable, Externalizable { @Override public void dump (PrintStream p, String indent) { if (value != null) { if (value.indexOf('<') >= 0) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else if (value.startsWith("{")) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else { p.println(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\" " + XMLPackager.VALUE_ATTR + "=\"" + ISOUtil.normalize(value) + "\"/>"); } } } ISOField();  ISOField(int n);  ISOField(int n, String v); }
ISOField extends ISOComponent implements Cloneable, Externalizable { @Override public void dump (PrintStream p, String indent) { if (value != null) { if (value.indexOf('<') >= 0) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else if (value.startsWith("{")) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else { p.println(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\" " + XMLPackager.VALUE_ATTR + "=\"" + ISOUtil.normalize(value) + "\"/>"); } } } ISOField();  ISOField(int n);  ISOField(int n, String v); @Override byte[] pack(); @Override int unpack(byte[] b); @Override void unpack(InputStream in); @Override Object getKey(); @Override Object getValue(); @Override void setValue(Object obj); @Override byte[] getBytes(); @Override void dump(PrintStream p, String indent); @Override void setFieldNumber(int fieldNumber); @Override int getFieldNumber(); @Override void writeExternal(ObjectOutput out); @Override void readExternal(ObjectInput in); }
ISOField extends ISOComponent implements Cloneable, Externalizable { @Override public void dump (PrintStream p, String indent) { if (value != null) { if (value.indexOf('<') >= 0) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else if (value.startsWith("{")) { p.print(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\"><![CDATA["); p.print(value); p.println("]]></" + XMLPackager.ISOFIELD_TAG + ">"); } else { p.println(indent + "<" + XMLPackager.ISOFIELD_TAG + " " + XMLPackager.ID_ATTR + "=\"" + fieldNumber + "\" " + XMLPackager.VALUE_ATTR + "=\"" + ISOUtil.normalize(value) + "\"/>"); } } } ISOField();  ISOField(int n);  ISOField(int n, String v); @Override byte[] pack(); @Override int unpack(byte[] b); @Override void unpack(InputStream in); @Override Object getKey(); @Override Object getValue(); @Override void setValue(Object obj); @Override byte[] getBytes(); @Override void dump(PrintStream p, String indent); @Override void setFieldNumber(int fieldNumber); @Override int getFieldNumber(); @Override void writeExternal(ObjectOutput out); @Override void readExternal(ObjectInput in);  }