public class NVPXmlHandler extends AbstractXmlHandler
<Inventories xmlns:_cat="http://www.ibm.com/xmlns/prod/commerce/9/catalog" xmlns:_inv="http://www.ibm.com/xmlns/prod/commerce/9/inventory" > <_inv:Inventory ProductPartNumber="TAPL-01" > <_cat:Item ItemPartNumber="TAPL-0101" > <Quantity>101</Quantity> </_cat:Item> <_cat:Item ItemPartNumber="TAPL-0102"> <Quantity>102</Quantity> </_cat:Item> </_inv:Inventory> </Inventories>It will build a map and the key is the name and the value is either a string or a list if there are multiple values for the same name.
Constructor and Description |
---|
NVPXmlHandler() |
Modifier and Type | Method and Description |
---|---|
void | characters(char[] chars, int start, int length)
Handle the characters event in the xml.
|
void | endElement(java.lang.String uri, java.lang.String localName, java.lang.String qName)
Handle the end element event in the xml.
|
void | init()
Initializes some instance variables.
|
void | startElement(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes attributes)
Handle the start element event in the xml.
|
public void characters(char[] chars, int start, int length) throws org.xml.sax.SAXException
public void startElement(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes attributes) throws org.xml.sax.SAXException
public void endElement(java.lang.String uri, java.lang.String localName, java.lang.String qName) throws org.xml.sax.SAXException
public void init() throws DataLoadException