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 2006/07/05 19:03:34 UTC
svn commit: r419280 - in
/incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule:
CalculatorImpl_CalculatorDivideService_Proxy.cpp
CalculatorImpl_CalculatorDivideService_Proxy.h
Author: robbinspg
Date: Wed Jul 5 10:03:34 2006
New Revision: 419280
URL: http://svn.apache.org/viewvc?rev=419280&view=rev
Log:
TUSCANY-517 Update to calculator sample provided by Andy Borley
add files I missed 2nd time :-(
Added:
incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp (with props)
incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h (with props)
Added: incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp?rev=419280&view=auto
==============================================================================
--- incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp (added)
+++ incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp Wed Jul 5 10:03:34 2006
@@ -0,0 +1,64 @@
+/*
+ * 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.
+ */
+
+#include "CalculatorImpl_CalculatorDivideService_Proxy.h"
+
+#include "osoa/sca/sca.h"
+using namespace osoa::sca;
+using namespace tuscany::sca;
+
+extern "C"
+{
+
+ #if defined(WIN32) || defined(_WINDOWS)
+ __declspec(dllexport)
+ #endif
+ CalculatorImpl_CalculatorDivideService_Proxy* CalculatorImpl_CalculatorDivideService_Proxy_Factory(ServiceWrapper* target)
+ {
+ return new CalculatorImpl_CalculatorDivideService_Proxy(target);
+ }
+
+ #if defined(WIN32) || defined(_WINDOWS)
+ __declspec(dllexport)
+ #endif
+ void CalculatorImpl_CalculatorDivideService_Proxy_Destructor(void* proxy)
+ {
+ delete (CalculatorImpl_CalculatorDivideService_Proxy*)proxy;
+ }
+}
+
+CalculatorImpl_CalculatorDivideService_Proxy::CalculatorImpl_CalculatorDivideService_Proxy(ServiceWrapper* targ) : target(targ)
+{
+}
+
+CalculatorImpl_CalculatorDivideService_Proxy::~CalculatorImpl_CalculatorDivideService_Proxy()
+{
+ if (target)
+ delete target;
+}
+
+float CalculatorImpl_CalculatorDivideService_Proxy::divide( float arg0, float arg1)
+{
+ Operation operation("divide");
+ operation.addParameter(&arg0);
+ operation.addParameter(&arg1);
+ float ret;
+ operation.setReturnValue(&ret);
+ target->invoke(operation);
+ return ret;
+}
+
+
Propchange: incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.cpp
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h
URL: http://svn.apache.org/viewvc/incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h?rev=419280&view=auto
==============================================================================
--- incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h (added)
+++ incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h Wed Jul 5 10:03:34 2006
@@ -0,0 +1,38 @@
+/*
+ * 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.
+ */
+
+#ifndef CalculatorImpl_CalculatorDivideService_Proxy_h
+#define CalculatorImpl_CalculatorDivideService_Proxy_h
+
+#if defined(WIN32) || defined (_WINDOWS)
+#pragma warning(disable: 4786)
+#endif
+
+#include "DivideService.h"
+#include "tuscany/sca/core/ServiceWrapper.h"
+
+class CalculatorImpl_CalculatorDivideService_Proxy : public DivideService
+{
+public:
+ CalculatorImpl_CalculatorDivideService_Proxy(tuscany::sca::ServiceWrapper*);
+ virtual ~CalculatorImpl_CalculatorDivideService_Proxy();
+ virtual float divide( float arg1, float arg2);
+private:
+ tuscany::sca::ServiceWrapper* target;
+};
+
+#endif // CalculatorImpl_CalculatorDivideService_Proxy_h
+
Propchange: incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/cpp/sca/samples/Calculator/CalculatorModule/CalculatorImpl_CalculatorDivideService_Proxy.h
------------------------------------------------------------------------------
svn:keywords = Rev Date
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org