I'm trying to declare a variable in my flow following the documentation, using
<var name="myVar" class="int" />
However, Eclipse highlights the var
as an error, and I get a parser exception when running the flow (either from within Eclipse or from a standalone jar):
org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'var'. One of '{"http://ift.tt/1jwD1YA":input, "http://ift.tt/1jwD1YA":on-start, "http://ift.tt/1jwD1YA":action-state, "http://ift.tt/1jwD1YA":view-state, "http://ift.tt/1jwD1YA":decision-state, "http://ift.tt/1jwD1YA":subflow-state, "http://ift.tt/1jwD1YA":end-state, "http://ift.tt/1jwD1YA":global-transitions, "http://ift.tt/1jwD1YA":on-end, "http://ift.tt/1jwD1YA":output, "http://ift.tt/1jwD1YA":exception-handler, "http://ift.tt/1jwD1YA":bean-import}' is expected.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:134)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:437)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:368)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:325)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(XMLSchemaValidator.java:458)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.reportSchemaError(XMLSchemaValidator.java:3237)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:1796)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.emptyElement(XMLSchemaValidator.java:766)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:356)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2786)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:117)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:243)
at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:348)
at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121)
at org.springframework.webflow.engine.model.builder.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:113)
at org.springframework.webflow.engine.model.builder.xml.XmlFlowModelBuilder.init(XmlFlowModelBuilder.java:112)
I'm using the latest XSD:
<flow xmlns="http://ift.tt/1jwD1YA"
xmlns:xsi="http://ift.tt/ra1lAU"
xsi:schemaLocation="http://ift.tt/1jwD1YA
http://ift.tt/1pZXDNv">
and I've verified that the 2.4 XSD both on the Spring server and in the jar do in fact contain the definition for the var
element, right along with input
, on-start
, and the other working elements.
Any idea what may be the problem?
Aucun commentaire:
Enregistrer un commentaire