public final class DOMXMLParser extends PropertyListParser
NSObjects| Modifier and Type | Field and Description |
|---|---|
protected javax.xml.parsers.DocumentBuilder |
db
The DocumentBuilder
|
protected static javax.xml.parsers.DocumentBuilderFactory |
dbf
The DocumentBuilderFactory
|
protected org.w3c.dom.Document |
doc
The XML document
|
static java.lang.String |
DTD
DTD obtained from http://www.apple.com/DTDs/PropertyList-1.0.dtd, with comments removed
|
protected PropertyListException |
pleResult
The exception indicating why parsing failed
|
protected NSObject |
result
The parse result
|
file, input| Constructor and Description |
|---|
DOMXMLParser(java.io.File file) |
DOMXMLParser(java.io.InputStream input) |
| Modifier and Type | Method and Description |
|---|---|
NSObject |
parse()
Parse the Property List input (provided in the constructor) to a tree of
NSObjects |
protected static NSArray |
parseArray(org.w3c.dom.Node node)
Convert a node to an NSArray
|
protected static NSBoolean |
parseBoolean(org.w3c.dom.Node node)
Convert a node to an NSDictionary
|
protected static NSData |
parseData(org.w3c.dom.Node node)
Convert a node to an NSDictionary
|
protected static NSDate |
parseDate(org.w3c.dom.Node node)
Convert a node to an NSDictionary
|
protected static NSDictionary |
parseDictionary(org.w3c.dom.Node node)
Convert a node to an NSDictionary
|
protected static java.lang.String |
parseKey(org.w3c.dom.Node node)
Convert a node to a key
|
protected static NSObject |
parseNode(org.w3c.dom.Node node)
Convert a node to an NSObject
|
protected static NSNumber |
parseNumber(org.w3c.dom.Node node)
Convert a node to an NSNumber
|
protected static NSString |
parseString(org.w3c.dom.Node node)
Convert a node to an NSString
|
parse, parseprotected org.w3c.dom.Document doc
protected static final javax.xml.parsers.DocumentBuilderFactory dbf
protected final javax.xml.parsers.DocumentBuilder db
protected NSObject result
protected PropertyListException pleResult
public static final java.lang.String DTD
public DOMXMLParser(java.io.File file)
throws java.io.IOException,
PropertyListException
java.io.IOExceptionPropertyListExceptionPropertyListParser.parse(File)public DOMXMLParser(java.io.InputStream input)
throws java.io.IOException,
PropertyListException
java.io.IOExceptionPropertyListExceptionPropertyListParser.PropertyListParser(InputStream)public NSObject parse() throws PropertyListException
NSObjectsparse in class PropertyListParserNSObject of the parsed Property ListPropertyListException - when parsing the Property List failedprotected static NSObject parseNode(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSArray parseArray(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSDictionary parseDictionary(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSBoolean parseBoolean(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSData parseData(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSDate parseDate(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSNumber parseNumber(org.w3c.dom.Node node) throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static java.lang.String parseKey(org.w3c.dom.Node node)
throws PropertyListException
node - the node to parsePropertyListException - when parsing failsprotected static NSString parseString(org.w3c.dom.Node node)
node - the node to parsePropertyListException - when parsing fails