You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by ro...@apache.org on 2007/06/14 21:48:00 UTC

svn commit: r547380 - in /incubator/tuscany/cpp/sdo/runtime/core: src/commonj/sdo/SDOXMLWriter.cpp test/noschema.xml test/sdotest2.cpp

Author: robbinspg
Date: Thu Jun 14 12:47:59 2007
New Revision: 547380

URL: http://svn.apache.org/viewvc?view=rev&rev=547380
Log:
Don't use commonj.sdo namespace when serializing an OpenDataObject

Added:
    incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml   (with props)
Modified:
    incubator/tuscany/cpp/sdo/runtime/core/src/commonj/sdo/SDOXMLWriter.cpp
    incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp

Modified: incubator/tuscany/cpp/sdo/runtime/core/src/commonj/sdo/SDOXMLWriter.cpp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/src/commonj/sdo/SDOXMLWriter.cpp?view=diff&rev=547380&r1=547379&r2=547380
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/src/commonj/sdo/SDOXMLWriter.cpp (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/src/commonj/sdo/SDOXMLWriter.cpp Thu Jun 14 12:47:59 2007
@@ -133,7 +133,10 @@
                 SDOXMLString elementURI = doc->getRootElementURI();
                 if (elementURI.isNull() || elementURI.equals(""))
                 {
-                    elementURI = rootTypeURI;
+                    if (!rootTypeURI.equals(s_commonjsdo))
+                    {
+                        elementURI = rootTypeURI;
+                    }
                 }
                 SDOXMLString elementName = doc->getRootElementName();
                 if (elementName.isNull() || elementName.equals(""))

Added: incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml?view=auto&rev=547380
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml (added)
+++ incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml Thu Jun 14 12:47:59 2007
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<StockQuotes xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><Stock fred="joe"><Symbol>IBM</Symbol><Last>79.78</Last><Date>5/24/2006</Date><Time>4:01pm</Time><Change>0.00</Change><Open>N/A</Open><High>N/A</High><Low>N/A</Low><Volume>900</Volume><MktCap>123.7B</MktCap><PreviousClose>79.78</PreviousClose><PercentageChange>0.00</PercentageChange><AnnRange>73.45 - 89.94</AnnRange><Earns>5.121</Earns><P-E>15.58</P-E><Name>INTL BUSINESS MAC</Name></Stock></StockQuotes>

Propchange: incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/cpp/sdo/runtime/core/test/noschema.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp?view=diff&rev=547380&r1=547379&r2=547380
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp Thu Jun 14 12:47:59 2007
@@ -1898,9 +1898,10 @@
     try {
         XMLHelperPtr xmh = HelperProvider::getXMLHelper();
 
-        XMLDocumentPtr doc = xmh->loadFile("stock.wsdl");
+        XMLDocumentPtr doc = xmh->loadFile("pete.xml");
+        xmh->save(doc, "noschemaout.xml");
+        return comparefiles("noschemaout.xml" ,"noschema.xml");
 
-        return 1;
     }
     catch (SDORuntimeException e)
     {



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org