WPS UOM Parsing
---------------
Key: GEOT-3159
URL: http://jira.codehaus.org/browse/GEOT-3159
Project: GeoTools
Issue Type: Bug
Components: core xml
Reporter: Jody Garnett
Assignee: Ben Caradoc-Davies
Fix For: 2.7-RC1
The wps module is failing its ParsingTest.testDescribeProcessParsing - I expect
testing must be turned off at the pom level?
The failure is as follows:
{noformat}
java.lang.RuntimeException: Parsing failed for Supported:
java.lang.RuntimeException: Unable to set property: UOM for eobject:
{http://www.opengis.net/wps/1.0.0}UOMsType
at org.geotools.xml.impl.ParseExecutor.visit(ParseExecutor.java:158)
at
org.geotools.xml.impl.BindingWalker$BindingExecutionChain.execute(BindingWalker.java:215)
at org.geotools.xml.impl.BindingWalker.walk(BindingWalker.java:181)
at
org.geotools.xml.impl.ElementHandlerImpl.endElement(ElementHandlerImpl.java:223)
at
org.geotools.xml.impl.ParserHandler.endElement(ParserHandler.java:607)
at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown
Source)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.geotools.xml.Parser.parse(Parser.java:223)
at org.geotools.xml.Parser.parse(Parser.java:169)
at
org.geotools.data.wps.ParsingTest.testDescribeProcessParsing(ParsingTest.java:69)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:592)
at junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:232)
at junit.framework.TestSuite.run(TestSuite.java:227)
at
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:81)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.RuntimeException: Unable to set property: UOM for eobject:
{http://www.opengis.net/wps/1.0.0}UOMsType
at
org.geotools.xml.AbstractComplexEMFBinding.setProperty(AbstractComplexEMFBinding.java:286)
at
org.geotools.xml.AbstractComplexEMFBinding.setProperties(AbstractComplexEMFBinding.java:204)
at
org.geotools.xml.AbstractComplexEMFBinding.parse(AbstractComplexEMFBinding.java:145)
at org.geotools.xml.impl.ParseExecutor.visit(ParseExecutor.java:149)
... 34 more
Caused by: java.lang.ClassCastException: javax.measure.unit.BaseUnit
at org.eclipse.emf.ecore.util.EcoreEList.contains(EcoreEList.java:364)
at
org.eclipse.emf.common.util.BasicEList.getNonDuplicates(BasicEList.java:1908)
at org.eclipse.emf.common.util.BasicEList.addAll(BasicEList.java:686)
at org.geotools.xml.EMFUtils.add(EMFUtils.java:95)
at
org.geotools.xml.AbstractComplexEMFBinding.setProperty(AbstractComplexEMFBinding.java:232)
... 37 more
{noformat}
As usual parsing problems are an enigma wrapped in a RuntimeException. There is
an impedance mismatch between using an EMF generated Bean (and allowing eSet to
fill in the blanks) vs being able to use our own java bindings.
In this particular case UOM is probably trying to be represented as a Unit
class.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel