diff options
Diffstat (limited to 'tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo')
8 files changed, 243 insertions, 0 deletions
diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.cdtbuild b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.cdtbuild new file mode 100644 index 0000000000..ed308ead8d --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.cdtbuild @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<?fileVersion 3.0.0?>
+
+<ManagedProjectBuildInfo>
+<project id="tuscany_sca_test_CustomerInfo.cdt.managedbuild.target.gnu.so.1305856867" name="Shared Library (Gnu)" projectType="cdt.managedbuild.target.gnu.so">
+<configuration artifactExtension="so" artifactName="CustomerInfo" cleanCommand="rm -rf" description="" errorParsers="org.eclipse.cdt.core.MakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="cdt.managedbuild.config.gnu.so.debug.180210457" name="Debug" parent="cdt.managedbuild.config.gnu.so.debug">
+<toolChain id="cdt.managedbuild.toolchain.gnu.so.debug.150489083" name="GCC Tool Chain" superClass="cdt.managedbuild.toolchain.gnu.so.debug">
+<tool command="gcc" id="cdt.managedbuild.tool.gnu.c.compiler.so.debug.744339895" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.so.debug"/>
+<tool command="g++" id="cdt.managedbuild.tool.gnu.cpp.compiler.so.debug.773936698" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.so.debug">
+<option id="gnu.cpp.compiler.option.preprocessor.def.1937348866" superClass="gnu.cpp.compiler.option.preprocessor.def" valueType="definedSymbols">
+<listOptionValue builtIn="false" value="_DEBUG"/>
+</option>
+<option id="gnu.cpp.compiler.option.include.paths.1481017815" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
+<listOptionValue builtIn="false" value="${SCA4CPP_HOME}/runtime/core/src"/>
+<listOptionValue builtIn="false" value="${SDO4CPP}/include"/>
+</option>
+</tool>
+<tool command="gcc" id="cdt.managedbuild.tool.gnu.c.linker.so.debug.2091259285" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.so.debug"/>
+<tool command="g++" id="cdt.managedbuild.tool.gnu.cpp.linker.so.debug.509296678" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.so.debug"/>
+<tool command="as" id="cdt.managedbuild.tool.gnu.assembler.so.debug.187343736" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.so.debug"/>
+<macros/>
+</toolChain>
+</configuration>
+<configuration artifactExtension="so" artifactName="CustomerInfo" cleanCommand="rm -rf" description="" errorParsers="org.eclipse.cdt.core.MakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="cdt.managedbuild.config.gnu.so.release.954607388" name="Release" parent="cdt.managedbuild.config.gnu.so.release">
+<toolChain id="cdt.managedbuild.toolchain.gnu.so.release.1899157892" name="GCC Tool Chain" superClass="cdt.managedbuild.toolchain.gnu.so.release">
+<tool command="gcc" id="cdt.managedbuild.tool.gnu.c.compiler.so.release.1905763267" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.so.release"/>
+<tool command="g++" id="cdt.managedbuild.tool.gnu.cpp.compiler.so.release.91975924" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.so.release">
+<option id="gnu.cpp.compiler.option.include.paths.695258843" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
+<listOptionValue builtIn="false" value="${SCA4CPP_HOME}/runtime/core/src"/>
+<listOptionValue builtIn="false" value="${SDO4CPP}/include"/>
+</option>
+</tool>
+<tool command="gcc" id="cdt.managedbuild.tool.gnu.c.linker.so.release.749931234" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.so.release"/>
+<tool command="g++" id="cdt.managedbuild.tool.gnu.cpp.linker.so.release.636362934" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.so.release"/>
+<tool command="as" id="cdt.managedbuild.tool.gnu.assembler.so.release.1971799783" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.so.release"/>
+<macros/>
+</toolChain>
+</configuration>
+<macros/>
+</project>
+</ManagedProjectBuildInfo>
diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.cdtproject b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.cdtproject new file mode 100644 index 0000000000..48a12e6664 --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.cdtproject @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse-cdt version="2.0"?>
+
+<cdtproject id="org.eclipse.cdt.managedbuilder.core.managedMake">
+<extension id="org.eclipse.cdt.managedbuilder.core.ManagedBuildManager" point="org.eclipse.cdt.core.ScannerInfoProvider"/>
+<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
+<extension id="org.eclipse.cdt.core.domsourceindexer" point="org.eclipse.cdt.core.CIndexer"/>
+<data>
+<item id="org.eclipse.cdt.core.pathentry">
+<pathentry kind="src" path=""/>
+<pathentry kind="out" path=""/>
+<pathentry kind="con" path="org.eclipse.cdt.managedbuilder.MANAGED_CONTAINER"/>
+</item>
+</data>
+</cdtproject>
diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.project b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.project new file mode 100644 index 0000000000..60a0a75176 --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.project @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>tuscany_sca_test_CustomerInfo</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.cdt.core.cnature</nature> + <nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature> + <nature>org.eclipse.cdt.core.ccnature</nature> + </natures> +</projectDescription> diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.settings/org.eclipse.cdt.managedbuilder.core.prefs b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.settings/org.eclipse.cdt.managedbuilder.core.prefs new file mode 100644 index 0000000000..691a33706a --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/.settings/org.eclipse.cdt.managedbuilder.core.prefs @@ -0,0 +1,9 @@ +#Tue Nov 29 15:05:50 GMT 2005
+eclipse.preferences.version=1
+environment/buildEnvironmentInclude/cdt.managedbuild.config.gnu.so.debug.180210457=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment>\n<variable name\="CPATH" operation\="remove"/>\n<variable name\="CPLUS_INCLUDE_PATH" operation\="remove"/>\n</environment>\n
+environment/buildEnvironmentInclude/cdt.managedbuild.config.gnu.so.release.954607388=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment>\n<variable name\="CPATH" operation\="remove"/>\n<variable name\="CPLUS_INCLUDE_PATH" operation\="remove"/>\n</environment>\n
+environment/buildEnvironmentLibrary/cdt.managedbuild.config.gnu.so.debug.180210457=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment>\n<variable name\="LIBRARY_PATH" operation\="remove"/>\n</environment>\n
+environment/buildEnvironmentLibrary/cdt.managedbuild.config.gnu.so.release.954607388=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment>\n<variable name\="LIBRARY_PATH" operation\="remove"/>\n</environment>\n
+environment/project=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment/>\n
+environment/project/cdt.managedbuild.config.gnu.so.debug.180210457=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment/>\n
+environment/project/cdt.managedbuild.config.gnu.so.release.954607388=<?xml version\="1.0" encoding\="UTF-8"?>\n<environment/>\n
diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfo.h b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfo.h new file mode 100644 index 0000000000..6372a5a45a --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfo.h @@ -0,0 +1,30 @@ +/* + * + * Copyright 2005 The Apache Software Foundation or its licensors, as applicable. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* $Rev$ $Date: 2005/12/22 11:33:21 $ */ + +#ifndef CustomerInfo_h +#define CustomerInfo_h + +class CustomerInfo +{ +public: + virtual const char* getCustomerInformation(const char* customerID) = 0; + +}; + +#endif diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfoImpl.cpp b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfoImpl.cpp new file mode 100644 index 0000000000..91996bace7 --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfoImpl.cpp @@ -0,0 +1,79 @@ +/* + * + * Copyright 2005 The Apache Software Foundation or its licensors, as applicable. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* $Rev$ $Date: 2005/12/22 11:33:21 $ */ + +#include "CustomerInfoImpl.h" +#include <ostream> +#include <string.h> +#include "osoa/sca/sca.h" +#include "commonj/sdo/DataObjectInstance.h" +using namespace osoa::sca; +using namespace commonj::sdo; + +////////////////////////////////////////////////////////////////////// +// Construction/Destruction +////////////////////////////////////////////////////////////////////// + +CustomerInfoImpl::CustomerInfoImpl() +{ + cout << "Construct CustomerInfoImpl" << endl; + +} + +CustomerInfoImpl::~CustomerInfoImpl() +{ + cout << "Destroy CustomerInfoImpl" << endl; +} + +////////////////////////////////////////////////////////////////////// +// Other methods +////////////////////////////////////////////////////////////////////// +const char* CustomerInfoImpl::getCustomerInformation(const char* customerID) +{ + cout << "In getCustomerInformation with customerid: " << customerID << endl; + + + + ComponentContext myContext = ComponentContext::getCurrent(); + + DataObjectInstance properties = myContext.getProperties(); + DataObjectInstance props2 = properties; + if (properties) + { + const char* fredVal = properties->getCString("Fred"); + cout << "Property Fred value: " << fredVal <<endl; + + + DataObjectList& joeList = properties->getList("Joe"); + for (int i=0; i<joeList.size();i++) + { + cout << "Property Joe value " << i << ": " << joeList.getInteger(i) <<endl; + } + } + + if (!strcmp("12345", customerID)) + { + return "IBM"; + } + else + { + throw "Wobbler"; + } + + +} diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfoImpl.h b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfoImpl.h new file mode 100644 index 0000000000..7f70664f68 --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/CustomerInfoImpl.h @@ -0,0 +1,36 @@ +/* + * + * Copyright 2005 The Apache Software Foundation or its licensors, as applicable. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* $Rev$ $Date: 2005/12/22 11:33:21 $ */ + +#ifndef CustomerInfoImpl_h +#define CustomerInfoImpl_h + +#include "CustomerInfo.h" + + + +class CustomerInfoImpl : public CustomerInfo +{ +public: + CustomerInfoImpl(); + virtual ~CustomerInfoImpl(); + virtual const char* getCustomerInformation(const char* customerID); + +}; + +#endif diff --git a/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/Makefile.am b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/Makefile.am new file mode 100644 index 0000000000..b533c6cdb8 --- /dev/null +++ b/tags/cpp-stable-20060304/sca/runtime/core/test/CustomerInfo/Makefile.am @@ -0,0 +1,14 @@ +lib_LTLIBRARIES = libCustomerInfo.la + +libCustomerInfo_la_SOURCES = \ +CustomerInfoImpl.cpp \ +CustomerInfoImpl_CustomerInfoService_Proxy.cpp \ +CustomerInfoImpl_CustomerInfoService_Wrapper.cpp + +libCustomerInfo_la_LIBADD = + +INCLUDES = -I$(top_builddir)/runtime/core/src \ + -I${TUSCANY_SDOCPP}/include \ + -I${AXISCPP_DEPLOY}/include + +install:
\ No newline at end of file |