I gave this a try and I am still getting a MalformedURLException. Here's the part of the stack trace:
[2005-09-08 11:54:56 EDT] <WorkerThread13> com.webobjects.foundation.NSForwardException for java.net.MalformedURLException at java.net.URL.<init>(URL.java:571) at java.net.URL.<init>(URL.java:434) at java.net.URL.<init>(URL.java:383) at org.apache.xerces.impl.XMLEntityManager.startEntity(XMLEntityManager.java:807) at org.apache.xerces.impl.XMLEntityManager.startDocumentEntity(XMLEntityManager.java:753) at org.apache.xerces.impl.XMLDocumentScannerImpl.setInputSource(XMLDocumentScannerImpl.java:260) at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:499) at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:581) at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152) at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1114) at com.webobjects.appserver.xml._private._MappingModel.mappingModelWithXMLFile(_MappingModel.java:405) at com.webobjects.appserver.xml._private._WOXMLMappingDecoder.<init>(_WOXMLMappingDecoder.java:121) at com.webobjects.appserver.xml.WOXMLDecoder.decoderWithMapping(WOXMLDecoder.java:581) at XMLDecodeMachine.decodeXML(XMLDecodeMachine.java:25) at DirectAction.newOrderAction(DirectAction.java:47)
the XMLDecodeMachine.decodeXML method is here (with line 25 denoted):
public String decodeXML (String theXML) { mappingFile = application().resourceManager().pathForResourceNamed("OrderXMLModel.xml", null, null); NSData xmlData = new NSData(theXML, "UTF-8"); line 25 --> CustomBar custBar = (CustomBar)WOXMLDecoder.decoderWithMapping(mappingFile).decodeRootObject(xmlData); System.out.println(custBar); return "Done"; }
I don't understand why I am getting the malformedURLException...I'm passing in an NSData object which is acceptable. I AM CONFUSED here. It's just not making sense !!
Anybody shed light on this ?? |