Skip to main content

Strange Problem usingJAXP in GoogleAppEngine

No replies
bitliner
Offline
Joined: 2011-03-19
Points: 0

I explain my problem:
i have this code:
// code
XMLReader xr = XMLReaderFactory.createXMLReader();
xr.setContentHandler(myObjectImporter);
xr.parse(new InputSource(new FileReader("db-at-startup.xml")));
List<MyObject> videos=myObjectImporter.getMyObjects();
// end code
The execution is this:

  • xr.parse(new InputSource(new FileReader("db-at-startup.xml"))); is execute
  • List<MyObject> videos=myObjectImporter.getMyObjects(); is execute
  • then the program (i don't know why, as there isn't cycle) returns to execute the first point and second point above
  • then the program executes again the first point above ( xr.parse(new InputSource(new FileReader("db-at-startup.xml"))); )
  • and then the execution is completed, also there are some instruction after these above and it doesn't throw any expeption

Some help?