From: Raif S. N. <ra...@fo...> - 2006-11-07 23:12:41
|
hello there, i'm trying to parse the WFS capabilities document returned by a GeoServer 1.4.0-RC2, using the following dependencies and code: * ... <dependency> <groupId>org.geotools</groupId> <artifactId>gt2-main</artifactId> <version>2.2.1</version> </dependency> ... <dependency> <groupId>xerces</groupId> <artifactId>xercesImpl</artifactId> <version>2.8.0</version> </dependency> * ... File out = ... Object obj = DocumentFactory.getInstance(out.toURI(), /* hints */ null); when running the above in a JUnit test i get: SEVERE: Could not find element handler for http://www.opengis.net/wfs : SHAPE-ZIP as a child of ResultFormatType. org.geotools.xml.handlers.ComplexElementHandler.getHandler(ComplexElementHandler.java:569) org.geotools.xml.XMLSAXHandler.startElement(XMLSAXHandler.java:377) org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source) org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source) org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source) org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) org.apache.xerces.parsers.XMLParser.parse(Unknown Source) org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source) javax.xml.parsers.SAXParser.parse(SAXParser.java:255) org.geotools.xml.DocumentFactory.getInstance(DocumentFactory.java:109) org.geotools.xml.DocumentFactory.getInstance(DocumentFactory.java:82) ... the problematic line in the xml capabilities document seems to be the fourth line in the "GetFeature" element: <GetFeature> <ResultFormat> <GML2/> <GML2-GZIP/> <SHAPE-ZIP/> </ResultFormat> ... </GetFeature> is it something wrong i'm doing (or right i'm not doing ;-) or is this a known problem? TIA + cheers; rsn |