Merge "Issue #1693 Fixing dependencies" into development

Former-commit-id: d7f63873c0 [formerly 1b223090e7] [formerly d7f63873c0 [formerly 1b223090e7] [formerly 1d2c4ea875 [formerly 9e6402a60994f17f3c8e61a2fc5ee3397c9f8da6]]]
Former-commit-id: 1d2c4ea875
Former-commit-id: 28aac73af0 [formerly 61a042cf41]
Former-commit-id: e77c439ef7
This commit is contained in:
Richard Peter 2013-08-21 16:33:22 -05:00 committed by Gerrit Code Review
commit cb4b5107ee
3 changed files with 9 additions and 13 deletions

View file

@ -34,8 +34,7 @@ Require-Bundle: com.raytheon.uf.common.registry.schemas.ebxml;bundle-version="1.
com.raytheon.uf.common.datadelivery.request;bundle-version="1.0.0",
javax.mail;bundle-version="1.0.0",
org.apache.commons.validator;bundle-version="1.2.0",
com.sun.xml.bind;bundle-version="1.0.0",
org.apache.commons.io;bundle-version="2.4.0"
com.sun.xml.bind;bundle-version="1.0.0"
Export-Package: com.raytheon.uf.edex.registry.ebxml.acp,
com.raytheon.uf.edex.registry.ebxml.dao,
com.raytheon.uf.edex.registry.ebxml.exception,

View file

@ -19,6 +19,7 @@
**/
package com.raytheon.uf.edex.registry.ebxml.util.xpath;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.StringWriter;
@ -26,6 +27,7 @@ import java.util.Collections;
import java.util.HashSet;
import java.util.Set;
import javax.xml.bind.JAXBElement;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
@ -41,7 +43,6 @@ import javax.xml.xpath.XPathFactory;
import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.MsgRegistryException;
import org.apache.commons.io.IOUtils;
import org.w3c.dom.Attr;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
@ -293,8 +294,8 @@ public class RegistryXPathProcessor {
Document domDocument = null;
InputStream stream = null;
try {
stream = IOUtils.toInputStream(jaxbManager
.marshalToXml(registryObject));
stream = new ByteArrayInputStream(jaxbManager.marshalToXml(
registryObject).getBytes("UTF-8"));
documentBuilder.reset();
domDocument = documentBuilder.parse(stream);
} catch (Exception e) {
@ -327,7 +328,9 @@ public class RegistryXPathProcessor {
try {
transformer.reset();
transformer.transform(new DOMSource(doc), result);
return jaxbManager.unmarshalFromXml(writer.toString());
return ((JAXBElement<?>) jaxbManager.unmarshalFromXml(writer
.toString())).getValue();
} catch (Exception e) {
throw new EbxmlRegistryException(
"Error converting object from dom", e);

View file

@ -16,7 +16,7 @@
<license url="http://www.example.com/license">
[Enter License Description here.]
</license>
<import feature="com.raytheon.uf.edex.registry.client.feature" version="1.0.0.qualifier"/>
<plugin
@ -33,10 +33,4 @@
version="0.0.0"
unpack="false"/>
<plugin
id="org.apache.commons.io"
download-size="0"
install-size="0"
version="0.0.0"/>
</feature>