tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From edslatt...@apache.org
Subject svn commit: r415260 - in /incubator/tuscany/cpp/sdo: projects/tuscany_sdo/ projects/tuscany_sdo/sdo_axiom/ runtime/core/sdo_axiom/ runtime/core/sdo_axiom_test/ runtime/core/test/
Date Mon, 19 Jun 2006 08:45:05 GMT
Author: edslattery
Date: Mon Jun 19 01:45:04 2006
New Revision: 415260

URL: http://svn.apache.org/viewvc?rev=415260&view=rev
Log:
Tuscany-478
Update to axis2-0.92

Modified:
    incubator/tuscany/cpp/sdo/projects/tuscany_sdo/sdo_axiom/sdo_axiom.dsp
    incubator/tuscany/cpp/sdo/projects/tuscany_sdo/tuscany_sdo.ncb
    incubator/tuscany/cpp/sdo/projects/tuscany_sdo/tuscany_sdo.opt
    incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.cpp
    incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.h
    incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom_test/sdo_axiom_test.cpp
    incubator/tuscany/cpp/sdo/runtime/core/test/main.cpp
    incubator/tuscany/cpp/sdo/runtime/core/test/sdotest.h
    incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp

Modified: incubator/tuscany/cpp/sdo/projects/tuscany_sdo/sdo_axiom/sdo_axiom.dsp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/projects/tuscany_sdo/sdo_axiom/sdo_axiom.dsp?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/projects/tuscany_sdo/sdo_axiom/sdo_axiom.dsp (original)
+++ incubator/tuscany/cpp/sdo/projects/tuscany_sdo/sdo_axiom/sdo_axiom.dsp Mon Jun 19 01:45:04
2006
@@ -79,10 +79,10 @@
 # ADD BSC32 /nologo
 LINK32=link.exe
 # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib
shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386
/pdbtype:sept
-# ADD LINK32 axis2_parser.lib axis2_util.lib axis2_om.lib tuscany_sdo.lib kernel32.lib user32.lib
gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"Debug/tuscany_sdo_axiom.dll"
/pdbtype:sept /libpath:"..\..\..\deploy\lib" /libpath:"$(AXIS2C_HOME)\lib"
+# ADD LINK32 axis2_parser.lib axis2_util.lib axiom.lib tuscany_sdo.lib kernel32.lib user32.lib
gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"Debug/tuscany_sdo_axiom.dll"
/pdbtype:sept /libpath:"..\..\..\deploy\lib" /libpath:"$(AXIS2C_HOME)\lib"
 # Begin Special Build Tool
 SOURCE="$(InputPath)"
-PostBuild_Cmds=copy      Debug\tuscany_sdo_axiom.dll      ..\..\..\deploy\bin     	copy 
    Debug\tuscany_sdo_axiom.pdb      ..\..\..\deploy\bin     	copy      Debug\tuscany_sdo_axiom.lib
     ..\..\..\deploy\lib     	copy      ..\..\..\runtime\core\sdo_axiom\sdo_axiom.h      ..\..\..\deploy\include\
    	copy      ..\..\..\runtime\core\sdo_axiom\sdo_axiom_export.h      ..\..\..\deploy\include\

+PostBuild_Cmds=copy       Debug\tuscany_sdo_axiom.dll       ..\..\..\deploy\bin      	copy
      Debug\tuscany_sdo_axiom.pdb       ..\..\..\deploy\bin      	copy       Debug\tuscany_sdo_axiom.lib
      ..\..\..\deploy\lib      	copy       ..\..\..\runtime\core\sdo_axiom\sdo_axiom.h   
   ..\..\..\deploy\include\      	copy       ..\..\..\runtime\core\sdo_axiom\sdo_axiom_export.h
      ..\..\..\deploy\include\ 
 # End Special Build Tool
 
 !ENDIF 

Modified: incubator/tuscany/cpp/sdo/projects/tuscany_sdo/tuscany_sdo.ncb
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/projects/tuscany_sdo/tuscany_sdo.ncb?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
Binary files - no diff available.

Modified: incubator/tuscany/cpp/sdo/projects/tuscany_sdo/tuscany_sdo.opt
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/projects/tuscany_sdo/tuscany_sdo.opt?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
Binary files - no diff available.

Modified: incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.cpp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.cpp?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.cpp (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.cpp Mon Jun 19 01:45:04 2006
@@ -74,23 +74,23 @@
         }
 
 
-        axis2_env_t** AxiomHelper::getEnv()
+        axis2_env_t* AxiomHelper::getEnv()
         {
-            return &the_env;
+            return the_env;
         }
 
-        axis2_om_node_t* AxiomHelper::toAxiomNode(DataObjectPtr dob)
+        axiom_node_t* AxiomHelper::toAxiomNode(DataObjectPtr dob)
         {
 
-            axis2_om_document_t* doc = toAxiomDoc(dob);
+            axiom_document_t* doc = toAxiomDoc(dob);
 
             if (!doc)
             {
                 return 0;
             }
     
-            axis2_om_node_t* root_node = 
-                AXIS2_OM_DOCUMENT_GET_ROOT_ELEMENT(doc, &the_env);
+            axiom_node_t* root_node = 
+                AXIOM_DOCUMENT_GET_ROOT_ELEMENT(doc, the_env);
             if (!root_node)
             {
                 cout << "No Root Element in the document" << endl;
@@ -101,7 +101,7 @@
             return root_node;
         }
 
-        axis2_om_document_t* AxiomHelper::toAxiomDoc(DataObjectPtr dob)
+        axiom_document_t* AxiomHelper::toAxiomDoc(DataObjectPtr dob)
         {
 
             DataFactory* df = dob->getDataFactory();
@@ -120,12 +120,8 @@
 
             // if (str) cout << str << endl;
 
-            axis2_xml_reader_t * reader =  
- //           axis2_xml_reader_create_for_buffer(&the_env,
- //                                 (const axis2_char_t *)str,
- //                                 strlen(str),
- //                                 (const axis2_char_t *)"UTF-8");
-            axis2_xml_reader_create_for_memory(&the_env,
+            axiom_xml_reader_t * reader =  
+            axiom_xml_reader_create_for_memory(the_env,
                                   (void*)str,
                                   strlen(str),
                                   (const axis2_char_t *)"UTF-8",
@@ -137,42 +133,42 @@
                 return 0;
             }
 
-            axis2_om_stax_builder_t* builder = 
-                axis2_om_stax_builder_create(&the_env, reader);
+            axiom_stax_builder_t* builder = 
+                axiom_stax_builder_create(the_env, reader);
         
             if (!builder)
             {
                 cout << "No Axis Builder" << endl;
-                AXIS2_XML_READER_FREE(reader, &the_env);
+                AXIOM_XML_READER_FREE(reader, the_env);
                 return 0;
             }
         
-            axis2_om_document_t* document = 
-                AXIS2_OM_STAX_BUILDER_GET_DOCUMENT(builder, &the_env);
+            axiom_document_t* document = 
+                AXIOM_STAX_BUILDER_GET_DOCUMENT(builder, the_env);
         
             if (!document)
             {
                 cout << "No Axis Document" << endl;
-                AXIS2_OM_STAX_BUILDER_FREE(builder, &the_env);
+                AXIOM_STAX_BUILDER_FREE(builder, the_env);
                 return 0;
             }
     
-            axis2_om_node_t* root_node = 
-                AXIS2_OM_DOCUMENT_GET_ROOT_ELEMENT(document, &the_env);
+            axiom_node_t* root_node = 
+                AXIOM_DOCUMENT_GET_ROOT_ELEMENT(document, the_env);
             if (!root_node)
             {
                 cout << "No Root Element in the document" << endl;
-                AXIS2_OM_STAX_BUILDER_FREE(builder, &the_env);
+                AXIOM_STAX_BUILDER_FREE(builder, the_env);
                 return 0;
             }
             
 
-            AXIS2_OM_DOCUMENT_BUILD_ALL(document, &the_env);
+            AXIOM_DOCUMENT_BUILD_ALL(document, the_env);
 
             return document;
         }
 
-        DataObjectPtr AxiomHelper::toSdo(axis2_om_document_t* document,
+        DataObjectPtr AxiomHelper::toSdo(axiom_document_t* document,
             DataFactoryPtr factory)
         {
         
@@ -182,13 +178,13 @@
                 return 0;
             }
 
-            axis2_om_node_t* root_node = 
-                AXIS2_OM_DOCUMENT_GET_ROOT_ELEMENT(document, &the_env);
+            axiom_node_t* root_node = 
+                AXIOM_DOCUMENT_GET_ROOT_ELEMENT(document, the_env);
 
             return toSdo(root_node,factory);
         }
  
-        DataObjectPtr AxiomHelper::toSdo(axis2_om_node_t* root_node,
+        DataObjectPtr AxiomHelper::toSdo(axiom_node_t* root_node,
                                 DataFactoryPtr factory)
         {
         
@@ -200,23 +196,23 @@
 
             XMLHelperPtr helper = HelperProvider::getXMLHelper(factory);
 
-            axis2_xml_writer_t* writer = axis2_xml_writer_create_for_memory(
-                &the_env, NULL, AXIS2_TRUE, 0,
+            axiom_xml_writer_t* writer = axiom_xml_writer_create_for_memory(
+                the_env, NULL, AXIS2_TRUE, 0,
                 AXIS2_XML_PARSER_TYPE_BUFFER);
     
-            axis2_om_output_t* output = axis2_om_output_create(&the_env, writer);
+            axiom_output_t* output = axiom_output_create(the_env, writer);
     
 
             if (!root_node)
             {
                 cout << "No Root Element in the document" << endl;
-                AXIS2_OM_OUTPUT_FREE(output, &the_env);
+                AXIOM_OUTPUT_FREE(output, the_env);
                 return 0;
             }
 
-            AXIS2_OM_NODE_SERIALIZE(root_node, &the_env, output);
+            AXIOM_NODE_SERIALIZE(root_node, the_env, output);
     
-            axis2_char_t* buffer = (axis2_char_t*)AXIS2_XML_WRITER_GET_XML(writer, &the_env);
+            axis2_char_t* buffer = (axis2_char_t*)AXIOM_XML_WRITER_GET_XML(writer, the_env);
 
             XMLDocumentPtr theXMLDocument = helper->load(buffer);
 
@@ -228,7 +224,7 @@
             return 0;
         }
  
-        void AxiomHelper::output(axis2_om_document_t* document)
+        void AxiomHelper::output(axiom_document_t* document)
         {
         
             if (!the_env)
@@ -237,29 +233,29 @@
                 return;
             }
 
-            axis2_xml_writer_t* writer = axis2_xml_writer_create_for_memory(
-                &the_env, NULL, AXIS2_TRUE, 0,
+            axiom_xml_writer_t* writer = axiom_xml_writer_create_for_memory(
+                the_env, NULL, AXIS2_TRUE, 0,
                 AXIS2_XML_PARSER_TYPE_BUFFER);
     
-            axis2_om_output_t* output = axis2_om_output_create(&the_env, writer);
+            axiom_output_t* output = axiom_output_create(the_env, writer);
     
-            axis2_om_node_t* root_node = 
-                AXIS2_OM_DOCUMENT_GET_ROOT_ELEMENT(document, &the_env);
+            axiom_node_t* root_node = 
+                AXIOM_DOCUMENT_GET_ROOT_ELEMENT(document, the_env);
  
             if (!root_node)
             {
                 cout << "No Root Element in the document" << endl;
-                AXIS2_OM_OUTPUT_FREE(output, &the_env);
+                AXIOM_OUTPUT_FREE(output, the_env);
                 return;
             }
 
-            AXIS2_OM_NODE_SERIALIZE(root_node, &the_env, output);
+            AXIOM_NODE_SERIALIZE(root_node, the_env, output);
     
-            axis2_char_t* buffer = (axis2_char_t*)AXIS2_XML_WRITER_GET_XML(writer, &the_env);
+            axis2_char_t* buffer = (axis2_char_t*)AXIOM_XML_WRITER_GET_XML(writer, the_env);
 
             printf("Output XML:n %s ", buffer);
 
-            AXIS2_OM_OUTPUT_FREE(output, &the_env);
+            AXIOM_OUTPUT_FREE(output, the_env);
        
             return;          
         }

Modified: incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.h
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.h?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.h (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom/sdo_axiom.h Mon Jun 19 01:45:04 2006
@@ -22,9 +22,9 @@
 
 #include "sdo_axiom_export.h"
 
-#include "axis2_om.h"
-#include "axis2_om_document.h"
-#include "axis2_om_stax_builder.h"
+#include "axiom.h"
+//#include "axis2_om_document.h"
+//#include "axis2_om_stax_builder.h"
 
 
 #include "commonj/sdo/SDO.h"
@@ -52,15 +52,15 @@
 
             SDO_AXIOM_API static void releaseHelper(AxiomHelper* ax);
 
-            SDO_AXIOM_API axis2_om_document_t*  toAxiomDoc(DataObjectPtr dob);
-            SDO_AXIOM_API axis2_om_node_t*      toAxiomNode(DataObjectPtr dob);
+            SDO_AXIOM_API axiom_document_t*  toAxiomDoc(DataObjectPtr dob);
+            SDO_AXIOM_API axiom_node_t*      toAxiomNode(DataObjectPtr dob);
 
-            SDO_AXIOM_API DataObjectPtr  toSdo(axis2_om_document_t* doc,DataFactoryPtr factory);
-            SDO_AXIOM_API DataObjectPtr  toSdo(axis2_om_node_t* root_node,DataFactoryPtr
factory);
+            SDO_AXIOM_API DataObjectPtr  toSdo(axiom_document_t* doc,DataFactoryPtr factory);
+            SDO_AXIOM_API DataObjectPtr  toSdo(axiom_node_t* root_node,DataFactoryPtr factory);
 
-            SDO_AXIOM_API axis2_env_t** getEnv();
+            SDO_AXIOM_API axis2_env_t* getEnv();
 
-            SDO_AXIOM_API void output(axis2_om_document_t* document);
+            SDO_AXIOM_API void output(axiom_document_t* document);
 
 
         protected:

Modified: incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom_test/sdo_axiom_test.cpp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom_test/sdo_axiom_test.cpp?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom_test/sdo_axiom_test.cpp (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/sdo_axiom_test/sdo_axiom_test.cpp Mon Jun 19 01:45:04
2006
@@ -84,7 +84,7 @@
 
     if (ax)
     {
-        axis2_om_document_t* doc = ax->toAxiomDoc(company);
+        axiom_document_t* doc = ax->toAxiomDoc(company);
 
         if (doc)
         {
@@ -99,8 +99,8 @@
                 cout << "Finished" << endl;
             }
 
-            axis2_om_node_t* node = 
-                            AXIS2_OM_DOCUMENT_GET_ROOT_ELEMENT(doc, ax->getEnv());
+            axiom_node_t* node = 
+                            AXIOM_DOCUMENT_GET_ROOT_ELEMENT(doc, ax->getEnv());
  
 
             DataObjectPtr newdob2 = ax->toSdo(node,mdg);

Modified: incubator/tuscany/cpp/sdo/runtime/core/test/main.cpp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/test/main.cpp?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/test/main.cpp (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/test/main.cpp Mon Jun 19 01:45:04 2006
@@ -44,6 +44,7 @@
     int totaltests=0;
     int value = 0;
 
+    TEST ( sdotest::scopetest() );
     TEST ( sdotest::xsdtosdo() );
 
     /* groups now supported*/

Modified: incubator/tuscany/cpp/sdo/runtime/core/test/sdotest.h
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sdo/runtime/core/test/sdotest.h?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/test/sdotest.h (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/test/sdotest.h Mon Jun 19 01:45:04 2006
@@ -61,6 +61,10 @@
         static int definetest();
         static int stocktest();
 
+        static int scopetest();
+        static DataObjectPtr scopetest2();
+
+
         static int pete();
         static int testgenerate(const char* xsd, const char* output);
         static int emptycs();

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?rev=415260&r1=415259&r2=415260&view=diff
==============================================================================
--- incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp (original)
+++ incubator/tuscany/cpp/sdo/runtime/core/test/sdotest2.cpp Mon Jun 19 01:45:04 2006
@@ -32,6 +32,41 @@
 
 using namespace commonj::sdo;
 
+DataObjectPtr sdotest::scopetest2()
+{
+
+    DataFactoryPtr mdg  = DataFactory::getDataFactory();
+
+    mdg->addType("myspace","Root");
+
+    mdg->addType("myspace","Company");
+
+    mdg->addPropertyToType("myspace","Company","name",
+                       "commonj.sdo","String", false, false, false);
+
+    mdg->addPropertyToType("myspace","Company","id",
+                       "commonj.sdo","String", false, false, false);
+
+    mdg->addPropertyToType("myspace","Root","company",
+                       "myspace","Company", false, false, true);
+
+    const Type& tcc = mdg->getType("myspace","Root");
+
+    DataObjectPtr dop = mdg->create((Type&)tcc);
+
+    DataObjectPtr co = dop->createDataObject("company");
+
+    return dop;
+}
+
+int sdotest::scopetest()
+{
+    DataObjectPtr dob;
+    dob = scopetest2();
+
+    // fails on close?
+    return 1;
+}
 
 int sdotest::xsdtosdo()
 {



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


Mime
View raw message