net.n3.nanoxml

Class XMLParserFactory

public class XMLParserFactory extends Object

Creates an XML parser.

Version: $Name: RELEASE_2_2_1 $, $Revision: 1.3 $

Author: Marc De Scheemaecker

Field Summary
static StringCLASS_KEY
The Java properties key of the XML parser class name.
static StringDEFAULT_CLASS
The class name of the default XML parser.
Method Summary
static IXMLParsercreateDefaultXMLParser()
Creates a default parser.
static IXMLParsercreateDefaultXMLParser(IXMLBuilder builder)
Creates a default parser.
static IXMLParsercreateXMLParser(String className, IXMLBuilder builder)
Creates a parser.

Field Detail

CLASS_KEY

public static final String CLASS_KEY
The Java properties key of the XML parser class name.

DEFAULT_CLASS

public static final String DEFAULT_CLASS
The class name of the default XML parser.

Method Detail

createDefaultXMLParser

public static IXMLParser createDefaultXMLParser()
Creates a default parser.

Returns: the non-null parser.

Throws: java.lang.ClassNotFoundException if the class of the parser or validator could not be found. java.lang.InstantiationException if the parser could not be created java.lang.IllegalAccessException if the parser could not be created

See Also: DEFAULT_CLASS CLASS_KEY

createDefaultXMLParser

public static IXMLParser createDefaultXMLParser(IXMLBuilder builder)
Creates a default parser.

Parameters: builder the XML builder.

Returns: the non-null parser.

Throws: java.lang.ClassNotFoundException if the class of the parser could not be found. java.lang.InstantiationException if the parser could not be created java.lang.IllegalAccessException if the parser could not be created

See Also: DEFAULT_CLASS CLASS_KEY

createXMLParser

public static IXMLParser createXMLParser(String className, IXMLBuilder builder)
Creates a parser.

Parameters: className the name of the class of the XML parser builder the XML builder.

Returns: the non-null parser.

Throws: java.lang.ClassNotFoundException if the class of the parser could not be found. java.lang.InstantiationException if the parser could not be created java.lang.IllegalAccessException if the parser could not be created