xml2class
XML data structures
I M P S T U X

I

invokeMethod(Object, String) - Static method in class xml2class.X2cTools
Allows to invoke any (parameterless) method for any object.

M

main(String[]) - Static method in class xml2class.XMLFile
Allows to parse from the command line a XML file, which should contain also instructions on how to proceed when the parsing process is complete. Syntax: XMLFile [directory/filename.xml] [package.name] [verbose].

P

parse(Reader) - Method in class xml2class.XML2ClassParser
Parses a data structure by extracting data from the Reader, beginning with the first instance of the first element, which is found.
parse(Reader, String) - Method in class xml2class.XML2ClassParser
Parses a data structure by extracting data from the Reader, beginning with the first instance of the indicated element which is found. The reader should be buffered (it must support mark/reset).
parse(String, String) - Static method in class xml2class.XMLFile
Parse directly a whole structure from a file.
parse(String, String[], boolean, boolean) - Static method in class xml2class.XMLFile
Parse directly a whole structure from a (resource) file.
parse(String, String, boolean) - Static method in class xml2class.XMLFile
Parse directly a whole structure from a file.
parseResource(String, String) - Static method in class xml2class.XMLFile
Parse directly a whole structure from a resource file.
parseResource(String, String, boolean) - Static method in class xml2class.XMLFile
Parse directly a whole structure from a resource file.
printPackageInfo(PrintWriter) - Static method in class xml2class.XML2ClassParser
Writes the package's version and copyleft to a PrintWriter.

S

save(Object, String) - Static method in class xml2class.XMLFile
Save the data structure - given its root element - back to a file.
save(Object, String, String) - Static method in class xml2class.XMLFile
Save the data structure - given its root element - back to a file.
save(String, String, String, boolean) - Static method in class xml2class.XMLFile
Save the data structure - given its XML representation - back to a (resource) file.
saveResource(Object, String) - Static method in class xml2class.XMLFile
Save the data structure - given its root element - back to a resource file.
saveResource(Object, String, String) - Static method in class xml2class.XMLFile
Save the data structure - given its root element - back to a resource file.
setVerbose(PrintWriter) - Method in class xml2class.XML2ClassParser
Sets the parser's verbose output destination (null = not verbose).
stripClassPath(String) - Static method in class xml2class.X2cTools
Removes any path information from a class name.

T

toEntityString(String) - Static method in class xml2class.X2cTools
Returns the same string, but with any entity character encoded as XML entity (e.g.
tokensToArray(String) - Static method in class xml2class.X2cTools
Transforms a token-string into a string array.
tokensToArray(String, String) - Static method in class xml2class.X2cTools
Transforms a token-string into a string array.
toXMLString() - Method in interface xml2class.XMLSaveable
Produces a XML representation of the implementing object.
toXMLString(Object) - Static method in class xml2class.X2cTools
Converts any element into an XML string, at the condition that it provides a toXMLString() method.

U

upperCaseFirstLetter(String) - Static method in class xml2class.X2cTools
Capitalizes the first character.

X

X2cClassBuildingException - exception xml2class.X2cClassBuildingException.
This exception is thrown when one of the XML elements or attributes did not correspond to an already present class or method, so that Java couldn't build that object. Any ClassNotFoundException, NoSuchMethodException, InstantiationException, IllegalAccessException and InvocationTargetException will be converted to a X2cClassBuildingException.
X2cClassBuildingException() - Constructor for class xml2class.X2cClassBuildingException
Constructs an X2cClassBuildingException with no specified detail message.
X2cClassBuildingException(String) - Constructor for class xml2class.X2cClassBuildingException
Constructs an X2cClassBuildingException with the specified detail message.
X2cException - exception xml2class.X2cException.
This exception class is superclass of any exception thrown by xml2class.
X2cException() - Constructor for class xml2class.X2cException
Constructs an X2cException with no specified detail message.
X2cException(String) - Constructor for class xml2class.X2cException
Constructs an X2cException with the specified detail message.
X2cInputException - exception xml2class.X2cInputException.
Any IOException occuring during the parsing process will be converted into a X2cInputException in order to facilitate exception handling.
X2cInputException() - Constructor for class xml2class.X2cInputException
Constructs an X2cInputException with no specified detail message.
X2cInputException(String) - Constructor for class xml2class.X2cInputException
Constructs an X2cInputException with the specified detail message.
X2cInvalidTagException - exception xml2class.X2cInvalidTagException.
This exception is thrown when a tag or an entity is invalid (bad syntax).
X2cInvalidTagException() - Constructor for class xml2class.X2cInvalidTagException
Constructs an X2cInvalidTagException with no specified detail message.
X2cInvalidTagException(String) - Constructor for class xml2class.X2cInvalidTagException
Constructs an X2cInvalidTagException with the specified detail message.
X2cOutputException - exception xml2class.X2cOutputException.
An X2cOutputException is thrown, when there was any exception while trying to save a data structure back to a XML file.
X2cOutputException() - Constructor for class xml2class.X2cOutputException
Constructs an X2cOutputException with no specified detail message.
X2cOutputException(String) - Constructor for class xml2class.X2cOutputException
Constructs an X2cOutputException with the specified detail message.
X2cTagException - exception xml2class.X2cTagException.
This exception is thrown when an (end)tag is missing or when there was an unexpected or unknown tag or entity. When this exception is thrown, it usually is a sign for not well-formed / valid XML.
X2cTagException() - Constructor for class xml2class.X2cTagException
Constructs an X2cTagException with no specified detail message.
X2cTagException(String) - Constructor for class xml2class.X2cTagException
Constructs an X2cTagException with the specified detail message.
X2cTools - class xml2class.X2cTools.
This class provides some utility methods for the whole xml2class package.
X2cTools() - Constructor for class xml2class.X2cTools
 
xml2class - package xml2class
Provides you with a simple XML parser, which instantiates data structures written in Java out of a XML description (and supports storing them back as XML code).
XML2ClassParser - class xml2class.XML2ClassParser.
The XML2ClassParser extracts data about a present data structure (i.e. it must already be implemented) out of XML code and instantiates a new instance of it with the values available from an XML source.
XML2ClassParser() - Constructor for class xml2class.XML2ClassParser
Creates a new XML2ClassParser.
XML2ClassParser(String) - Constructor for class xml2class.XML2ClassParser
Creates a new XML2ClassParser for the given classpath(s).
XML2ClassParser(String[]) - Constructor for class xml2class.XML2ClassParser
Creates a new XML2ClassParser for the given classpath(s).
XMLFile - class xml2class.XMLFile.
An auxiliary class for XML file handling.
XMLFile() - Constructor for class xml2class.XMLFile
 
XMLSaveable - interface xml2class.XMLSaveable.
For convenience reasons, any class which is able to describe itself in XML (in order to be written to a file) may implement this interface.

I M P S T U X
xml2class
XML data structures

Copyleft 2001 by Simon Bünzli, zeniko@gmx.ch