{
XmlOptions ltgOptions = new XmlOptions();
ltgOptions.setLoadSubstituteNamespaces(Collections.singletonMap("", "http://www.bea.com/2003/05/xmlbean/ltgfmt"));
ltgOptions.setErrorListener(errors);
ltgOptions.setLoadLineNumbers();
TestsDocument doc = TestsDocument.Factory.parse(ltgFile, ltgOptions);
if (!doc.validate(ltgOptions))
throw new Exception("Document " + ltgFile + " not valid.");
com.bea.x2003.x05.xmlbean.ltgfmt.TestCase[] testCases = doc.getTests().getTestArray();
Collection result = new ArrayList();
for (int i = 0; i < testCases.length; i++)
{
TestCase newCase = new TestCase();