xerces

XercesDOMParser and XIncludes

徘徊边缘 提交于 2019-12-10 18:16:02
问题 I am attempting to get xincludes working in an existing system that uses a XercesDOMParser in xercesc to parse incoming xml from a client. I am working with Apache Xercesc v3.0.1, and the incoming XML, read from an input stream, is: <?xml version="1.0" encoding="UTF-8"?> <VisionServer xmlns:xi="http://www.w3.org/2001/XInclude"> <CompositeObject> <xi:include href="testguioutput.xml" /> while testguioutput.xml contains <?xml version="1.0" encoding="UTF-8"?> <GUIOutput> <Input>Input</Input>

Locale specific messages in Xerces 2.11.0 (Java)

倖福魔咒の 提交于 2019-12-10 09:58:17
问题 I want to use locale specific error messages with my JAXP and Xerces2. By default only English messages are available. First step is to retrieve the messages files and put them into the package "org/apache/xerces/impl/msg/" - done. By using Locale.setDefault (Locale.GERMANY) the German messages are displayed so this is working. But I want the messages to be differently localized on a per-instance basis. So one parser should return English messages and another parser should return German

I have UTF-8 - but still get “Invalid byte 1 of 1-byte UTF-8 sequence”

徘徊边缘 提交于 2019-12-10 04:23:06
问题 I create a XML String on the fly (NOT reading from a file). Then I use Cocoon 3 to transform it via FOP to a PDF. Somewhere in the middle Xerces runs. When I use the hardcoded stuff everything works. As soon as I put a german Umlaut into the database and enrich my xml with that data I get: Caused by: org.apache.cocoon.pipeline.ProcessingException: Can't parse the XML string. at org.apache.cocoon.sax.component.XMLGenerator$StringGenerator.execute(XMLGenerator.java:326) at org.apache.cocoon.sax

Apache Hadoop setXIncludeAware UnsupportedOperationException

血红的双手。 提交于 2019-12-10 01:59:17
问题 I'm trying to get Apache Hadoop 1.21 running, but I'm getting this exception: Failed to set setXIncludeAware(true) for parser org.apache.xerces.jaxp.DocumentBuilderFactoryImpl org.apache.xerces.jaxp.DocumentBuilderFactoryImpl@2662e5cf:java.lang.UnsupportedOperationException full stack trace: 13/10/17 17:22:52 ERROR conf.Configuration: Failed to set setXIncludeAware(true) for parser org.apache.xerces.jaxp.DocumentBuilderFactoryImpl@2662e5cf:java.lang.UnsupportedOperationException:

libxml2 from java

此生再无相见时 提交于 2019-12-09 17:09:21
问题 This question is somewhat related to Fastest XML parser for small, simple documents in Java but with a few more specifics. I'm working on an application which needs to parse many (10s of millions), small (approx. 300k) xml documents. The current implementation is using xerces-j and it takes about 2.5 ms per xml document on a 1.5 GHz machine. I'd like to improve this performance. I came across this article http://www.xml.com/pub/a/2007/05/16/xml-parser-benchmarks-part-2.html claiming that

Sonar Xerces conflict Findbugs and ivy:report

扶醉桌前 提交于 2019-12-09 16:27:53
问题 I am trying to get sonar to work for a project with a quality profile that includes Findbugs rules. However when analyzing the project the sonar anttask chrashes with the following error: Caused by: java.io.IOException: SAX2 driver class org.apache.xerces.parsers.SAXParser not found at edu.umd.cs.findbugs.filter.Filter.<init>(Filter.java:134) at edu.umd.cs.findbugs.FindBugs.configureFilter(FindBugs.java:516) at edu.umd.cs.findbugs.FindBugs2.addFilter(FindBugs2.java:374) at org.sonar.plugins

XML validation against XSD 1.1 with Xerces in Java

僤鯓⒐⒋嵵緔 提交于 2019-12-09 02:59:02
问题 I have installed Xerces through Maven: <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.11</version> <scope>test</scope> </dependency> <dependency> <groupId>org.jdom</groupId> <artifactId>jdom</artifactId> <version>2.0.2</version> </dependency> <dependency> <groupId>xerces</groupId> <artifactId>xercesImpl</artifactId> <version>2.11.0</version> </dependency> </dependencies> I then tried the code given in this example from the Xerces FAQ to validate

Xerces C++ - Load, read and save, alternatives?

空扰寡人 提交于 2019-12-08 18:01:03
问题 I'm searching for a tutorial to load a XML file, read it, change it and finally save it with C++. I'm using Linux Ubuntu and tried to use Xerces. With Google and much time, I could only load an XML File: #include <xercesc/parsers/XercesDOMParser.hpp> #include <xercesc/dom/DOM.hpp> #include <xercesc/sax/HandlerBase.hpp> #include <xercesc/util/XMLString.hpp> #include <xercesc/util/PlatformUtils.hpp> #include <iostream> using namespace std; using namespace xercesc; int main (int argc, char* args

Xml node text is causing issues when it has funny characters

血红的双手。 提交于 2019-12-08 14:19:59
问题 I'm setting the characters inside the xml element in the following event: public void characters(char[] ch, int start, int length) { elementText = new String(ch, start, length); } Where elementText is a String. <client-key>#<ABC::DEF::GHI:0x102548f78></client-key> I am loading this xml data into java objects, and my objects property has this value: '\n ' Now if I change the text in the element <client-key> above, it comes out fine in my objects property. Is there some encoding issue that I

WARNING: unrecognized options: --disable-netaccessor-libcurl

孤街浪徒 提交于 2019-12-08 00:20:31
I am trying to install Xerces-C to my Shibboleth 2 SP following this guide: https://wiki.shibboleth.net/confluence/display/SHIB2/NativeSPLinuxSourceBuild But when i run: ./configure --prefix=/opt/shibboleth-sp --disable-netaccessor-libcurl i get this warning: WARNING: unrecognized options: --disable-netaccessor-libcurl [...] config.status: creating src/xercesc/util/Xerces_autoconf_config.hpp config.status: src/xercesc/util/Xerces_autoconf_config.hpp is unchanged config.status: executing depfiles commands config.status: executing libtool commands config.status: executing libtool-rpath-patch