pConfig.getErrorHandlers().put(Integer.parseInt(oCodeNode.getNodeValue()), oHandler);
}
private void readMapping(Node pNode, RewriterConfiguration pConfig) throws ConfigurationException {
Node oNameNode = ParserHelper.getAttribute(pNode, Constants.ATTR_NAME, true);
StringDictionnary oMap = new StringDictionnary();
for (int i = 0; i < pNode.getChildNodes().getLength(); i++) {
Node oNode = pNode.getChildNodes().item(i);
if (Constants.ELEMENT_MAP.equals(oNode.getNodeName()) && oNode.getNodeType() == Node.ELEMENT_NODE) {
Node oFromValueNode = ParserHelper.getAttribute(oNode, Constants.ATTR_FROM, true);
Node oToValueNode = ParserHelper.getAttribute(oNode, Constants.ATTR_TO, true);
oMap.put(oFromValueNode.getNodeValue(), oToValueNode.getNodeValue());
} else if (oNode.getNodeType() != Node.TEXT_NODE){
throw new ConfigurationException(String.format(Messages.ELEMENT_NOTALLOWED, oNode.getNodeName()));
}
}
pConfig.getTransformFactory().addTransform(new StaticMappingTransform(oNameNode.getNodeValue(), oMap));