com.infoengine.object
Class XML
java.lang.Object
com.infoengine.object.XML
- public class XML
- extends Object
Constructor Summary |
XML()
|
Method Summary |
static String |
byteToHex(byte[] rawBytes)
|
static byte[] |
hexToByte(String s)
|
static String |
hexToUnicode(String s)
|
static String |
javaToXML(Object o,
int type)
|
static String |
javaToXML(Object o,
int type,
boolean includeMeta)
|
static int |
javaType(Object o)
|
static String |
normalizeXml(String s)
|
static void |
printType(PrintWriter output,
int type,
Object o)
|
private static String |
serializeObject(Object o)
|
static String |
spaces(int level,
boolean readable)
|
static void |
toXML(IeObject o,
boolean dtdOrNo,
boolean readable,
String dtdPath,
PrintWriter pw,
String encoding,
boolean newVersion,
boolean reply)
|
static void |
toXMLAtts(IeObject o,
int level,
PrintWriter pw,
boolean readable,
Hashtable attValues)
|
static void |
toXMLChildren(IeObject o,
int level,
PrintWriter pw,
boolean readable,
Hashtable attValues)
|
static void |
toXMLDatum(IeDatum d,
int level,
PrintWriter pw,
boolean readable)
|
static void |
toXMLHelper(IeObject o,
int level,
PrintWriter pw,
boolean readable,
Hashtable attValues)
|
static void |
toXMLMetas(IeObject o,
int level,
PrintWriter pw)
|
static void |
toXMLMetas(IeObject o,
int level,
PrintWriter pw,
boolean readable)
|
static boolean |
validTag(String s)
|
static IeDatum |
xmlToJava(Object o,
int type)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UTF8
public static final String UTF8
- See Also:
- Constant Field Values
USASCII
public static final String USASCII
- See Also:
- Constant Field Values
Version
public static final String Version
- See Also:
- Constant Field Values
REPLY
public static boolean REPLY
hByte
static final byte[] hByte
NAME_SPACE
public static final String NAME_SPACE
- See Also:
- Constant Field Values
NAME_SPACE_TAG
public static final String NAME_SPACE_TAG
- See Also:
- Constant Field Values
NAME_SPACE_VALUE
public static final String NAME_SPACE_VALUE
- See Also:
- Constant Field Values
START_ATT_TAG
private static final String START_ATT_TAG
- See Also:
- Constant Field Values
STOP_ATT_TAG
private static final String STOP_ATT_TAG
- See Also:
- Constant Field Values
STOP_TAG
private static final String STOP_TAG
- See Also:
- Constant Field Values
START_TAG
private static final String START_TAG
- See Also:
- Constant Field Values
END_TAG
private static final String END_TAG
- See Also:
- Constant Field Values
START_DATUM_TAG
private static final String START_DATUM_TAG
- See Also:
- Constant Field Values
STOP_DATUM_TAG
private static final String STOP_DATUM_TAG
- See Also:
- Constant Field Values
START_META_TAG
private static final String START_META_TAG
- See Also:
- Constant Field Values
STOP_META_TAG
private static final String STOP_META_TAG
- See Also:
- Constant Field Values
COLLECTION_TAG
private static final String COLLECTION_TAG
- See Also:
- Constant Field Values
OBJECT
public static final int OBJECT
- See Also:
- Constant Field Values
NUMBER
public static final int NUMBER
- See Also:
- Constant Field Values
STRING
public static final int STRING
- See Also:
- Constant Field Values
DATE
public static final int DATE
- See Also:
- Constant Field Values
BYTE_ARRAY
public static final int BYTE_ARRAY
- See Also:
- Constant Field Values
TIMESTAMP
public static final int TIMESTAMP
- See Also:
- Constant Field Values
IDENTIFIER
public static final int IDENTIFIER
- See Also:
- Constant Field Values
ELEMENT
public static final int ELEMENT
- See Also:
- Constant Field Values
TYPE_INSTANCE
public static final int TYPE_INSTANCE
- See Also:
- Constant Field Values
GROUP
public static final int GROUP
- See Also:
- Constant Field Values
BOOLEAN
public static final int BOOLEAN
- See Also:
- Constant Field Values
counter
private static int counter
elementClass
private static Class elementClass
elementConstructor
private static Constructor elementConstructor
elementMethodToXML
private static Method elementMethodToXML
groupClass
private static Class groupClass
groupMethodToXML
private static Method groupMethodToXML
XML
public XML()
javaType
public static int javaType(Object o)
javaToXML
public static String javaToXML(Object o,
int type)
javaToXML
public static String javaToXML(Object o,
int type,
boolean includeMeta)
serializeObject
private static String serializeObject(Object o)
throws IOException
- Throws:
IOException
xmlToJava
public static IeDatum xmlToJava(Object o,
int type)
toXMLMetas
public static void toXMLMetas(IeObject o,
int level,
PrintWriter pw)
toXMLMetas
public static void toXMLMetas(IeObject o,
int level,
PrintWriter pw,
boolean readable)
toXMLAtts
public static void toXMLAtts(IeObject o,
int level,
PrintWriter pw,
boolean readable,
Hashtable attValues)
toXMLDatum
public static void toXMLDatum(IeDatum d,
int level,
PrintWriter pw,
boolean readable)
toXMLChildren
public static void toXMLChildren(IeObject o,
int level,
PrintWriter pw,
boolean readable,
Hashtable attValues)
toXMLHelper
public static void toXMLHelper(IeObject o,
int level,
PrintWriter pw,
boolean readable,
Hashtable attValues)
toXML
public static void toXML(IeObject o,
boolean dtdOrNo,
boolean readable,
String dtdPath,
PrintWriter pw,
String encoding,
boolean newVersion,
boolean reply)
normalizeXml
public static String normalizeXml(String s)
validTag
public static boolean validTag(String s)
spaces
public static String spaces(int level,
boolean readable)
byteToHex
public static String byteToHex(byte[] rawBytes)
hexToByte
public static byte[] hexToByte(String s)
hexToUnicode
public static String hexToUnicode(String s)
printType
public static void printType(PrintWriter output,
int type,
Object o)