diff options
Diffstat (limited to 'tags/cpp-1.0-incubating-M2-RC1/sca/samples')
232 files changed, 16159 insertions, 0 deletions
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/AUTHORS b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/AUTHORS new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/AUTHORS diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/Makefile.am new file mode 100644 index 0000000000..238a783674 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/Makefile.am @@ -0,0 +1,4 @@ +deploydir=$(prefix)/samples/BigBank/deploy +SUBDIRS = bigbank.account bigbank.client bigbank.wsclient +EXTRA_DIST = *.composite README.html +deploy_DATA = *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/README new file mode 100644 index 0000000000..dc919e1aed --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/README @@ -0,0 +1,30 @@ +Tuscany SCA for C++ Samples - BigBank Sample +=============================================== + +This sample implements the "Simplified BigBank" scenario. A whitepaper +describing the scenario based on the SCA 0.9 Assembly specification can be +found here. This sample uses multiple C++ components, calls out to an +external Web Service via a reference, exposes the service as a Web Service +and also provides a PHP based client. + +There are four sub projects in this workspace: + - bigbank.account + This contains the source code and SCDL artifacts for the SCA BigBank + composite implementing the account services. + + - bigbank.client + A sample client which does a local call to the BigBank service. + + - bigbank.wsclient + A sample Axis2 Web Service client which calls the BigBank Web service. + + - bigbank.phpclient + A sample PHP client which calls the BigBank Web service and then + deconstructs and displays the result by using the SDO for PHP extension. + +Additionally, there is the bigbank.accountmanagement.composite file. This +describes the configuration of the SCA Calculator composite deployed to the +SCA runtime. + +See the README.html file for instructions to build and run this sample + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/README.html b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/README.html new file mode 100644 index 0000000000..26cc1f303d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/README.html @@ -0,0 +1,424 @@ + +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<!-- + Copyright 2006 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. + --> +<HTML> +<HEAD> + <META CONTENT="text/html; charset=iso-8859-1" HTTP-EQUIV="Content-Type"> + <META CONTENT="text/css" HTTP-EQUIV="Content-Style-Type"> + <STYLE MEDIA="all" TYPE="text/css"> +@import url("../../doc/css/maven-base.css"); +@import url("../../doc/css/maven-theme.css"); + </STYLE> + + <LINK HREF="../doc/css/maven-theme.css" MEDIA="print" REL="stylesheet" + TYPE="text/css"> + <TITLE>Tuscany SCA for C++ Samples - BigBank Sample</TITLE> +</HEAD> + +<BODY> +<DIV ID="bodyColumn"> + <DIV ID="contentBox"> + <DIV CLASS="section"> + <H2>Tuscany SCA for C++ Samples - BigBank Sample</H2> + + <P>This sample implements the "Simplified BigBank" scenario. A whitepaper describing + the scenario based on the SCA 0.9 Assembly specification can be found + <A HREF="http://www.osoa.org/display/Main/SCA+-+Previously+Published+Specifications">here</A>. + This sample uses multiple C++ components, calls out to an external Web Service via a reference, + exposes the service as a Web Service and also provides a PHP based client. + </P> + <P>There are four sub projects in this workspace:</P> + <UL> + <LI>bigbank.account<BR/> + This contains the source code and SCDL artifacts for the SCA BigBank + composite implementing the account services. + </LI> + <LI>bigbank.client<BR/> + A sample client which does a local call to the BigBank service. + </LI> + <LI>bigbank.wsclient<BR/> + A sample Axis2 Web Service client which calls the BigBank Web service. + </LI> + <LI>bigbank.phpclient<BR/> + A sample PHP client which calls the BigBank Web service and then deconstructs + and displays the result by using the + <A HREF="http://www.osoa.org/display/PHP/SOA+PHP+Homepage">SDO for PHP extension</A>. + <P>This is a pair of very simple PHP scripts to demonstrate how the Accounts service + that the C++ Big Bank sample exposes can be used from within the PHP scripting + language. + </P> + <P>bigwelcome.php<BR/> + A bootstrap script that shows a form and allows the user to press a button + in order to invoke the bigaccount.php script + </P> + <P>bigaccount.php<BR/> + Makes a call to a locally installed BigBank Accounts service. The script + shows how to use PHP SDO and SOAP extensions to construct the call + and interpret the result. + </P> + </LI> + </UL> + <P>Additionally, there is the bigbank.accountmanagement.composite file. This + describes the configuration of the SCA Calculator composite deployed to the SCA + runtime. + </P> + + </DIV> + + <DIV CLASS="section"> + <H2>Contents</H2> + <OL> + <LI><A HREF="#linuxbld">Building the C++ samples on Linux</A></LI> + <LI><A HREF="#linuxrun">Running the BigBank sample on Linux:</A></LI> + <UL> + <LI><A HREF="#linuxbasic">Running the basic client</A></LI> + <LI><A HREF="#linuxws">Running the Web Service client</A></LI> + <LI><A HREF="#linuxphp">Installing and running the PHP web client</A></LI> + </UL> + <LI><A HREF="#winbld">Building the BigBank sample on Windows</A></LI> + <LI><A HREF="#winrun">Running the BigBank sample on Windows:</A></LI> + <UL> + <LI><A HREF="#winbasic">Running the basic client</A></LI> + <LI><A HREF="#winws">Running the Web Service client</A></LI> + <LI><A HREF="#winphp">Installing and running the PHP web client</A></LI> + </UL> + <LI><A HREF="#help">Getting help</A></LI> + </OL> + </DIV> + + + <DIV CLASS="section"> + <A NAME="linuxbld"><H2>Building the C++ samples on Linux</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#linuxrun">Running the samples on Linux</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>Build the C++ samples with the following command sequence: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples</LI> + <LI>./configure --prefix=$TUSCANY_SCACPP</LI> + <LI>make</LI> + <LI>make install</LI> + </UL> + NOTE: If you don't provide the --prefix configure option, it will by default install into + /usr/local/tuscany/sca/samples/BigBank</LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="linuxrun"><H2>Running the BigBank sample on Linux</H2></A> + <A NAME="linuxbasic"><H3>BigBank with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.92></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.client</LI> + <LI>./runclient.sh</LI> + </UL> + </LI> + </OL> + <A NAME="linuxws"><H3>BigBank with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.account + </LI> + <LI>./runwsserver.sh</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variable is required: + <UL> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.wsclient</LI> + <LI>./runwsclient.sh</LI> + </OL> + </LI> + </OL> + <A NAME="linuxphp"><H3>BigBank with PHP web client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bin + </LI> + <LI>./runwsserver.sh</LI> + </OL> + </LI> + <LI>To run the php scripts requires some configuration and setup of a php runtime with + the SDO and SimpleXML extensions enabled. The bits you will need are: + <UL> + <LI><A HREF="http://httpd.apache.org/">Apache web server</A> (tested with version 2.0.55)</LI> + <LI><A HREF="http://www.php.net/downloads.php">PHP 5</A> (tested with version 5.1.6)</LI> + <LI><A HREF="http://pecl.php.net/package/sdo">PHP SDO</A> (tested with version 1.0.3)</LI> + </UL> + <P>Follow + <A HREF="http://livedocs.phpdoc.info/index.php?l=en&q=ref.sdo">these instructions</A> to + install SDO and DAS. + </P> + </LI> + <LI>You need to configure Apache to run PHP of course. This is well documented but this + is what I put at the end of httpd.conf: + <PRE># PHP5 Support +LoadModule php5_module "/home/php/php5.1.6/php5apache2.so" +AddType application/x-httpd-php .php + +# configure the path to php.ini +PHPIniDir "/home/php/php5.1.6"</PRE> + </LI> + <LI>Copy the <tuscany_sca_install_dir>/samples/BigBank/bigbank.phpwsclient + directory to your Apache document root directory (by default this is named 'htdocs'). + </LI> + <LI>Finally, start your Apache web server. + </LI> + <LI>Run the PHP web client by pointing your browser at + <A HREF="http://localhost/bigbank.phpwsclient/welcome.php">http://localhost/bigbank.phpwsclient/welcome.php</A>. + You should now be able to press the "GetAccount" button and see the values + returned from the BigBank SCA application. + </LI> + + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winbld"><H2>Building the BigBank sample on Windows</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#winrun">Running the samples on Windows</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>You must have set up the environment for Microsoft Visual C++ tools. + The build command will call vcvars32 to set the environment. Ensure the + directory containing this is on your path. This will be where you + installed the compiler. + </LI> + <LI>Build the source, either via the Visual Studio 6 or 7 projects under + <tuscany_sca_install_dir>\samples\ides or via the command-line build file + found at <tuscany_sca_install_dir>\samples\ides\devstudio6\projects\BigBank\build.cmd + which will build and deploy the samples. + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winrun"><H2>Running the BigBank sample on Windows</H2></A> + <A NAME="winbasic"><H3>BigBank with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.client</LI> + <LI>./runclient.bat</LI> + </UL> + </LI> + </OL> + <A NAME="winws"><H3>BigBank with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.account + </LI> + <LI>./runwsserver.bat</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variable is required: + <UL> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.wsclient</LI> + <LI>./runwsclient.bat</LI> + </OL> + </LI> + </OL> + <A NAME="winphp"><H3>BigBank with PHP web client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/BigBank/deploy/bigbank.account + </LI> + <LI>./runwsserver.bat</LI> + </OL> + </LI> + <LI>To run the php scripts requires some configuration and setup of a php runtime with + the SDO and SimpleXML extensions enabled. The bits you will need are: + <UL> + <LI><A HREF="http://httpd.apache.org/">Apache web server</A> (tested with version 2.0.55)</LI> + <LI><A HREF="http://www.php.net/downloads.php">PHP 5</A> (tested with version 5.1.6)</LI> + <LI><A HREF="http://pecl.php.net/package/sdo">PHP SDO</A> (tested with version 1.0.3)</LI> + </UL> + <P>You can get Windows binary builds from + <A HREF="http://www.php.net/downloads.php">http://www.php.net/downloads.php</A>. + For SDO you need two dlls as follows: + </P> + <UL> + <LI><A HREF="http://pecl4win.php.net/ext.php/php_sdo.dll">php_sdo.dll</A></LI> + <LI><A HREF="http://pecl4win.php.net/ext.php/php_sdo_das_xml.dll">php_sdo_das_xml.dll</A></LI> + </UL> + <P>I copied these to my php5.1.6/ext dir ( php_soap.dll is already there) and added the + following to my php.ini file (having already renamed php.ini-recommended to php.ini + of course) + <PRE>extension=php_soap.dll +extension=php_sdo.dll +extension=php_sdo_das_xml.dll</PRE> + I also changed the extension_dir directive to point to my extensions directory: + <PRE>extension_dir="C:/php5.1.6/ext"</PRE> + </P> + <P>When I ask PHP to list what modules are active in my version of PHP I get the + following: + <PRE>C:\php5.1.6>php -m +[PHP Modules] +bcmath +calendar +com_dotnet +ctype +date +dom +ftp +hash +iconv +libxml +odbc +pcre +Reflection +sdo +sdo_das_xml +session +SimpleXML +soap +SPL +standard +tokenizer +wddx +xml +xmlreader +xmlwriter +zlib + +[Zend Modules]</PRE> + Of particular relevance to these scripts note that soap, sdo and sdo_das_xml are active. + </P> + </LI> + <LI>You need to configure Apache to run PHP of course. This is well documented but this + is what I put at the end of httpd.conf: + <PRE># PHP5 Support +LoadModule php5_module "C:/php5.1.6/php5apache2.dll" +AddType application/x-httpd-php .php + +# configure the path to php.ini +PHPIniDir "C:/php5.1.6"</PRE> + </LI> + <LI>Copy the <tuscany_sca_install_dir>/samples/BigBank/bigbank.phpwsclient + directory to your Apache document root directory (by default this is named 'htdocs'). + </LI> + <LI>Finally, start your Apache web server. + </LI> + <LI>Run the PHP web client by pointing your browser at + <A HREF="http://localhost/bigbank.phpwsclient/welcome.php">http://localhost/bigbank.phpwsclient/welcome.php</A>. + You should now be able to press the "GetAccount" button and see the values + returned from the BigBank SCA application. + </LI> + </OL> + </DIV> + + + + <DIV CLASS="section"> + <A NAME="help"><H2>Getting Help</H2></A> + + <P>First place to look is at the Tuscany FAQ at + <A HREF="http://incubator.apache.org/tuscany/faq.html" + TARGET="_blank">http://incubator.apache.org/tuscany/faq.html</A> </P> + + <P>Any problem with this release can be reported to the Tuscany + <A HREF="http://incubator.apache.org/tuscany/mail-lists.html" + TARGET="_blank">mailing lists</A> or create a JIRA issue at <A HREF="http://issues.apache.org/jira/browse/Tuscany" + TARGET="_blank">http://issues.apache.org/jira/browse/Tuscany</A>.</P> + </DIV> + </DIV> +</DIV> +</BODY> + +</HTML> + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataService.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataService.h new file mode 100644 index 0000000000..04000698e7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataService.h @@ -0,0 +1,64 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "commonj/sdo/SDO.h" + +#include <string> +using std::string; + +namespace services +{ + namespace accountdata + { + + /** + * AccountDataService business interface + */ + class AccountDataService + { + public: + + // CheckingAccount is a data object containing + // string accountNumber + // float balance + + virtual commonj::sdo::DataObjectPtr /* CheckingAccount*/ getCheckingAccount( + const string id) = 0; + + // SavingsAccount is a data object containing + // string accountNumber + // float balance + + virtual commonj::sdo::DataObjectPtr /* SavingsAccount */ getSavingsAccount( + const string id) = 0; + + // StockAccount is a data object containing + // string accountNumber + // string symbol + // int quantity + + virtual commonj::sdo::DataObjectPtr /* StockAccount */ getStockAccount ( + const string id) = 0; + + }; + + } // End accountdata +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.componentType new file mode 100644 index 0000000000..b1cab9e1f9 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.componentType @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"> + + <service name="AccountDataService"> + <interface.cpp header="AccountDataService.h"/> + </service> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.cpp new file mode 100644 index 0000000000..3f06809919 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.cpp @@ -0,0 +1,136 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#if defined(WIN32) || defined (_WINDOWS) +#pragma warning(disable: 4786) +#endif + +#include "commonj/sdo/SDO.h" +#include "osoa/sca/sca.h" + +#include "AccountDataServiceImpl.h" + +using namespace commonj::sdo; +using namespace osoa::sca; + +/** + * AccountDataServiceImpl component implementation + */ + +namespace services +{ + namespace accountdata + { + + DataObjectPtr /* CheckingAccount*/ + AccountDataServiceImpl::getCheckingAccount(const string id) + { + try { + + DataFactoryPtr factory = ComponentContext::getCurrent().getDataFactory(); + + DataObjectPtr newaccount = + factory->create("http://www.bigbank.com/AccountService","CheckingAccount"); + + char* name = new char[id.size() + 10]; + strcpy(name,id.c_str()); + strcat(name,"_CHA12345"); + + newaccount->setCString("accountNumber",name); + + delete name; + + newaccount->setFloat("balance",1500.0f); + + return newaccount; + + } + catch (SDORuntimeException e) + { + return 0; + } + } + + + + DataObjectPtr /* SavingsAccount */ + AccountDataServiceImpl::getSavingsAccount(const string id) + { + try { + + DataFactoryPtr factory = ComponentContext::getCurrent().getDataFactory(); + + DataObjectPtr newaccount = + factory->create("http://www.bigbank.com/AccountService","SavingsAccount"); + + char* name = new char[id.size() + 10]; + strcpy(name,id.c_str()); + strcat(name,"_SAA12345"); + + newaccount->setCString("accountNumber",name); + + delete name; + + newaccount->setFloat("balance",1500.0f); + + return newaccount; + + } + catch (SDORuntimeException e) + { + return 0; + } + } + + + DataObjectPtr /* StockAccount */ + AccountDataServiceImpl::getStockAccount (const string id) + { + try { + + DataFactoryPtr factory = ComponentContext::getCurrent().getDataFactory(); + + DataObjectPtr newaccount = + factory->create("http://www.bigbank.com/AccountService","StockAccount"); + + char* name = new char[id.size() + 10]; + strcpy(name,id.c_str()); + strcat(name,"_STA12345"); + + newaccount->setCString("accountNumber",name); + + delete name; + + newaccount->setCString("symbol","IBM"); + + newaccount->setInteger("quantity",100); + + return newaccount; + + } + catch (SDORuntimeException e) + { + return 0; + } + } + + } // End accountdata +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.h new file mode 100644 index 0000000000..373da4ba95 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountDataServiceImpl.h @@ -0,0 +1,61 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "AccountDataService.h" + +namespace services +{ + namespace accountdata + { + + /** + * AccountDataServiceImpl component implementation class + */ + class AccountDataServiceImpl : public AccountDataService + { + public: + + // CheckingAccount is a data object containing + // string accountNumber + // float balance + + virtual DataObjectPtr /* CheckingAccount*/ getCheckingAccount( + const string id); + + // SavingsAccount is a data object containing + // string accountNumber + // float balance + + virtual DataObjectPtr /* SavingsAccount */ getSavingsAccount( + const string id); + + // StockAccount is a data object containing + // string accountNumber + // string symbol + // int quantity + + virtual DataObjectPtr /* StockAccount */ getStockAccount ( + const string id); + + }; + + } // End accountdata +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountService.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountService.h new file mode 100644 index 0000000000..b8e462fb72 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountService.h @@ -0,0 +1,52 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "commonj/sdo/SDO.h" + +#include <string> +using std::string; + +namespace services +{ + namespace account + { + + /** + * AccountService business interface + */ + class AccountService + { + public: + + // The account report data object has one many-valued + // property "accountSummaries", containing the following + // properties: + // string accountNumber + // string accountType + // float balance. + + virtual commonj::sdo::DataObjectPtr /*AccountReport*/ + getAccountReport(const string customerID) = 0; + + }; + + } // End account +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountService.wsdl new file mode 100644 index 0000000000..cbfe180692 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountService.wsdl @@ -0,0 +1,126 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://www.bigbank.com/AccountService" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + targetNamespace="http://www.bigbank.com/AccountService" + name="AccountService"> + + <wsdl:types> + <xsd:schema + targetNamespace="http://www.bigbank.com/AccountService" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:element name="getAccountReport"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="customerID" + type="xsd:string" /> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + + <xsd:element name="getAccountReportResponse"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="result" + type="tns:AccountReport" /> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + + <xsd:complexType name="AccountReport"> + <xsd:sequence> + <xsd:element name="checking" + type="tns:CheckingAccount" maxOccurs="unbounded" /> + <xsd:element name="savings" + type="tns:SavingsAccount" maxOccurs="unbounded" /> + <xsd:element name="stocks" type="tns:StockAccount" + maxOccurs="unbounded" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="StockAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="symbol" type="xsd:string" /> + <xsd:element name="quantity" type="xsd:integer" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="CheckingAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="SavingsAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="getAccountReportRequest"> + <wsdl:part element="tns:getAccountReport" + name="getAccountReportRequest" /> + </wsdl:message> + + <wsdl:message name="getAccountReportResponse"> + <wsdl:part element="tns:getAccountReportResponse" + name="getAccountReportResponse" /> + </wsdl:message> + + <wsdl:portType name="AccountService"> + <wsdl:operation name="getAccountReport"> + <wsdl:input message="tns:getAccountReportRequest" /> + <wsdl:output message="tns:getAccountReportResponse" /> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="AccountServiceSOAP" type="tns:AccountService"> + <soap:binding style="document" + transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getAccountReport"> + <soap:operation + soapAction="http://www.bigbank.com/AccountService/getAccountReport" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="AccountService"> + <wsdl:port binding="tns:AccountServiceSOAP" + name="AccountServiceSOAP"> + <soap:address + location="http://localhost:9090/axis2/services/AccountService" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.componentType new file mode 100644 index 0000000000..b65fa1dc18 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.componentType @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="AccountService"> + <interface.cpp header="AccountService.h"/> + </service> + + <reference name="accountDataService"> + <interface.cpp header="AccountDataService.h"/> + </reference> + + <reference name="stockQuoteService"> + <interface.cpp header="StockQuoteService.h"/> + </reference> + + <property name="currency" type="xs:string">USD</property> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.cpp new file mode 100644 index 0000000000..fd18119bad --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.cpp @@ -0,0 +1,130 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#if defined(WIN32) || defined (_WINDOWS) +#pragma warning(disable: 4786) +#endif + +#include "osoa/sca/sca.h" + +#include "AccountServiceImpl.h" +#include "StockQuoteService.h" +#include "AccountDataService.h" + +using namespace osoa::sca; +using namespace services::accountdata; +using namespace services::stockquote; + +/** + * AccountServiceImpl component implementation + */ +namespace services +{ + namespace account + { + + DataObjectPtr /*AccountReport**/ + AccountServiceImpl::getAccountReport(const string customerID) + { + ComponentContext theContext = ComponentContext::getCurrent(); + + commonj::sdo::DataFactoryPtr factory = theContext.getDataFactory(); + + commonj::sdo::DataObjectPtr newReport = + factory->create("http://www.bigbank.com/AccountService","AccountReport"); + + // Get the accountDataService service + AccountDataService *dataService = + (AccountDataService*)theContext.getService("accountDataService"); + + // would be better to return a list of accounts - this only + // gets the first of each. + + commonj::sdo::DataObjectPtr checking = + dataService->getCheckingAccount(customerID); + + if (checking != 0) + { + commonj::sdo::DataObjectList& dl = newReport->getList("checking"); + checking->setFloat("balance", + fromUSDollarToCurrency(checking->getFloat("balance"))); + dl.append(checking); + } + + commonj::sdo::DataObjectPtr savings = dataService->getSavingsAccount(customerID); + + if (savings != 0) + { + commonj::sdo::DataObjectList& dl = newReport->getList("savings"); + savings->setFloat("balance", + fromUSDollarToCurrency(savings->getFloat("balance"))); + dl.append(savings); + } + + // Get the stockQuoteService service + StockQuoteService* stockService = + (StockQuoteService*)theContext.getService("stockQuoteService"); + + commonj::sdo::DataObjectPtr stocks = dataService->getStockAccount(customerID); + + if (stocks != 0) + { + commonj::sdo::DataObjectList& dl = newReport->getList("stocks"); + + float value = 10.0f; + try { + value = stockService->getQuote( + stocks->getCString("symbol")); + } + catch (ServiceRuntimeException& e) + { + std::cout << "Fault from stock quote service" << e << std::endl; + } + stocks->setFloat("balance", + fromUSDollarToCurrency(stocks->getInteger("quantity") * + value)); + dl.append(stocks); + } + + return newReport; + } + + float AccountServiceImpl::fromUSDollarToCurrency(float value) + { + // Get the "currency" property + ComponentContext myContext = ComponentContext::getCurrent(); + + commonj::sdo::DataObjectInstance properties = myContext.getProperties(); + if (properties) + { + const char* currency = properties->getCString("currency"); + if (currency != 0) + { + std::cout << "Currency is : " << currency << std::endl; + if (!strcmp(currency,"USD")) return value; + if (!strcmp(currency,"EURO")) return 0.8f * value; + } + } + return 0.0f; + } + + } // End account +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.h new file mode 100644 index 0000000000..70dfc17b19 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/AccountServiceImpl.h @@ -0,0 +1,44 @@ +/** + * + * 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 "AccountService.h" + + +namespace services +{ + namespace account + { + + /** + * AccountServiceImpl component implementation class + */ + class AccountServiceImpl: public AccountService + { + public: + + virtual DataObjectPtr /*AccountReport*/ + getAccountReport(const string customerID); + + private: + + float fromUSDollarToCurrency(float value); + + }; + + } // End account +} // End services + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/Makefile.am new file mode 100644 index 0000000000..a8fc73e3c0 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/Makefile.am @@ -0,0 +1,42 @@ +deploydir=$(prefix)/samples/BigBank/deploy +compositedir=$(deploydir)/bigbank.account + +BUILT_SOURCES = scagen + +noinst_HEADERS = *.h + +composite_SCRIPTS = runwsserver.sh + +scagen: + java -jar $(TUSCANY_SCACPP)/bin/scagen.jar -dir . -output . + +composite_LTLIBRARIES = libAccount.la +composite_DATA = *.composite *.componentType *.wsdl *.xsd +EXTRA_DIST = *.composite *.componentType *.wsdl *.xsd runwsserver.sh + +dist_libAccount_la_SOURCES = \ +AccountDataServiceImpl.cpp \ +AccountServiceImpl.cpp \ +StockQuoteServiceImpl.cpp + +nodist_libAccount_la_SOURCES = \ +AccountDataServiceImpl_AccountDataService_Proxy.cpp \ +AccountDataServiceImpl_AccountDataService_Wrapper.cpp \ +AccountServiceImpl_accountDataService_Proxy.cpp \ +AccountServiceImpl_AccountService_Proxy.cpp \ +AccountServiceImpl_AccountService_Wrapper.cpp \ +AccountServiceImpl_stockQuoteService_Proxy.cpp \ +StockQuoteServiceImpl_StockQuoteService_Proxy.cpp \ +StockQuoteServiceImpl_StockQuoteService_Wrapper.cpp \ +StockQuoteServiceImpl_webService_Proxy.cpp + +libAccount_la_LIBADD = \ +-L${TUSCANY_SCACPP}/lib \ + -ltuscany_sca \ +-L${TUSCANY_SCACPP}/extensions/cpp/lib \ + -ltuscany_sca_cpp + +INCLUDES = \ + -I$(TUSCANY_SCACPP)/extensions/cpp/include \ + -I$(TUSCANY_SCACPP)/include \ + -I${TUSCANY_SDOCPP}/include diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteService.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteService.h new file mode 100644 index 0000000000..d67998059a --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteService.h @@ -0,0 +1,36 @@ +/* + * + * Copyright 2006 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 <string> +using std::string; + +namespace services +{ + namespace stockquote + { + /** + * StockQuoteService business interface + */ + class StockQuoteService + { + public: + + virtual float getQuote(const string symbol) = 0; + + }; + + } // End stockquote +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.componentType new file mode 100644 index 0000000000..6ac2b77255 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.componentType @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. + --> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"> + + <service name="StockQuoteService"> + <interface.cpp header="StockQuoteService.h"/> + </service> + + <reference name="webService"> + <interface.cpp header="StockQuoteWebService.h"/> + </reference> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.cpp new file mode 100644 index 0000000000..e78769f50e --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.cpp @@ -0,0 +1,72 @@ +/* + * + * Copyright 2006 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. + */ + +#if defined(WIN32) || defined (_WINDOWS) +#pragma warning(disable: 4786) +#endif + +#include "StockQuoteServiceImpl.h" +#include "StockQuoteWebService.h" + +#include "osoa/sca/sca.h" +#include "commonj/sdo/SDO.h" + +using namespace osoa::sca; +using namespace commonj::sdo; + +/** + * StockQuoteServiceImpl component implementation + */ +namespace services { + namespace stockquote { + + // Map the format returned by the StockQuote Web service to + // the format expected in the BigBank application + float StockQuoteServiceImpl::getQuote(const string symbol) + { + ComponentContext myContext = ComponentContext::getCurrent(); + + // Get the StockQuote Web service + StockQuoteWebService* webService = + (StockQuoteWebService*)myContext.getService("webService"); + + // Invoke the service + const string result = webService->GetQuote(symbol); + + float stockPrice = 0.0f; + + // Get the stock price out of the document returned by the StockQuote + // Web service + try + { + XMLHelperPtr xmlHelper = HelperProvider::getXMLHelper(myContext.getDataFactory()); + XMLDocumentPtr stockDoc = xmlHelper->load(result); + if (stockDoc->getRootDataObject()) + { + stockPrice=stockDoc->getRootDataObject()->getFloat("Stock.0/Last"); + } + } + catch (SDORuntimeException e) + { + std::cout << e << std::endl; + return 0.0f; + } + return stockPrice; + } + + } // End stockquote +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.h new file mode 100644 index 0000000000..cccf161454 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteServiceImpl.h @@ -0,0 +1,36 @@ +/* + * + * Copyright 2006 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 "StockQuoteService.h" + +namespace services +{ + namespace stockquote + { + + /** + * StockQuoteServiceImpl component implementation class + */ + class StockQuoteServiceImpl : public StockQuoteService + { + public: + + virtual float getQuote(const string symbol); + }; + + } // End stockquote +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteTypes.xsd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteTypes.xsd new file mode 100644 index 0000000000..5bce3a63dc --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteTypes.xsd @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!-- + Copyright 2006 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. + --> + +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <xs:element name="StockQuotes" type="tStockQuotes"/> + <xs:complexType name="tStockQuotes"> + <xs:sequence> + <xs:element name="Stock" type="tStock" minOccurs="0" maxOccurs="unbounded"/> + <xs:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + <xs:anyAttribute namespace="##any" processContents="lax"/> + </xs:complexType> + + <xs:complexType name="tStock"> + <xs:sequence> + <xs:element minOccurs="0" maxOccurs="1" name="Symbol" type="xs:string"/> + <xs:element minOccurs="0" maxOccurs="1" name="Last" type="xs:float"/> + <xs:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + <xs:anyAttribute namespace="##any" processContents="lax"/> + </xs:complexType> +</xs:schema>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteWebService.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteWebService.h new file mode 100644 index 0000000000..9bee445c8d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteWebService.h @@ -0,0 +1,40 @@ +/* + * + * Copyright 2006 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 <string> +using std::string; + +namespace services +{ + namespace stockquote + { + + /** + * StockQuoteWebService business interface + * + * This is the interface of the Web service used to get + * live stock quotes. + */ + class StockQuoteWebService + { + public: + + virtual const string GetQuote(const string symbol) = 0; + + }; + + } // End stockquote +} // End services diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteWebService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteWebService.wsdl new file mode 100644 index 0000000000..c14f97c87b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/StockQuoteWebService.wsdl @@ -0,0 +1,165 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" + xmlns:tns="http://www.webserviceX.NET/" + xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + targetNamespace="http://www.webserviceX.NET/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:types> + <s:schema elementFormDefault="qualified" + targetNamespace="http://www.webserviceX.NET/"> + <s:element name="GetQuote"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="symbol" type="s:string" /> + </s:sequence> + </s:complexType> + + </s:element> + <s:element name="GetQuoteResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="GetQuoteResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="string" nillable="true" type="s:string" /> + + </s:schema> + </wsdl:types> + <wsdl:message name="GetQuoteSoapIn"> + <wsdl:part name="parameters" element="tns:GetQuote" /> + </wsdl:message> + <wsdl:message name="GetQuoteSoapOut"> + <wsdl:part name="parameters" element="tns:GetQuoteResponse" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpGetIn"> + + <wsdl:part name="symbol" type="s:string" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpGetOut"> + <wsdl:part name="Body" element="tns:string" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpPostIn"> + <wsdl:part name="symbol" type="s:string" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpPostOut"> + + <wsdl:part name="Body" element="tns:string" /> + </wsdl:message> + <wsdl:portType name="StockQuoteSoap"> + <wsdl:operation name="GetQuote"> + <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"> + Get Stock quote for a company Symbol + </documentation> + <wsdl:input message="tns:GetQuoteSoapIn" /> + <wsdl:output message="tns:GetQuoteSoapOut" /> + </wsdl:operation> + + </wsdl:portType> + <wsdl:portType name="StockQuoteHttpGet"> + <wsdl:operation name="GetQuote"> + <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"> + Get Stock quote for a company Symbol + </documentation> + <wsdl:input message="tns:GetQuoteHttpGetIn" /> + <wsdl:output message="tns:GetQuoteHttpGetOut" /> + </wsdl:operation> + </wsdl:portType> + + <wsdl:portType name="StockQuoteHttpPost"> + <wsdl:operation name="GetQuote"> + <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"> + Get Stock quote for a company Symbol + </documentation> + <wsdl:input message="tns:GetQuoteHttpPostIn" /> + <wsdl:output message="tns:GetQuoteHttpPostOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="StockQuoteSoap" type="tns:StockQuoteSoap"> + + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" + style="document" /> + <wsdl:operation name="GetQuote"> + <soap:operation + soapAction="http://www.webserviceX.NET/GetQuote" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="StockQuoteHttpGet" + type="tns:StockQuoteHttpGet"> + <http:binding verb="GET" /> + <wsdl:operation name="GetQuote"> + <http:operation location="/GetQuote" /> + <wsdl:input> + <http:urlEncoded /> + </wsdl:input> + + <wsdl:output> + <mime:mimeXml part="Body" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="StockQuoteHttpPost" + type="tns:StockQuoteHttpPost"> + <http:binding verb="POST" /> + <wsdl:operation name="GetQuote"> + <http:operation location="/GetQuote" /> + + <wsdl:input> + <mime:content type="application/x-www-form-urlencoded" /> + </wsdl:input> + <wsdl:output> + <mime:mimeXml part="Body" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="StockQuote"> + + <wsdl:port name="StockQuoteSoap" binding="tns:StockQuoteSoap"> + <soap:address + location="http://www.webservicex.net/stockquote.asmx" /> + </wsdl:port> + <wsdl:port name="StockQuoteHttpGet" + binding="tns:StockQuoteHttpGet"> + <http:address + location="http://www.webservicex.net/stockquote.asmx" /> + </wsdl:port> + <wsdl:port name="StockQuoteHttpPost" + binding="tns:StockQuoteHttpPost"> + <http:address + location="http://www.webservicex.net/stockquote.asmx" /> + </wsdl:port> + + </wsdl:service> +</wsdl:definitions>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/bigbank.account.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/bigbank.account.composite new file mode 100644 index 0000000000..7173d584d2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/bigbank.account.composite @@ -0,0 +1,49 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Copyright (c) 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. + --> +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="bigbank.account"> + + <service name="AccountService"> + <interface.wsdl interface="http://www.bigbank.com/AccountService#wsdl.interface(AccountService)"/> + <!-- The endpoint is optional --> + <!-- <binding.ws endpoint="http://www.bigbank.com/AccountService#wsdl.endpoint(AccountService/AccountServiceSOAP)"/> --> + <binding.ws/> + <reference>AccountServiceComponent</reference> + </service> + + <component name="AccountServiceComponent"> + <implementation.cpp library="Account" header="AccountServiceImpl.h"/> + <reference name="accountDataService">AccountDataServiceComponent</reference> + <reference name="stockQuoteService">StockQuoteServiceComponent</reference> + <property name="currency">EURO</property> + </component> + + <component name="AccountDataServiceComponent"> + <implementation.cpp library="Account" header="AccountDataServiceImpl.h"/> + </component> + + <component name="StockQuoteServiceComponent"> + <implementation.cpp library="Account" header="StockQuoteServiceImpl.h"/> + <reference name="webService">StockQuoteWebService</reference> + </component> + + <reference name="StockQuoteWebService"> + <interface.wsdl interface="http://www.webserviceX.NET/#wsdl.interface(StockQuoteSoap)"/> + <binding.ws endpoint="http://www.webserviceX.NET/#wsdl.endpoint(StockQuote/StockQuoteSoap)"/> + </reference> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/runwsserver.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/runwsserver.bat new file mode 100644 index 0000000000..f95d5136ef --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/runwsserver.bat @@ -0,0 +1,51 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo Using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo Using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo Using Axis2C installed at %AXIS2C_HOME% + +set APFULLDIR=%~d0%~p0 +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +rem Run the client +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\cpp\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %AXIS2C_HOME%\bin +.\axis2_http_server.exe + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/runwsserver.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/runwsserver.sh new file mode 100755 index 0000000000..eb20a3d670 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.account/runwsserver.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/extensions/cpp/lib:$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +cd $AXIS2C_HOME/bin +./axis2_http_server diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.accountmanagement.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.accountmanagement.composite new file mode 100644 index 0000000000..4bf2c35008 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.accountmanagement.composite @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="bigbank.accountmanagement"> + + <component name="bigbank.AccountManagementComponent"> + <implementation.composite name="bigbank.account"/> + </component> + +</composite> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/AccountClient.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/AccountClient.cpp new file mode 100644 index 0000000000..a0b9de5f76 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/AccountClient.cpp @@ -0,0 +1,129 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#if defined(WIN32) || defined (_WINDOWS) +#pragma warning(disable: 4786) +#endif + +#include "AccountService.h" +#include "osoa/sca/sca.h" +#include <iostream> +#include <stdlib.h> + +using namespace osoa::sca; +using namespace std; +using namespace services::account; +using namespace commonj::sdo; + +int main(int argc, char* argv[]) +{ + + if (argc != 2) + { + cout << "account_client: Argument must be the name of the account" << endl; + return 0; + } + try + { + + // Locate a service + CompositeContext myContext = CompositeContext::getCurrent(); + AccountService *accountService = + (AccountService*) myContext.locateService("AccountServiceComponent"); + if (accountService == 0) + { + cout << "account_client: Unable to find Account service" << endl; + } + else + { + try + { + // exercise the account service + + DataObjectPtr report = + accountService->getAccountReport(argv[1]); + + XMLHelperPtr xmlHelper = HelperProvider::getXMLHelper(myContext.getDataFactory()); + char* doc = xmlHelper->save(report, report->getType().getURI(), report->getType().getName()); + cout << "XML: " << doc <<endl; + + if (report != 0) + { + int i; + char balanceStr[20]; + float balance; + + cout << "My Account Report" << endl; + cout << "=================" << endl; + + DataObjectList& stocks = report->getList("stocks"); + + for (i=0;i< stocks.size() ;i++) + { + cout << "Stock Account " << stocks[i]->getCString("accountNumber") << endl; + cout << "Stock Symbol : " << stocks[i]->getCString("symbol") << endl; + cout << " Holding : " << stocks[i]->getCString("quantity") << endl; + balance = stocks[i]->getFloat("balance"); + sprintf(balanceStr,"%.2f",balance); + cout << " Value : " << balanceStr << endl << endl; + } + + DataObjectList& checking = report->getList("checking"); + + for (i=0;i< checking.size() ;i++) + { + cout << "Checking Account " << checking[i]->getCString("accountNumber") << endl; + balance = checking[i]->getFloat("balance"); + sprintf(balanceStr,"%.2f",balance); + cout << " Balance : " << balanceStr << endl << endl; + } + + DataObjectList& savings = report->getList("savings"); + + for (i=0;i< savings.size() ;i++) + { + cout << "Savings Account " << savings[i]->getCString("accountNumber") << endl; + balance = savings[i]->getFloat("balance"); + sprintf(balanceStr,"%.2f",balance); + cout << " Balance : " << balanceStr << endl << endl; + } + + cout << endl; + } + } + catch (SDORuntimeException& e) + { + cout << e << endl; + } + catch (char* x) + { + cout << "account_client: exception caught: " << x << endl; + } + } + + } + catch (ServiceRuntimeException& ex) + { + cout << ex << endl; + } + return 0; +} + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/Makefile.am new file mode 100644 index 0000000000..eb14b48580 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/Makefile.am @@ -0,0 +1,32 @@ +deploydir=$(prefix)/samples/BigBank/deploy +clientdir=$(deploydir)/bigbank.client + +client_PROGRAMS = account_client +client_SCRIPTS = runclient.sh +EXTRA_DIST = runclient.sh + +AM_CPPFLAGS = $(CPPFLAGS) +account_client_SOURCES = AccountClient.cpp + +account_client_LDADD = -L${TUSCANY_SCACPP}/lib -ltuscany_sca \ + -L${TUSCANY_SCACPP}/extensions/cpp/lib -ltuscany_sca_cpp \ + -L${TUSCANY_SDOCPP}/lib -ltuscany_sdo -ltuscany_sdo_axiom \ + -L$(AXIS2C_HOME)/lib \ + -laxis2_util \ + -laxis2_axiom \ + -laxis2_wsdl \ + -laxis2_engine \ + -lwoden \ + -lwoden_wsdl \ + -laxis2_xml_schema \ + -laxis2_parser \ + -laxis2_minizip \ + -lpthread \ + -laxis2_http_sender \ + -laxis2_http_receiver + + +INCLUDES = -I$(TUSCANY_SCACPP)/extensions/cpp/include \ + -I${TUSCANY_SCACPP}/include \ + -I${TUSCANY_SDOCPP}/include \ + -I../bigbank.account diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/runclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/runclient.bat new file mode 100644 index 0000000000..e8907e9302 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/runclient.bat @@ -0,0 +1,50 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo Using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo Using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo Using Axis2C installed at %AXIS2C_HOME% + +set APFULLDIR=%~d0%~p0 +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +rem Run the client +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\cpp\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +.\AccountClient.exe 1234 + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/runclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/runclient.sh new file mode 100755 index 0000000000..54f3c27578 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.client/runclient.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/extensions/cpp/lib:$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +./account_client 1234 + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/AccountService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/AccountService.wsdl new file mode 100644 index 0000000000..cbfe180692 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/AccountService.wsdl @@ -0,0 +1,126 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://www.bigbank.com/AccountService" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + targetNamespace="http://www.bigbank.com/AccountService" + name="AccountService"> + + <wsdl:types> + <xsd:schema + targetNamespace="http://www.bigbank.com/AccountService" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:element name="getAccountReport"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="customerID" + type="xsd:string" /> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + + <xsd:element name="getAccountReportResponse"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="result" + type="tns:AccountReport" /> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + + <xsd:complexType name="AccountReport"> + <xsd:sequence> + <xsd:element name="checking" + type="tns:CheckingAccount" maxOccurs="unbounded" /> + <xsd:element name="savings" + type="tns:SavingsAccount" maxOccurs="unbounded" /> + <xsd:element name="stocks" type="tns:StockAccount" + maxOccurs="unbounded" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="StockAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="symbol" type="xsd:string" /> + <xsd:element name="quantity" type="xsd:integer" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="CheckingAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="SavingsAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="getAccountReportRequest"> + <wsdl:part element="tns:getAccountReport" + name="getAccountReportRequest" /> + </wsdl:message> + + <wsdl:message name="getAccountReportResponse"> + <wsdl:part element="tns:getAccountReportResponse" + name="getAccountReportResponse" /> + </wsdl:message> + + <wsdl:portType name="AccountService"> + <wsdl:operation name="getAccountReport"> + <wsdl:input message="tns:getAccountReportRequest" /> + <wsdl:output message="tns:getAccountReportResponse" /> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="AccountServiceSOAP" type="tns:AccountService"> + <soap:binding style="document" + transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getAccountReport"> + <soap:operation + soapAction="http://www.bigbank.com/AccountService/getAccountReport" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="AccountService"> + <wsdl:port binding="tns:AccountServiceSOAP" + name="AccountServiceSOAP"> + <soap:address + location="http://localhost:9090/axis2/services/AccountService" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/README new file mode 100644 index 0000000000..d02873e860 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/README @@ -0,0 +1,137 @@ +Big Bank PHP Client +=================== + +Overview +-------- + +This is a pair of very simple PHP scripts to demonstrate how the Accounts service +that the C++ Big Bank sample exposes can be used from within the PHP scripting +language. + +bigwelcome.php + A bootstrap script that shows a form and allows the user to press a button + in order to invoke the bigaccount.php script + +bigaccount.php + Makes a call to a locally installed BigBank Accounts service. The script + shows how to use PHP SDO and SOAP extensions to construct the call + and interpret the result. + +As this is a very simple test client once you have reached bigaccount.php you are done. +So there are no further buttons other than the browser back button. + +Installation +------------ + +This assumes that you have the BigBank sample runnig as a web service in your local +Axis2C container at http://localhost:9090/axis2/services/AccountService + +To run the php scripts requires some configuration and setup of a php runtime with +the SDO and SimpleXML extensions enabled. The bits you will need are: + +Apache web server - http://httpd.apache.org/ (I'm currently at 2.0.55) +PHP 5.1.6 - http://www.php.net/downloads.php (I'm currently at 5.1.6) +PHP SDO - http://pecl.php.net/package/sdo (I'm currently at 1.0.3) + +Windows +------- +If you are on windows you can get binary builds from http://www.php.net/downloads.php. +For SDO you need two dlls as followd + +php_sdo.dll http://pecl4win.php.net/ext.php/php_sdo.dll +php_sdo_das_xml.dll http://pecl4win.php.net/ext.php/php_sdo_das_xml.dll + +I copied these to my php5.1.6/ext dir ( php_soap.dll is already there) + +And added the following to my php.ini file (having already renamed php.ini-recommended to +php.ini of course) + +extension=php_soap.dll +extension=php_sdo.dll +extension=php_sdo_das_xml.dll + +I also changed the extension_dir directive to point to my extensions directory: + +extension_dir="C:/simon/apps/php5.1.6/ext" + +When I ask PHP to list what modules are active in my version of PHP I get the +following + +C:\simon\apps\php5.1.6>php -m +[PHP Modules] +bcmath +calendar +com_dotnet +ctype +date +dom +ftp +hash +iconv +libxml +odbc +pcre +Reflection +sdo +sdo_das_xml +session +SimpleXML +soap +SPL +standard +tokenizer +wddx +xml +xmlreader +xmlwriter +zlib + +[Zend Modules] + +Of particular relevance to these scripts note that soap, sdo and sd_das_xml are active. + +Other Platforms +--------------- + +If your on on another platform, such as Linux, then you will need to compile the +SDO extension. The documentation at the SDO extension page (http://livedocs.phpdoc.info/index.php?l=en&q=ref.sdo) +is currently a bit missleading and needs updating. What you need to do is do a +phpize build of the SDO PECL extension. This is discussed in the SDO documentation +but is also discussed in many other places, for example, http://www.php.net/manual/en/install.pecl.phpize.php. +Here is not the time to go into the details of how to build PHP extensions using +phpize but if you are familar with the process I use the following configure line +on windows. + +cscript configure.js --with-extra-includes=c:\simon\projects\tuscany\php\win32build\include; + c:\simon\apps\libxml2-2.6.23.win32\include; + c:\simon\apps\iconv-1.9.1.win32\include + --with-extra-libs=c:\simon\projects\tuscany\php\win32build\lib; + c:\simon\apps\libxml2-2.6.23.win32\lib; + c:\simon\apps\iconv-1.9.1.win32\lib + --enable-sdo=shared + --enable-soap + +There are no newlines in my command line by the way. I've just included them +here so you can see the command. + +Running +------- + +You need to configure Apache to run PHP of course. This is well documented but this +is what I put at the end of httpd.conf + +# PHP5 Support +LoadModule php5_module "C:/simon/apps/php5.1.6/php5apache2.dll" +AddType application/x-httpd-php .php + +# configure the path to php.ini +PHPIniDir "C:/simon/apps/php5.1.6" + +Having set up Apache all that remains is to + +- put the bigbank.phpwsclient directory in your web server's root documents directory +- start up the Axis2C runtime configured to run BigBank +- point your browser at http://myserver:port/bigbank.phpwsclient/bigwelcome.php + +You should now be able to press the "GetAccount" button and see the values +returned from the BigBank SCA application. diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/bigaccount.php b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/bigaccount.php new file mode 100644 index 0000000000..b9f77d3297 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/bigaccount.php @@ -0,0 +1,113 @@ +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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 $ +--> +<head> + <title>BigBank Sample</title> +</head> + +<body BGCOLOR="#EFEFEF"> + +<script type="text/javascript"></script> + +<?php + try + { + // In case we want to see what's in the request + //print_r ($_POST); + + // get the entered account name + $accountname = $_POST['accountname']; + + try + { + // configure the SOAP client + $client = new SoapClient("AccountService.wsdl"); + + // make the call but its a wrapped call so we + // can't just do... + // $result = $client->getAccountReport($accountname); + // we have to construct an object hierarchy that matches the + // WSDL request. We can use SDO to do this for us + + // configure SDO based on the WSDL + $xmldas = SDO_DAS_XML::create("AccountService.wsdl"); + + // Get a document that represents the request + // and get the root element + $requestxdoc = $xmldas->createDocument("getAccountReport"); + $requestsdo = $requestxdoc->getRootDataObject(); + + // add the parameter + $requestsdo['customerID'] = $accountname; + + // make the call + $result = $client->getAccountReport($requestsdo); + + // now we have the result as a PHP object + // we can turn this into an SDO but we have to do it manually + // as the SOAP extension won't generate types for us + // automatically just yet + $responsexdoc = $xmldas->createDocument("getAccountReportResponse"); + $responsesdo = $responsexdoc->getRootDataObject(); + + // flesh out the object hierarchy + $account = $responsesdo->createDataObject ('result'); + $checking = $account->createDataObject ('checking'); + $saving = $account->createDataObject ('savings'); + $stocks = $account->createDataObject ('stocks'); + + //copy the data + $checking['accountNumber'] = $result->result->checking->accountNumber; + $checking['balance'] = $result->result->checking->balance; + //etc.. + // This is a bit rubbish as we would want this to happen automatically + + // Now just put the data on the screen + // To do this we don't need to use SDO as you can see but + // it would be really handy if we wanted to pass the XML doc + // onto another service or if we wanted to do some other + // more complex XML manipulation or XPath searches + echo "<h2>Account $accountname</h2>"; + echo "<h2>Checking Account</h2><table>"; + echo "<tr><td>Account Number</td><td> $checking->accountNumber </td></tr>"; + echo "<tr><td>Balance</td><td> $checking->balance </td></tr>"; + echo "</table><h2>Saving Account</h2><table>"; + echo "<tr><td>Account Number</td><td>" . $result->result->savings->accountNumber . "</td></tr>"; + echo "<tr><td>Balance</td><td>" . $result->result->savings->balance . "</td></tr>"; + echo "</table><h2>Stock Account</h2><table>"; + echo "<tr><td>Account Number</td><td>" . $result->result->stocks->accountNumber . "</td></tr>"; + echo "<tr><td>Symbol</td><td>" . $result->result->stocks->symbol . "</td></tr>"; + echo "<tr><td>Quantity</td><td>" . $result->result->stocks->quantity . "</td></tr>"; + echo "<tr><td>Banalce</td><td>" . $result->result->stocks->balance . "</td></tr>"; + echo "</table>"; + } + catch (SoapFault $f) + { + echo "Caught soap exception: \n"; + print_r ( $f ); + } + } + catch ( Exception $e ) + { + echo "Caught exception: \n"; + print_r ( $e ); + + } +?> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/bigwelcome.php b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/bigwelcome.php new file mode 100644 index 0000000000..32159ddc16 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.phpwsclient/bigwelcome.php @@ -0,0 +1,44 @@ +<html> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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 $ +--> +<head> + <title>BigBank Sample</title> +</head> + +<body BGCOLOR="#EFEFEF"> + +<script type="text/javascript"></script> + +<?php +define('APP_ROOT', $_SERVER['SERVER_NAME'].':'.$_SERVER['SERVER_PORT'].'/bigbank.phpwsclient'); +?> + +<h1>Welcome To The BigBank Sample</h1> + + <form action="http://<?php echo APP_ROOT . '/bigaccount.php' ?>" method="POST"> + Please enter your account ID + <input type="text" name="accountname" size="30" value="ED" /> + <button type="submit">GetAccount</button> + </form> + + <div id="statusString"/> +</body> +</html> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/AccountWSClient.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/AccountWSClient.cpp new file mode 100644 index 0000000000..b31959170f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/AccountWSClient.cpp @@ -0,0 +1,184 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "axis2_Account_stub.h" +#include <stdio.h> +#include <axiom.h> +#include <axis2_util.h> +#include <axiom_soap.h> +#include <axis2_client.h> + +axiom_node_t * +build_om_programatically(const axis2_env_t *env, + const axis2_char_t *operation, + const axis2_char_t *param1 + ); + +int main(int argc, char** argv) +{ + axis2_stub_t *stub = NULL; + axiom_node_t *node = NULL; + axis2_status_t status = AXIS2_FAILURE; + const axis2_env_t *env = NULL; + const axis2_char_t *address = NULL; + const axis2_char_t *client_home = NULL; + axiom_node_t *ret_node = NULL; + + const axis2_char_t *operation = "getAccountReport"; + const axis2_char_t *param1 = "ED"; + + env = axis2_env_create_all( "BigBank_blocking.log", AXIS2_LOG_LEVEL_TRACE); + + client_home = AXIS2_GETENV("AXIS2C_HOME"); + if (!client_home) + client_home = "../../deploy"; + + address = "http://localhost:9090/axis2/services/AccountService"; + if (argc > 1 ) + operation = argv[1]; + if (AXIS2_STRCMP(operation, "-h") == 0) + { + printf("Usage : %s [operation] [param1] [endpoint_url]\n", argv[0]); + printf("use -h for help\n"); + printf("default operation add\n"); + printf("default param1 %s\n", param1); + printf("default endpoint_url %s\n", address); + printf("NOTE: command line arguments must appear in given order, with trailing ones being optional\n"); + return 0; + } + if (argc > 2 ) + param1 = argv[2]; + if (argc > 3 ) + address = argv[3]; + + printf ("Using endpoint : %s\n", address); + printf ("\nInvoking operation %s with param %s \n", operation, param1); + + node = build_om_programatically(env, operation, param1); + stub = + axis2_Account_stub_create_with_endpoint_uri_and_client_home(env, address, client_home); + /* create node and invoke Calculator */ + ret_node = axis2_Account_stub_getAccountReport(stub, env, node); + if(ret_node) + { + axis2_char_t *om_str = NULL; + om_str = AXIOM_NODE_TO_STRING(ret_node, env); + if(om_str) + { + printf("\nOM returned = %s\n", om_str); + } + + //if (AXIOM_NODE_GET_NODE_TYPE(ret_node, env) == AXIOM_ELEMENT) + //{ + // axis2_char_t *result = NULL; + // axiom_node_t *result_node = (axiom_node_t*)AXIOM_NODE_GET_FIRST_CHILD(ret_node, env); + // axiom_element_t *data_ele = (axiom_element_t*)AXIOM_NODE_GET_DATA_ELEMENT(result_node, env); + + // result = AXIOM_ELEMENT_GET_TEXT(data_ele, env, result_node); + // printf( "\nResult = %s\n", result); + //} + //else + //{ + // axiom_xml_writer_t *writer = NULL; + // axiom_output_t *om_output = NULL; + // axis2_char_t *buffer = NULL; + // writer = axiom_xml_writer_create_for_memory(env, NULL, AXIS2_TRUE, 0, + // AXIS2_XML_PARSER_TYPE_BUFFER); + // om_output = axiom_output_create (env, writer); + + // AXIOM_NODE_SERIALIZE (ret_node, env, om_output); + // buffer = (axis2_char_t*)AXIOM_XML_WRITER_GET_XML(writer, env); + // printf ("\nReceived invalid OM as result : %s\n", buffer); + // if(NULL != buffer) + // { + // AXIS2_FREE(env->allocator, buffer); + // buffer = NULL; + // } + // if(NULL != om_output) + // { + // AXIOM_OUTPUT_FREE(om_output, env); + // om_output = NULL; + // } + //} + } + else + { + AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Stub invoke FAILED: Error code:" + " %d :: %s", env->error->error_number, + AXIS2_ERROR_GET_MESSAGE(env->error)); + printf("Account stub invoke FAILED!\n"); + } + if (stub) + { + AXIS2_STUB_FREE(stub, env); + } + return status; +} + +axiom_node_t * +build_om_programatically(const axis2_env_t *env, + const axis2_char_t *operation, + const axis2_char_t *param1 + ) +{ + axiom_node_t *Account_om_node = NULL; + axiom_element_t* Account_om_ele = NULL; + axiom_node_t* text_om_node = NULL; + axiom_element_t * text_om_ele = NULL; + axiom_node_t* first_om_node = NULL; + axiom_element_t * first_om_ele = NULL; + axiom_namespace_t *ns1 = NULL; + + + axiom_xml_writer_t *xml_writer = NULL; + axiom_output_t *om_output = NULL; + axis2_char_t *buffer = NULL; + + ns1 = axiom_namespace_create (env, "http://www.bigbank.com/AccountService", "ns1"); + + Account_om_ele = axiom_element_create(env, NULL, operation, ns1, &Account_om_node); + + first_om_ele = axiom_element_create(env, Account_om_node, "customerID", NULL, &first_om_node); + + text_om_ele = axiom_element_create(env, first_om_node, "customerID", NULL, &text_om_node); + + AXIOM_ELEMENT_SET_TEXT(text_om_ele, env, param1, text_om_node); + + xml_writer = axiom_xml_writer_create_for_memory(env, NULL, AXIS2_FALSE, AXIS2_FALSE, + AXIS2_XML_PARSER_TYPE_BUFFER); + om_output = axiom_output_create( env, xml_writer); + + AXIOM_NODE_SERIALIZE(Account_om_node, env, om_output); + buffer = (axis2_char_t*)AXIOM_XML_WRITER_GET_XML(xml_writer, env); + AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI, "\nSending OM node in XML : %s \n", buffer); + if(NULL != buffer) + { + AXIS2_FREE(env->allocator, buffer); + buffer = NULL; + } + if(NULL != om_output) + { + AXIOM_OUTPUT_FREE(om_output, env); + om_output = NULL; + } + + return Account_om_node; +} diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/Makefile.am new file mode 100644 index 0000000000..f904b44182 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/Makefile.am @@ -0,0 +1,27 @@ +deploydir=$(prefix)/samples/BigBank/deploy +wsclientdir=$(deploydir)/bigbank.wsclient + +wsclient_PROGRAMS = account_wsclient +wsclient_SCRIPTS = runwsclient.sh +EXTRA_DIST = runwsclient.sh + +AM_CPPFLAGS = $(CPPFLAGS) +account_wsclient_SOURCES = axis2_Account_stub.cpp AccountWSClient.cpp +noinst_HEADERS = *.h + +account_wsclient_LDADD = -L$(AXIS2C_HOME)/lib \ + -laxis2_util \ + -laxis2_axiom \ + -laxis2_wsdl \ + -laxis2_engine \ + -lwoden \ + -lwoden_wsdl \ + -laxis2_xml_schema \ + -laxis2_parser \ + -laxis2_minizip \ + -lpthread \ + -laxis2_http_sender \ + -laxis2_http_receiver + + +INCLUDES = -I${AXIS2C_HOME}/include diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/axis2_Account_stub.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/axis2_Account_stub.cpp new file mode 100644 index 0000000000..a219003a75 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/axis2_Account_stub.cpp @@ -0,0 +1,111 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "axis2_Account_stub.h" + + +axis2_stub_t * +axis2_Account_stub_create_with_endpoint_ref_and_client_home(const axis2_env_t *env, + axis2_endpoint_ref_t *endpoint_ref, + axis2_char_t *client_home) +{ + axis2_stub_t *stub = NULL; + + AXIS2_ENV_CHECK(env, NULL); + + stub = (axis2_stub_t *) + axis2_stub_create_with_endpoint_ref_and_client_home(env, endpoint_ref, + client_home); + if(NULL == stub) + { + AXIS2_ERROR_SET(env->error, + AXIS2_ERROR_NO_MEMORY, (axis2_status_codes)AXIS2_FAILURE); + return NULL; + } + axis2_populate_axis_service( stub, env); + return stub; +} + +void axis2_populate_axis_service( axis2_stub_t* stub, const axis2_env_t *env) +{ + axis2_svc_client_t* svc_client = NULL; + axis2_qname_t *op_qname = NULL; + axis2_svc_t* svc = NULL; + axis2_op_t* op = NULL; + + /*Modifying the Service*/ + svc_client = AXIS2_STUB_GET_SVC_CLIENT (stub, env ); + svc = (axis2_svc_t*)AXIS2_SVC_CLIENT_GET_AXIS_SERVICE ( svc_client, env ); + + /*creating the operations*/ + + op_qname = axis2_qname_create(env,"getAccountReport" , "", NULL); + op = axis2_op_create_with_qname(env, op_qname); + AXIS2_OP_SET_MSG_EXCHANGE_PATTERN(op, env, AXIS2_MEP_URI_OUT_IN); + AXIS2_SVC_ADD_OP(svc, env, op); + + } + +axis2_stub_t * +axis2_Account_stub_create_with_endpoint_uri_and_client_home(const axis2_env_t *env, + const axis2_char_t *endpoint_uri, + const axis2_char_t *client_home) +{ + axis2_stub_t *stub = NULL; + + AXIS2_ENV_CHECK(env, NULL); + + stub = (axis2_stub_t *) + axis2_stub_create_with_endpoint_uri_and_client_home(env, endpoint_uri, + client_home); + if(NULL == stub) + { + AXIS2_ERROR_SET(env->error, + AXIS2_ERROR_NO_MEMORY, (axis2_status_codes)AXIS2_FAILURE); + return NULL; + } + + axis2_populate_axis_service( stub, env); + + return stub; +} + +/***************************Function implementation****************************/ + +axiom_node_t * +axis2_Account_stub_getAccountReport(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node) +{ + axis2_svc_client_t *svc_client = NULL; + axiom_node_t *ret_node = NULL; + axis2_qname_t *op_qname = NULL; + + AXIS2_ENV_CHECK(env, AXIS2_FAILURE); + + svc_client = AXIS2_STUB_GET_SVC_CLIENT(stub, env); + op_qname = axis2_qname_create(env, "getAccountReport" , "", NULL); + ret_node = AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME( svc_client, env, op_qname, node); + + return ret_node; +} + + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/axis2_Account_stub.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/axis2_Account_stub.h new file mode 100644 index 0000000000..f16b6d3a06 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/axis2_Account_stub.h @@ -0,0 +1,71 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef AXIS2_ECHO_STUB_H +#define AXIS2_ECHO_STUB_H + +/** + * @file axis2_Calculator_stub.h + * @brief axis2 Calculator stub interface + */ + +#include <axis2_stub.h> + +#ifdef __cplusplus +extern "C" +{ +#endif + +axiom_node_t * +axis2_Account_stub_getAccountReport(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node); + +/** + * populate services + */ +void axis2_populate_axis_service( axis2_stub_t* stub, const axis2_env_t *env); + +/** + * Creates axis2_stub struct + * @param endpoint reference + * @return pointer to newly created axis2_stub struct + */ +axis2_stub_t * +axis2_Account_stub_create_with_endpoint_ref_and_client_home(const axis2_env_t *env, + axis2_endpoint_ref_t *endpoint_ref, + axis2_char_t *client_home); + +/** + * Creates axis2_stub struct + * @param endpoint uri + * @return pointer to newly created axis2_stub struct + */ +axis2_stub_t * +axis2_Account_stub_create_with_endpoint_uri_and_client_home(const axis2_env_t *env, + const axis2_char_t *endpoint_uri, + const axis2_char_t *client_home); +/** @} */ + +#ifdef __cplusplus +} +#endif +#endif /* AXIS2_ECHO_STUB_H */ diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/runwsclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/runwsclient.bat new file mode 100644 index 0000000000..aa3f7d6dad --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/runwsclient.bat @@ -0,0 +1,32 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + + +setlocal + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo Using Axis2C installed at %AXIS2C_HOME%" + +rem Run the client +WSAccountClient.exe %* +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/runwsclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/runwsclient.sh new file mode 100755 index 0000000000..fa7d7d6813 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/bigbank.wsclient/runwsclient.sh @@ -0,0 +1,31 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +export LD_LIBRARY_PATH=$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +./account_wsclient + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deploy.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deploy.bat new file mode 100644 index 0000000000..2f1bdf1423 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deploy.bat @@ -0,0 +1,67 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA BigBank sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + +set package=bigbank.account + +set deploydir=%TUSCANY_SCACPP% +set samplesdir=%deploydir%\samples +set bbdir=%samplesdir%\BigBank +set bbdeploydir=%bbdir%\deploy +set samplebb=%bbdeploydir%\%package% + +if not exist %samplesdir% mkdir %samplesdir% +if not exist %bbdir% mkdir %bbdir% +if not exist %bbdeploydir% mkdir %bbdeploydir% +if not exist %samplebb% mkdir %samplebb% + +set samplebbsrc=%srcdir%\%package% +copy %srcdir%\bigbank.accountmanagement.composite %bbdeploydir% +copy %samplebbsrc%\*.wsdl %samplebb% +copy %samplebbsrc%\*.composite %samplebb% +copy %samplebbsrc%\*.componentType %samplebb% +copy %samplebbsrc%\runwsserver.bat %samplebb% + +set library=Account +copy %inpath%\%library%.dll %samplebb% + +if exist %inpath%\%library%.pdb copy %inpath%\%library%.pdb %samplebb% + +goto end +:usage +echo Usage: deploy <sample-src> <build-output> +:end + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deployclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deployclient.bat new file mode 100644 index 0000000000..1f47e5ab13 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deployclient.bat @@ -0,0 +1,63 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA BigBank sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + +set package=bigbank.client + +set deploydir=%TUSCANY_SCACPP% +set samplesdir=%deploydir%\samples +set bbdir=%samplesdir%\BigBank +set bbdeploydir=%bbdir%\deploy +set clientdir=%bbdeploydir%\%package% + +if not exist %samplesdir% mkdir %samplesdir% +if not exist %bbdir% mkdir %bbdir% +if not exist %bbdeploydir% mkdir %bbdeploydir% +if not exist %clientdir% mkdir %clientdir% + +set clientdirsrc=%srcdir%\%package% +copy %clientdirsrc%\runclient.bat %clientdir% + +set library=AccountClient +copy %inpath%\%library%.exe %clientdir% + +if exist %inpath%\%library%.pdb copy %inpath%\%library%.pdb %clientdir% + +goto end +:usage +echo Usage: deploy <sample-src> <build-output> +:end + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deploywsclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deploywsclient.bat new file mode 100644 index 0000000000..3e2ce687fe --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/BigBank/deploywsclient.bat @@ -0,0 +1,63 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA BigBank sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + +set package=bigbank.wsclient + +set deploydir=%TUSCANY_SCACPP% +set samplesdir=%deploydir%\samples +set bbdir=%samplesdir%\BigBank +set bbdeploydir=%bbdir%\deploy +set clientdir=%bbdeploydir%\%package% + +if not exist %samplesdir% mkdir %samplesdir% +if not exist %bbdir% mkdir %bbdir% +if not exist %bbdeploydir% mkdir %bbdeploydir% +if not exist %clientdir% mkdir %clientdir% + +set clientdirsrc=%srcdir%\%package% +copy %clientdirsrc%\runwsclient.bat %clientdir% + +set library=WSAccountClient +copy %inpath%\%library%.exe %clientdir% + +if exist %inpath%\%library%.pdb copy %inpath%\%library%.pdb %clientdir% + +goto end +:usage +echo Usage: deploy <sample-src> <build-output> +:end + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/COPYING b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/COPYING new file mode 100755 index 0000000000..6b0b1270ff --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/COPYING @@ -0,0 +1,203 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + 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. + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/Makefile.am new file mode 100644 index 0000000000..855bf1e44f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/Makefile.am @@ -0,0 +1,4 @@ +deploydir=$(prefix)/samples/Calculator/deploy +SUBDIRS = sample.calculator sample.calculator.client sample.calculator.wsclient +EXTRA_DIST = *.composite README.html +deploy_DATA = *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/README new file mode 100644 index 0000000000..4104ff46b6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/README @@ -0,0 +1,23 @@ +Tuscany SCA for C++ Samples - Calculator Sample +=============================================== + +This is a very simple sample to show how an SCA composite can wire together +two components to implement a Calculator service and expose that service as +a Web Service. + +There are three sub projects in this workspace: + - sample.calculator + This contains the source code and SCDL artifacts for the SCA Calculator. + composite implementing the sample Calculator. + + - sample.calculator.client + A sample client which does a local call to the Calculator service. + + - sample.calculator.wsclient + A sample Axis2 Web Service client which calls the Calculator Web service. + +Additionally, there is the sample.calculator.solution.composite file. This +describes the configuration of the SCA Calculator composite deployed to the +SCA runtime. + +See the README.html file for instructions to build and run this sample diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/README.html b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/README.html new file mode 100644 index 0000000000..c60d7b36f1 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/README.html @@ -0,0 +1,250 @@ + +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<!-- + Copyright 2006 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. + --> +<HTML> +<HEAD> + <META CONTENT="text/html; charset=iso-8859-1" HTTP-EQUIV="Content-Type"> + <META CONTENT="text/css" HTTP-EQUIV="Content-Style-Type"> + <STYLE MEDIA="all" TYPE="text/css"> +@import url("../../doc/css/maven-base.css"); +@import url("../../doc/css/maven-theme.css"); + </STYLE> + + <LINK HREF="../doc/css/maven-theme.css" MEDIA="print" REL="stylesheet" + TYPE="text/css"> + <TITLE>Tuscany SCA for C++ Samples - Calculator Sample</TITLE> +</HEAD> + +<BODY> +<DIV ID="bodyColumn"> + <DIV ID="contentBox"> + <DIV CLASS="section"> + <H2>Tuscany SCA for C++ Samples - Calculator Sample</H2> + + <P>This is a very simple sample to show how an SCA composite can wire + together two C++ components to implement a Calculator service and expose + that service as a Web Service. + </P> + <P>There are three sub projects in this workspace:</P> + <UL> + <LI>sample.calculator<BR/> + This contains the source code and SCDL artifacts for the SCA Calculator + composite implementing the sample Calculator. + </LI> + <LI>sample.calculator.client<BR/> + A sample client which does a local call to the Calculator service. + </LI> + <LI>sample.calculator.wsclient<BR/> + A sample Axis2 Web Service client which calls the Calculator Web service. + </LI> + </UL> + <P>Additionally, there is the sample.calculator.solution.composite file. This + describes the configuration of the SCA Calculator composite deployed to the SCA + runtime. + </P> + </DIV> + + <DIV CLASS="section"> + <H2>Contents</H2> + <OL> + <LI><A HREF="#linuxbld">Building the C++ samples on Linux</A></LI> + <LI><A HREF="#linuxrun">Running the Calculator sample on Linux:</A></LI> + <UL> + <LI><A HREF="#linuxbasic">Running the basic client</A></LI> + <LI><A HREF="#linuxws">Running the Web Service client</A></LI> + </UL> + <LI><A HREF="#winbld">Building the Calculator sample on Windows</A></LI> + <LI><A HREF="#winrun">Running the Calculator sample on Windows:</A></LI> + <UL> + <LI><A HREF="#winbasic">Running the basic client</A></LI> + <LI><A HREF="#winws">Running the Web Service client</A></LI> + </UL> + <LI><A HREF="#help">Getting help</A></LI> + </OL> + </DIV> + + + <DIV CLASS="section"> + <A NAME="linuxbld"><H2>Building the C++ samples on Linux</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#linuxrun">Running the samples on Linux</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>Build the C++ samples with the following command sequence: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples</LI> + <LI>./configure --prefix=$TUSCANY_SCACPP</LI> + <LI>make</LI> + <LI>make install</LI> + </UL> + NOTE: If you don't provide the --prefix configure option, it will by default install into + /usr/local/tuscany/sca/samples/Calculator</LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="linuxrun"><H2>Running the Calculator sample on Linux</H2></A> + <A NAME="linuxbasic"><H3>Calculator with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.92></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/Calculator/deploy/sample.calculator.client</LI> + <LI>./runclient.sh</LI> + </UL> + </LI> + </OL> + <A NAME="linuxws"><H3>Calculator with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/Calculator/deploy/sample.calculator + </LI> + <LI>./runwsserver.sh</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variable is required: + <UL> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/Calculator/deploy/sample.calculator.wsclient</LI> + <LI>./runwsclient.sh</LI> + </OL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winbld"><H2>Building the Calculator sample on Windows</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#winrun">Running the samples on Windows</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>You must have set up the environment for Microsoft Visual C++ tools. + The build command will call vcvars32 to set the environment. Ensure the + directory containing this is on your path. This will be where you + installed the compiler. + </LI> + <LI>Build the source, either via the Visual Studio 6 or 7 projects under + <tuscany_sca_install_dir>\samples\ides or via the command-line build file + found at <tuscany_sca_install_dir>\samples\ides\devstudio6\projects\Calculator\build.cmd + which will build and deploy the samples. + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winrun"><H2>Running the Calculator sample on Windows</H2></A> + <A NAME="winbasic"><H3>Calculator with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/Calculator/deploy/sample.calculator.client</LI> + <LI>./runclient.bat</LI> + </UL> + </LI> + </OL> + <A NAME="winws"><H3>Calculator with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/Calculator/deploy/sample.calculator</LI> + <LI>./runwsserver.bat</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variable is required: + <UL> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/Calculator/deploy/sample.calculator.wsclient</LI> + <LI>./runwsclient.bat</LI> + </OL> + </LI> + </OL> + </DIV> + + + + <DIV CLASS="section"> + <A NAME="help"><H2>Getting Help</H2></A> + + <P>First place to look is at the Tuscany FAQ at + <A HREF="http://incubator.apache.org/tuscany/faq.html" + TARGET="_blank">http://incubator.apache.org/tuscany/faq.html</A> </P> + + <P>Any problem with this release can be reported to the Tuscany + <A HREF="http://incubator.apache.org/tuscany/mail-lists.html" + TARGET="_blank">mailing lists</A> or create a JIRA issue at <A HREF="http://issues.apache.org/jira/browse/Tuscany" + TARGET="_blank">http://issues.apache.org/jira/browse/Tuscany</A>.</P> + </DIV> + </DIV> +</DIV> +</BODY> + +</HTML> + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deploy.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deploy.bat new file mode 100644 index 0000000000..efd18e8219 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deploy.bat @@ -0,0 +1,67 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA Calculator sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + +set package=sample.calculator + +set deploydir=%TUSCANY_SCACPP% +set samplesdir=%deploydir%\samples +set calcdir=%samplesdir%\Calculator +set calcdeploydir=%calcdir%\deploy +set samplecalc=%calcdeploydir%\%package% + +if not exist %samplesdir% mkdir %samplesdir% +if not exist %calcdir% mkdir %calcdir% +if not exist %calcdeploydir% mkdir %calcdeploydir% +if not exist %samplecalc% mkdir %samplecalc% + +set samplecalcsrc=%srcdir%\%package% +copy %srcdir%\%package%.solution.composite %calcdeploydir% +copy %samplecalcsrc%\*.wsdl %samplecalc% +copy %samplecalcsrc%\*.composite %samplecalc% +copy %samplecalcsrc%\*.componentType %samplecalc% +copy %samplecalcsrc%\runwsserver.bat %samplecalc% + +set library=Calculator +copy %inpath%\%library%.dll %samplecalc% + +if exist %inpath%\%library%.pdb copy %inpath%\%library%.pdb %samplecalc% + +goto end +:usage +echo Usage: deploy <sample-src> <build-output> +:end + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deployclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deployclient.bat new file mode 100644 index 0000000000..bf4fd47d43 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deployclient.bat @@ -0,0 +1,63 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA Calculator sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + +set package=sample.calculator.client + +set deploydir=%TUSCANY_SCACPP% +set samplesdir=%deploydir%\samples +set calcdir=%samplesdir%\Calculator +set calcdeploydir=%calcdir%\deploy +set clientdir=%calcdeploydir%\%package% + +if not exist %samplesdir% mkdir %samplesdir% +if not exist %calcdir% mkdir %calcdir% +if not exist %calcdeploydir% mkdir %calcdeploydir% +if not exist %clientdir% mkdir %clientdir% + +set clientdirsrc=%srcdir%\%package% +copy %clientdirsrc%\runclient.bat %clientdir% + +set library=calculator_client +copy %inpath%\%library%.exe %clientdir% + +if exist %inpath%\%library%.pdb copy %inpath%\%library%.pdb %clientdir% + +goto end +:usage +echo Usage: deploy <sample-src> <build-output> +:end + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deploywsclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deploywsclient.bat new file mode 100644 index 0000000000..8b1b1a53c5 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/deploywsclient.bat @@ -0,0 +1,63 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA Calculator sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + +set package=sample.calculator.wsclient + +set deploydir=%TUSCANY_SCACPP% +set samplesdir=%deploydir%\samples +set calcdir=%samplesdir%\Calculator +set calcdeploydir=%calcdir%\deploy +set clientdir=%calcdeploydir%\%package% + +if not exist %samplesdir% mkdir %samplesdir% +if not exist %calcdir% mkdir %calcdir% +if not exist %calcdeploydir% mkdir %calcdeploydir% +if not exist %clientdir% mkdir %clientdir% + +set clientdirsrc=%srcdir%\%package% +copy %clientdirsrc%\runwsclient.bat %clientdir% + +set library=calculator_wsclient +copy %inpath%\%library%.exe %clientdir% + +if exist %inpath%\%library%.pdb copy %inpath%\%library%.pdb %clientdir% + +goto end +:usage +echo Usage: deploy <sample-src> <build-output> +:end + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/CalculatorClient.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/CalculatorClient.cpp new file mode 100644 index 0000000000..9ec8b04bd1 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/CalculatorClient.cpp @@ -0,0 +1,160 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "Calculator.h" + +#include "osoa/sca/sca.h" +using namespace osoa::sca; + +#include "tuscany/sca/core/TuscanyRuntime.h" +using namespace tuscany::sca; + +#include <iostream> +#include <stdlib.h> +using namespace std; + + +void usage(); +bool IsNumber(const char *p); + +int main(int argc, char* argv[]) +{ + const char *operation; + float arg1 = 0; + float arg2 = 0; + + if (argc == 4) + { + operation = argv[1]; + + if (!IsNumber(argv[2])) + { + cout << "calculator_client: Argument 1 is not a number" << endl; + usage(); + } + else + { + arg1 = atof(argv[2]); + } + + if (!IsNumber(argv[3])) + { + cout << "calculator_client: Argument 2 is not a number" << endl; + usage(); + } + else + { + arg2 = atof(argv[3]); + } + } + else + { + usage(); + } + + try + { + // Locate a service + CompositeContext myContext = CompositeContext::getCurrent(); + Calculator *calcService = (Calculator*) myContext.locateService("CalculatorComponent/CalculatorService"); + if (calcService == 0) + { + cout << "calculator_client: Unable to find Calculator service" << endl; + } + else + { + try + { + float result = 0; + if (strcmp(operation, "add") == 0) + { + result = calcService->add(arg1, arg2); + cout << "calculator_client: add(" << arg1 << "," << arg2 << ") = " << result << endl; + } + else + if (strcmp(operation, "sub") == 0) + { + result = calcService->sub(arg1, arg2); + cout << "calculator_client: sub(" << arg1 << "," << arg2 << ") = " << result << endl; + } + else + if (strcmp(operation, "mul") == 0) + { + result = calcService->mul(arg1, arg2); + cout << "calculator_client: mul(" << arg1 << "," << arg2 << ") = " << result << endl; + } + else + if (strcmp(operation, "div") == 0) + { + result = calcService->div(arg1, arg2); + cout << "calculator_client: div(" << arg1 << "," << arg2 << ") = " << result << endl; + } + else + { + cout << "calculator_client: Unrecognized operation: " << operation << endl; + } + } + catch (char* x) + { + cout << "calculator_client: exception caught: " << x << endl; + } + } + + } + catch (ServiceRuntimeException& ex) + { + cout << ex << endl; + } + return 0; +} + +void usage() +{ + cout << "Usage: calculator_client add|sub|mul|div arg1 arg2" << endl; + exit(1); +} + +bool IsNumber (const char *p) +{ + int len = strlen(p); + int pointcount = 0; + + if (!isdigit (p[0]) && p[0] != '-' && p[0] != '+') + { + return false; + } + for (int i = 1; i < len; i++) + { + if (!isdigit (p[i])) + { + if (p[i] == '.') + { + if (pointcount > 0) return false; + pointcount++; + } + else + { + return false; + } + } + } + return true; +} diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/Makefile.am new file mode 100644 index 0000000000..433b249062 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/Makefile.am @@ -0,0 +1,38 @@ +deploydir=$(prefix)/samples/Calculator/deploy +clientdir=$(deploydir)/sample.calculator.client + +client_PROGRAMS = calculator_client +client_SCRIPTS = runclient.sh +EXTRA_DIST = runclient.sh + +AM_CPPFLAGS = $(CPPFLAGS) +calculator_client_SOURCES = \ +CalculatorClient.cpp + +calculator_client_LDADD = \ +-L${TUSCANY_SCACPP}/lib \ + -ltuscany_sca \ +-L${TUSCANY_SCACPP}/extensions/cpp/lib \ + -ltuscany_sca_cpp \ +-L${TUSCANY_SDOCPP}/lib \ + -ltuscany_sdo \ + -ltuscany_sdo_axiom \ +-L$(AXIS2C_HOME)/lib \ + -laxis2_util \ + -laxis2_axiom \ + -laxis2_wsdl \ + -laxis2_engine \ + -lwoden \ + -lwoden_wsdl \ + -laxis2_xml_schema \ + -laxis2_parser \ + -laxis2_minizip \ + -lpthread \ + -laxis2_http_sender \ + -laxis2_http_receiver + +INCLUDES = \ +-I$(TUSCANY_SCACPP)/extensions/cpp/include \ +-I${TUSCANY_SCACPP}/include \ +-I${TUSCANY_SDOCPP}/include \ +-I../sample.calculator diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/runclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/runclient.bat new file mode 100644 index 0000000000..f4308ff739 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/runclient.bat @@ -0,0 +1,48 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\cpp\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +.\calculator_client.exe div 5 2 + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/runclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/runclient.sh new file mode 100755 index 0000000000..ec4b3bb643 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.client/runclient.sh @@ -0,0 +1,47 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SCACPP/extensions/cpp/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +./calculator_client div 5 2 diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.solution.composite new file mode 100644 index 0000000000..0445d645e4 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.solution.composite @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator.solution"> + + <component name="sample.calculator.CalculatorComponent"> + <implementation.composite name="sample.calculator" /> + </component> + +</composite> + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/CalculatorWSClient.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/CalculatorWSClient.cpp new file mode 100644 index 0000000000..267baf1722 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/CalculatorWSClient.cpp @@ -0,0 +1,186 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "axis2_Calculator_stub.h" +#include <stdio.h> +#include <axiom.h> +#include <axis2_util.h> +#include <axiom_soap.h> +#include <axis2_client.h> + +axiom_node_t * +build_om_programatically(const axis2_env_t *env, + const axis2_char_t *operation, + const axis2_char_t *param1, + const axis2_char_t *param2); + +int main(int argc, char** argv) +{ + axis2_stub_t *stub = NULL; + axiom_node_t *node = NULL; + axis2_status_t status = AXIS2_FAILURE; + const axis2_env_t *env = NULL; + const axis2_char_t *address = NULL; + const axis2_char_t *client_home = NULL; + axiom_node_t *ret_node = NULL; + + const axis2_char_t *operation = "add"; + const axis2_char_t *param1 = "40"; + const axis2_char_t *param2 = "8"; + + env = axis2_env_create_all( "CalculatorService_blocking.log", AXIS2_LOG_LEVEL_TRACE); + + client_home = AXIS2_GETENV("AXIS2C_HOME"); + if (!client_home) + client_home = "../../deploy"; + + address = "http://localhost:9090/axis2/services/CalculatorService"; + if (argc > 1 ) + operation = argv[1]; + if (AXIS2_STRCMP(operation, "-h") == 0) + { + printf("Usage : %s [operation] [param1] [param2] [endpoint_url]\n", argv[0]); + printf("use -h for help\n"); + printf("default operation add\n"); + printf("default param1 %s\n", param1); + printf("default param2 %s\n", param2); + printf("default endpoint_url %s\n", address); + printf("NOTE: command line arguments must appear in given order, with trailing ones being optional\n"); + return 0; + } + if (argc > 2 ) + param1 = argv[2]; + if (argc > 3 ) + param2 = argv[3]; + if (argc > 4 ) + address = argv[4]; + + printf ("Using endpoint : %s\n", address); + printf ("\nInvoking operation %s with params %s and %s\n", operation, param1, param2); + + node = build_om_programatically(env, operation, param1, param2); + stub = + axis2_Calculator_stub_create_with_endpoint_uri_and_client_home(env, address, client_home); + /* create node and invoke Calculator */ + ret_node = axis2_Calculator_stub_add(stub, env, node); + if(ret_node) + { + axis2_char_t *om_str = NULL; + om_str = AXIOM_NODE_TO_STRING(ret_node, env); + if(om_str) + { + printf("\nOM returned = %s\n", om_str); + } + + if (AXIOM_NODE_GET_NODE_TYPE(ret_node, env) == AXIOM_ELEMENT) + { + axis2_char_t *result = NULL; + axiom_node_t *result_node = (axiom_node_t*)AXIOM_NODE_GET_FIRST_CHILD(ret_node, env); + axiom_element_t *data_ele = (axiom_element_t*)AXIOM_NODE_GET_DATA_ELEMENT(result_node, env); + + result = AXIOM_ELEMENT_GET_TEXT(data_ele, env, result_node); + printf( "\nResult = %s\n", result); + } + else + { + axiom_xml_writer_t *writer = NULL; + axiom_output_t *om_output = NULL; + axis2_char_t *buffer = NULL; + writer = axiom_xml_writer_create_for_memory(env, NULL, AXIS2_TRUE, 0, + AXIS2_XML_PARSER_TYPE_BUFFER); + om_output = axiom_output_create (env, writer); + + AXIOM_NODE_SERIALIZE (ret_node, env, om_output); + buffer = (axis2_char_t*)AXIOM_XML_WRITER_GET_XML(writer, env); + printf ("\nReceived invalid OM as result : %s\n", buffer); + if(NULL != buffer) + { + AXIS2_FREE(env->allocator, buffer); + buffer = NULL; + } + if(NULL != om_output) + { + AXIOM_OUTPUT_FREE(om_output, env); + om_output = NULL; + } + } + } + else + { + AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Stub invoke FAILED: Error code:" + " %d :: %s", env->error->error_number, + AXIS2_ERROR_GET_MESSAGE(env->error)); + printf("Calculator stub invoke FAILED!\n"); + } + if (stub) + { + AXIS2_STUB_FREE(stub, env); + } + return status; +} + +axiom_node_t * +build_om_programatically(const axis2_env_t *env, + const axis2_char_t *operation, + const axis2_char_t *param1, + const axis2_char_t *param2) +{ + axiom_node_t *Calculator_om_node = NULL; + axiom_element_t* Calculator_om_ele = NULL; + axiom_node_t* text_om_node = NULL; + axiom_element_t * text_om_ele = NULL; + axiom_namespace_t *ns1 = NULL; + + + axiom_xml_writer_t *xml_writer = NULL; + axiom_output_t *om_output = NULL; + axis2_char_t *buffer = NULL; + + ns1 = axiom_namespace_create (env, "http://sample/calculator", "ns1"); + + Calculator_om_ele = axiom_element_create(env, NULL, operation, ns1, &Calculator_om_node); + + text_om_ele = axiom_element_create(env, Calculator_om_node, "param1", NULL, &text_om_node); + AXIOM_ELEMENT_SET_TEXT(text_om_ele, env, param1, text_om_node); + + text_om_ele = axiom_element_create(env, Calculator_om_node, "param2", NULL, &text_om_node); + AXIOM_ELEMENT_SET_TEXT(text_om_ele, env, param2, text_om_node); + + xml_writer = axiom_xml_writer_create_for_memory(env, NULL, AXIS2_FALSE, AXIS2_FALSE, + AXIS2_XML_PARSER_TYPE_BUFFER); + om_output = axiom_output_create( env, xml_writer); + + AXIOM_NODE_SERIALIZE(Calculator_om_node, env, om_output); + buffer = (axis2_char_t*)AXIOM_XML_WRITER_GET_XML(xml_writer, env); + AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI, "\nSending OM node in XML : %s \n", buffer); + if(NULL != buffer) + { + AXIS2_FREE(env->allocator, buffer); + buffer = NULL; + } + if(NULL != om_output) + { + AXIOM_OUTPUT_FREE(om_output, env); + om_output = NULL; + } + + return Calculator_om_node; +} diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/Makefile.am new file mode 100644 index 0000000000..dca4c832bb --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/Makefile.am @@ -0,0 +1,31 @@ +deploydir=$(prefix)/samples/Calculator/deploy +wsclientdir=$(deploydir)/sample.calculator.wsclient + +wsclient_PROGRAMS = calculator_wsclient +wsclient_SCRIPTS = runwsclient.sh +EXTRA_DIST = runwsclient.sh + +AM_CPPFLAGS = $(CPPFLAGS) + +calculator_wsclient_SOURCES = \ +axis2_Calculator_stub.cpp \ +CalculatorWSClient.cpp + +noinst_HEADERS = *.h + +calculator_wsclient_LDADD = \ +-L$(AXIS2C_HOME)/lib \ + -laxis2_util \ + -laxis2_axiom \ + -laxis2_wsdl \ + -laxis2_engine \ + -lwoden \ + -lwoden_wsdl \ + -laxis2_xml_schema \ + -laxis2_parser \ + -laxis2_minizip \ + -lpthread \ + -laxis2_http_sender \ + -laxis2_http_receiver + +INCLUDES = -I${AXIS2C_HOME}/include diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/axis2_Calculator_stub.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/axis2_Calculator_stub.cpp new file mode 100644 index 0000000000..a24a3c9ed6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/axis2_Calculator_stub.cpp @@ -0,0 +1,178 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "axis2_Calculator_stub.h" + + +axis2_stub_t * +axis2_Calculator_stub_create_with_endpoint_ref_and_client_home(const axis2_env_t *env, + axis2_endpoint_ref_t *endpoint_ref, + axis2_char_t *client_home) +{ + axis2_stub_t *stub = NULL; + + AXIS2_ENV_CHECK(env, NULL); + + stub = (axis2_stub_t *) + axis2_stub_create_with_endpoint_ref_and_client_home(env, endpoint_ref, + client_home); + if(NULL == stub) + { + AXIS2_ERROR_SET(env->error, + AXIS2_ERROR_NO_MEMORY, (axis2_status_codes)AXIS2_FAILURE); + return NULL; + } + axis2_populate_axis_service( stub, env); + return stub; +} + +void axis2_populate_axis_service( axis2_stub_t* stub, const axis2_env_t *env) +{ + axis2_svc_client_t* svc_client = NULL; + axis2_qname_t *op_qname = NULL; + axis2_svc_t* svc = NULL; + axis2_op_t* op = NULL; + + /*Modifying the Service*/ + svc_client = AXIS2_STUB_GET_SVC_CLIENT (stub, env ); + svc = (axis2_svc_t*)AXIS2_SVC_CLIENT_GET_AXIS_SERVICE ( svc_client, env ); + + /*creating the operations*/ + + op_qname = axis2_qname_create(env,"add" , "", NULL); + op = axis2_op_create_with_qname(env, op_qname); + AXIS2_OP_SET_MSG_EXCHANGE_PATTERN(op, env, AXIS2_MEP_URI_OUT_IN); + AXIS2_SVC_ADD_OP(svc, env, op); + + op_qname = axis2_qname_create(env,"sub" , "", NULL); + op = axis2_op_create_with_qname(env, op_qname); + AXIS2_OP_SET_MSG_EXCHANGE_PATTERN(op, env, AXIS2_MEP_URI_OUT_IN); + AXIS2_SVC_ADD_OP(svc, env, op); + + op_qname = axis2_qname_create(env,"mul" , "", NULL); + op = axis2_op_create_with_qname(env, op_qname); + AXIS2_OP_SET_MSG_EXCHANGE_PATTERN(op, env, AXIS2_MEP_URI_OUT_IN); + AXIS2_SVC_ADD_OP(svc, env, op); + + op_qname = axis2_qname_create(env,"div" , "", NULL); + op = axis2_op_create_with_qname(env, op_qname); + AXIS2_OP_SET_MSG_EXCHANGE_PATTERN(op, env, AXIS2_MEP_URI_OUT_IN); + AXIS2_SVC_ADD_OP(svc, env, op); +} + +axis2_stub_t * +axis2_Calculator_stub_create_with_endpoint_uri_and_client_home(const axis2_env_t *env, + const axis2_char_t *endpoint_uri, + const axis2_char_t *client_home) +{ + axis2_stub_t *stub = NULL; + + AXIS2_ENV_CHECK(env, NULL); + + stub = (axis2_stub_t *) + axis2_stub_create_with_endpoint_uri_and_client_home(env, endpoint_uri, + client_home); + if(NULL == stub) + { + AXIS2_ERROR_SET(env->error, + AXIS2_ERROR_NO_MEMORY, (axis2_status_codes)AXIS2_FAILURE); + return NULL; + } + + axis2_populate_axis_service( stub, env); + + return stub; +} + +/***************************Function implementation****************************/ + +axiom_node_t * +axis2_Calculator_stub_add(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node) +{ + axis2_svc_client_t *svc_client = NULL; + axiom_node_t *ret_node = NULL; + axis2_qname_t *op_qname = NULL; + + AXIS2_ENV_CHECK(env, AXIS2_FAILURE); + + svc_client = AXIS2_STUB_GET_SVC_CLIENT(stub, env); + op_qname = axis2_qname_create(env, "add" , "", NULL); + ret_node = AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME( svc_client, env, op_qname, node); + + return ret_node; +} + +axiom_node_t * +axis2_Calculator_stub_sub(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node) +{ + axis2_svc_client_t *svc_client = NULL; + axiom_node_t *ret_node = NULL; + axis2_qname_t *op_qname = NULL; + + AXIS2_ENV_CHECK(env, AXIS2_FAILURE); + + svc_client = AXIS2_STUB_GET_SVC_CLIENT(stub, env); + op_qname = axis2_qname_create(env, "sub" , "", NULL); + ret_node = AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME( svc_client, env, op_qname, node); + + return ret_node; +} + +axiom_node_t * +axis2_Calculator_stub_mul(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node) +{ + axis2_svc_client_t *svc_client = NULL; + axiom_node_t *ret_node = NULL; + axis2_qname_t *op_qname = NULL; + + AXIS2_ENV_CHECK(env, AXIS2_FAILURE); + + svc_client = AXIS2_STUB_GET_SVC_CLIENT(stub, env); + op_qname = axis2_qname_create(env, "mul" , "", NULL); + ret_node = AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME( svc_client, env, op_qname, node); + + return ret_node; +} + +axiom_node_t * +axis2_Calculator_stub_div(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node) +{ + axis2_svc_client_t *svc_client = NULL; + axiom_node_t *ret_node = NULL; + axis2_qname_t *op_qname = NULL; + + AXIS2_ENV_CHECK(env, AXIS2_FAILURE); + + svc_client = AXIS2_STUB_GET_SVC_CLIENT(stub, env); + op_qname = axis2_qname_create(env, "div" , "", NULL); + ret_node = AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME( svc_client, env, op_qname, node); + + return ret_node; +} + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/axis2_Calculator_stub.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/axis2_Calculator_stub.h new file mode 100644 index 0000000000..833c6f85c6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/axis2_Calculator_stub.h @@ -0,0 +1,85 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef AXIS2_ECHO_STUB_H +#define AXIS2_ECHO_STUB_H + +/** + * @file axis2_Calculator_stub.h + * @brief axis2 Calculator stub interface + */ + +#include <axis2_stub.h> + +#ifdef __cplusplus +extern "C" +{ +#endif + +axiom_node_t * +axis2_Calculator_stub_add(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node); + +axiom_node_t * +axis2_Calculator_stub_sub(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node); + +axiom_node_t * +axis2_Calculator_stub_mul(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node); + +axiom_node_t * +axis2_Calculator_stub_div(axis2_stub_t *stub, + const axis2_env_t *env, + axiom_node_t *node); +/** + * populate services + */ +void axis2_populate_axis_service( axis2_stub_t* stub, const axis2_env_t *env); + +/** + * Creates axis2_stub struct + * @param endpoint reference + * @return pointer to newly created axis2_stub struct + */ +axis2_stub_t * +axis2_Calculator_stub_create_with_endpoint_ref_and_client_home(const axis2_env_t *env, + axis2_endpoint_ref_t *endpoint_ref, + axis2_char_t *client_home); + +/** + * Creates axis2_stub struct + * @param endpoint uri + * @return pointer to newly created axis2_stub struct + */ +axis2_stub_t * +axis2_Calculator_stub_create_with_endpoint_uri_and_client_home(const axis2_env_t *env, + const axis2_char_t *endpoint_uri, + const axis2_char_t *client_home); +/** @} */ + +#ifdef __cplusplus +} +#endif +#endif /* AXIS2_ECHO_STUB_H */ diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/runwsclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/runwsclient.bat new file mode 100644 index 0000000000..6d50f23370 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/runwsclient.bat @@ -0,0 +1,32 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo Using Axis2C installed at %AXIS2C_HOME%" + +rem Run the client +.\calculator_wsclient.exe div 5 2 + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/runwsclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/runwsclient.sh new file mode 100755 index 0000000000..51d8dbac22 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator.wsclient/runwsclient.sh @@ -0,0 +1,30 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +export LD_LIBRARY_PATH=$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +./calculator_wsclient div 5 2 diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Calculator.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Calculator.h new file mode 100644 index 0000000000..1a88c9cb67 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Calculator.h @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef sample_calculator_h +#define sample_calculator_h + +class Calculator +{ +public: + virtual float add(float arg1, float arg2) = 0; + virtual float sub(float arg1, float arg2) = 0; + virtual float mul(float arg1, float arg2) = 0; + virtual float div(float arg1, float arg2) = 0; +}; + +#endif // sample_calculator_h + + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Calculator.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Calculator.wsdl new file mode 100644 index 0000000000..37529c06c5 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Calculator.wsdl @@ -0,0 +1,161 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" + targetNamespace="http://sample/calculator"> + <types> + <xs:schema targetNamespace="http://sample/calculator" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" elementFormDefault="qualified"> + + <xs:element name="add"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="sub"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="mul"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="div"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="result"> + <xs:complexType> + <xs:sequence> + <xs:element name="data" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </types> + + <message name="addRequestMsg"> + <part name="body" element="tns:add" /> + </message> + <message name="subRequestMsg"> + <part name="body" element="tns:sub" /> + </message> + <message name="mulRequestMsg"> + <part name="body" element="tns:mul" /> + </message> + <message name="divRequestMsg"> + <part name="body" element="tns:div" /> + </message> + + <message name="calculatorResponseMsg"> + <part name="body" element="tns:result" /> + </message> + + <portType name="Calculator"> + <operation name="add"> + <input message="tns:addRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="sub"> + <input message="tns:subRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="mul"> + <input message="tns:mulRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="div"> + <input message="tns:divRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + </portType> + + <binding name="CalculatorBinding" + type="tns:Calculator"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" /> + <operation name="add"> + <soap:operation soapAction="CalculatorService#add" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + <operation name="sub"> + <soap:operation soapAction="CalculatorService#sub" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + <operation name="mul"> + <soap:operation soapAction="CalculatorService#mul" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + <operation name="div"> + <soap:operation soapAction="CalculatorService#div" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + </binding> + + <service name="CalculatorService"> + <port name="CalculatorPort" + binding="tns:CalculatorBinding"> + <soap:address location="http://localhost:9090/axis2/services/CalculatorService" /> + </port> + </service> +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.componentType new file mode 100644 index 0000000000..72fe9842e8 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.componentType @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"> + + <service name="CalculatorService"> + <interface.cpp header="Calculator.h"/> + </service> + + <reference name="divideService"> + <interface.cpp header="Divide.h"/> + </reference> + +</componentType>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.cpp new file mode 100644 index 0000000000..73abf2f1df --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.cpp @@ -0,0 +1,89 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "CalculatorImpl.h" +#include <stdio.h> + +#include "Divide.h" +#include "osoa/sca/ComponentContext.h" +#include "osoa/sca/ServiceRuntimeException.h" + +CalculatorImpl::CalculatorImpl() +{ +} + +CalculatorImpl::~CalculatorImpl() +{ +} + +// Calculator interface +float CalculatorImpl::add(float arg1, float arg2) +{ + float result = arg1 + arg2; + + printf("CalculatorImpl::add %f + %f = %f\n", arg1, arg2, result); + return result; +} + +float CalculatorImpl::sub(float arg1, float arg2) +{ + float result = arg1 - arg2; + printf("CalculatorImpl::sub %f - %f = %f\n", arg1, arg2, result); + return result; +} + +float CalculatorImpl::mul(float arg1, float arg2) +{ + float result = arg1 * arg2; + printf("CalculatorImpl::mul %f * %f = %f\n", arg1, arg2, result); + return result; +} + +float CalculatorImpl::div(float arg1, float arg2) +{ + float result = 0; + + // This method shows how to invoke a service on a different component from within a component + + // First, get the current ComponentContext + osoa::sca::ComponentContext myContext = osoa::sca::ComponentContext::getCurrent(); + + try + { + // Find the required service, as referenced in CalculatorImpl.componentType + Divide* divideService = (Divide*)myContext.getService("divideService"); + + // Finally, invoke the service + result = divideService->divide(arg1, arg2); + + printf("CalculatorImpl::div Divide returned result: %f\n", result); + + } + catch (osoa::sca::ServiceRuntimeException& e) + { + // Print out error message and carry on + printf("CalculatorImpl::div Error whilst invoking Divide: %s", e.getMessageText()); + } + + return result; +} + + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.h new file mode 100644 index 0000000000..af8a5eeab1 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/CalculatorImpl.h @@ -0,0 +1,41 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef sample_calculatorimpl_h +#define sample_calculatorimpl_h + +#include "Calculator.h" + +class CalculatorImpl : public Calculator +{ +public: + CalculatorImpl(); + virtual ~CalculatorImpl(); + + // Calculator interface + virtual float add(float arg1, float arg2); + virtual float sub(float arg1, float arg2); + virtual float mul(float arg1, float arg2); + virtual float div(float arg1, float arg2); +}; + +#endif // sample_calculatorimpl_h + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Divide.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Divide.h new file mode 100644 index 0000000000..6e171ed733 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Divide.h @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + + +#ifndef sample_divide_h +#define sample_divide_h + +class Divide +{ +public: + virtual float divide(float arg1, float arg2) = 0; +}; + +#endif // sample_divide_h + + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.componentType new file mode 100644 index 0000000000..d7369e3ff0 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.componentType @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"> + + <service name="DivideService"> + <interface.cpp header="Divide.h"/> + </service> + +</componentType> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.cpp new file mode 100644 index 0000000000..8b9db46ecb --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.cpp @@ -0,0 +1,47 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#include "DivideImpl.h" +#include <stdio.h> + +DivideImpl::DivideImpl() +{ +} + +DivideImpl::~DivideImpl() +{ +} + +// Divide interface +float DivideImpl::divide(float arg1, float arg2) +{ + if(arg2 == 0.0) + { + printf("DivideImpl::div %f / %f !! Cannot divide by zero, so returning 0\n", arg1, arg2); + return 0; + } + + float result = arg1 / arg2; + printf("DivideImpl::div %f / %f = %f\n", arg1, arg2, result); + return result; +} + + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.h new file mode 100644 index 0000000000..64045f1899 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/DivideImpl.h @@ -0,0 +1,39 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + + +#ifndef sample_divideimpl_h +#define sample_divideimpl_h + +#include "Divide.h" + +class DivideImpl : public Divide +{ +public: + DivideImpl(); + virtual ~DivideImpl(); + + // Divide interface + virtual float divide(float arg1, float arg2); +}; + +#endif // sample_divideimpl_h + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Makefile.am new file mode 100644 index 0000000000..bbd99286ac --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/Makefile.am @@ -0,0 +1,38 @@ +deploydir=$(prefix)/samples/Calculator/deploy +compositedir=$(deploydir)/sample.calculator + +BUILT_SOURCES = scagen + +noinst_HEADERS = *.h + +scagen: + java -jar $(TUSCANY_SCACPP)/bin/scagen.jar -dir . -output . + +composite_SCRIPTS = runwsserver.sh + +composite_LTLIBRARIES = libCalculator.la +composite_DATA = *.composite *.componentType *.wsdl +EXTRA_DIST = *.composite *.componentType *.wsdl runwsserver.sh + +dist_libCalculator_la_SOURCES = \ +CalculatorImpl.cpp \ +DivideImpl.cpp + +nodist_libCalculator_la_SOURCES = \ +CalculatorImpl_CalculatorService_Proxy.cpp \ +CalculatorImpl_CalculatorService_Wrapper.cpp \ +CalculatorImpl_divideService_Proxy.cpp \ +DivideImpl_DivideService_Proxy.cpp \ +DivideImpl_DivideService_Wrapper.cpp + +libCalculator_la_LIBADD = \ +-L${TUSCANY_SCACPP}/lib \ + -ltuscany_sca \ +-L${TUSCANY_SCACPP}/extensions/cpp/lib \ + -ltuscany_sca_cpp + +INCLUDES = \ +-I$(TUSCANY_SCACPP)/extensions/cpp/include \ +-I$(TUSCANY_SCACPP)/include \ +-I${TUSCANY_SDOCPP}/include + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/runwsserver.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/runwsserver.bat new file mode 100644 index 0000000000..160152e6a9 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/runwsserver.bat @@ -0,0 +1,49 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\cpp\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %AXIS2C_HOME%\bin +.\axis2_http_server.exe + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/runwsserver.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/runwsserver.sh new file mode 100755 index 0000000000..b94d841d66 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/runwsserver.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SCACPP/extensions/cpp/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +cd $AXIS2C_HOME/bin +./axis2_http_server diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/sample.calculator.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/sample.calculator.composite new file mode 100644 index 0000000000..ae4657b366 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Calculator/sample.calculator/sample.calculator.composite @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator"> + + <service name="CalculatorService"> + <interface.wsdl interface="http://sample/calculator#wsdl.interface(Calculator)"/> + <binding.ws/> + <reference>CalculatorComponent/CalculatorService</reference> + </service> + + <component name="CalculatorComponent"> + <implementation.cpp library="Calculator" header="CalculatorImpl.h"/> + <reference name="divideService">DivideComponent/DivideService</reference> + </component> + + <component name="DivideComponent"> + <implementation.cpp library="Calculator" header="DivideImpl.h"/> + </component> + +</composite>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ChangeLog b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ChangeLog new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ChangeLog diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/GettingStarted.html b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/GettingStarted.html new file mode 100644 index 0000000000..85cdc6b701 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/GettingStarted.html @@ -0,0 +1,114 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<HTML> +<HEAD> + <META CONTENT="text/html; charset=iso-8859-1" HTTP-EQUIV="Content-Type"> + <META CONTENT="text/css" HTTP-EQUIV="Content-Style-Type"> + <STYLE MEDIA="all" TYPE="text/css"> +@import url("../doc/css/maven-base.css"); +@import url("../doc/css/maven-theme.css"); + </STYLE> + + <LINK HREF="../doc/css/maven-theme.css" MEDIA="print" REL="stylesheet" + TYPE="text/css"> + <TITLE>Tuscany SCA C++ Samples - Getting Started</TITLE> +</HEAD> + +<BODY> +<DIV ID="bodyColumn"> + <DIV ID="contentBox"> + <DIV CLASS="section"> + <H2>Tuscany Samples - Getting Started - SCA C++ Milestone release 2</H2> + + <P>Tuscany SCA C++ includes a set of simple technology samples that demonstrates some of the functionality of + the Tuscany SCA C++ runtime. This page describes the samples and links to the documents that describe how to + build and run them + </P> + </DIV> + + <DIV CLASS="section"> + <A NAME="samples"><H2>Samples</H2></A> + <TABLE CLASS="bodyTable"> + <TBODY> + <TR CLASS="a"> + <TD STYLE="vertical-align: top; white-space: nowrap;"><A HREF="Calculator/README.html">Calculator</A> + </TD> + <TD>A very simple sample to show how an SCA composite can wire + together two C++ components to implement a Calculator service + and expose that service as a Web Service + </TD> + </TR> + <TR CLASS="a"> + <TD STYLE="vertical-align: top; white-space: nowrap;"><A HREF="PythonCalculator/README.html">PythonCalculator</A> + </TD> + <TD>A very simple sample to show how an SCA composite can wire + together two Python components to implement a Calculator service + and expose that service as a Web Service + </TD> + </TR> + <TR CLASS="a"> + <TD STYLE="vertical-align: top; white-space: nowrap;"><A HREF="RubyCalculator/README.html">RubyCalculator</A> + </TD> + <TD>A very simple sample to show how an SCA composite can wire + together two Ruby components to implement a Calculator service + and expose that service as a Web Service + </TD> + </TR> + <TR CLASS="a"> + <TD STYLE="vertical-align: top; white-space: nowrap;"><A HREF="BigBank/README.html">BigBank</A> + </TD> + <TD>A more complex sample that implements the "Simplified BigBank" scenario. A whitepaper describing + the scenario based on the SCA 0.9 Assembly specification can be found + <A HREF="http://www.osoa.org/display/Main/SCA+-+Previously+Published+Specifications">here</A>. + This sample uses multiple C++ components, calls out to an external Web Service via a reference, + exposes the service as a Web Service and also provides a PHP based client. + </TD> + </TR> + <TR CLASS="a"> + <TD STYLE="vertical-align: top; white-space: nowrap;"><A HREF="RubyBank/README.html">RubyBank</A> + </TD> + <TD>A more complex sample that implements the "Simplified BigBank" scenario. This sample uses multiple + Ruby components, calls out to an external Web Service via a reference and exposes the service as a + Web Service. + </TD> + </TR> + </TBODY> + </TABLE> + <BR> + </DIV> + <DIV CLASS="section"> + <A NAME="help"><H2>Getting Help</H2></A> + + <P>The first place to look is at the Tuscany FAQ at + <A HREF="http://incubator.apache.org/tuscany/faq.html" + TARGET="_blank">http://incubator.apache.org/tuscany/faq.html</A> </P> + + <P>Any problem with this release can be reported to the Tuscany + <A HREF="http://incubator.apache.org/tuscany/mail-lists.html" + TARGET="_blank">mailing lists</A> or create a JIRA issue at <A HREF="http://issues.apache.org/jira/browse/Tuscany" + TARGET="_blank">http://issues.apache.org/jira/browse/Tuscany</A>.</P> + + + <P> </P> + + <P> </P> + + <P> </P> + <TABLE CLASS="bodyTable"> + <TBODY> + <TR CLASS="a"> + <TD> + + <P>Thank you for your interest in Tuscany.</P> <STRONG><EM>-The + Tuscany Development Team</EM></STRONG> + </TD> + </TR> + </TBODY> + </TABLE> + </DIV> + + </DIV> + +</DIV> +</BODY> + +</HTML> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/INSTALL b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/INSTALL new file mode 100644 index 0000000000..2a6a072bf5 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/INSTALL @@ -0,0 +1,2 @@ +Please read the GettingStarted.html document for information on +building and installing the Tuscany SCA for C++ samples diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/LICENSE b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/LICENSE new file mode 100755 index 0000000000..f433b1a53f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/LICENSE @@ -0,0 +1,177 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Makefile.am new file mode 100644 index 0000000000..df96ecb8b4 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/Makefile.am @@ -0,0 +1,19 @@ +if WANT_ALL_SAMPLES + CPP_SAMPLES = Calculator BigBank + PYTHON_SAMPLES = PythonCalculator + RUBY_SAMPLES = RubyCalculator RubyBank +endif +if WANT_CPP_SAMPLES + CPP_SAMPLES = Calculator BigBank +endif +if WANT_PYTHON_SAMPLES + PYTHON_SAMPLES = PythonCalculator +endif +if WANT_RUBY_SAMPLES + RUBY_SAMPLES = RubyCalculator RubyBank +endif +if WANT_PHP_SAMPLES +endif +SUBDIRS = ${CPP_SAMPLES} ${PYTHON_SAMPLES} ${RUBY_SAMPLES} ${PHP_SAMPLES} + +EXTRA_DIST = GettingStarted.html diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Client/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Client/Makefile.am new file mode 100644 index 0000000000..b1586cc752 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Client/Makefile.am @@ -0,0 +1,11 @@ +prgbindir=$(prefix)/samples/bin +prgbin_PROGRAMS = MyValueClient + +MyValueClient_SOURCES = MyValueClient.cpp + +MyValueClient_LDADD = -L$(top_builddir)/runtime/core/src -ltuscany_sca \ + -L${TUSCANY_SDOCPP}/lib -ltuscany_sdo -lxml2 + +INCLUDES = -I.. \ + -I$(top_builddir)/runtime/core/src \ + -I${TUSCANY_SDOCPP}/include diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Client/MyValueClient.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Client/MyValueClient.cpp new file mode 100755 index 0000000000..0919c539da --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Client/MyValueClient.cpp @@ -0,0 +1,184 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#pragma warning(disable: 4786) + +#include "commonj/sdo/Logger.h" +#include "commonj/sdo/SDO.h" +#include "commonj/sdo/HelperProvider.h" +#include "osoa/sca/sca.h" +#include "tuscany/sca/util/Logger.h" +#include "tuscany/sca/util/Utils.h" +#include <iostream> + +using namespace std; +using namespace osoa::sca; +using namespace tuscany::sca; +using namespace commonj::sdo; +using namespace tuscany::sca::ws; + +void usage(); + +// +// MyValueClient is a sample application that invokes operations on the +// MyValueService Web Service. +// +int main(int argc, char* argv[]) +{ + + // + // Schema file for the types used by MyValueService + // + char *pszXSD; + + // + // The WebService endpoint uri. + // + char *pszEndpoint; + + // + // TargetNamespace + // + const char *pszTargetNamespace; + + // + // SOAPAction + // + // Axis 1.5: SoapAction must be <serviceName>#<operationName>. + const char *pcszSoapAction = "MyValueService#getMyValue"; + + // + // Operation Name + // + const char *pcszOperationName = "getMyValue"; + + // + // Operation Response Name + // + const char *pcszOperationResponseName = "getMyValueResponse"; + + + // Get the input parameters. + if (argc == 3) + { + // Schema file. + pszXSD = argv[1]; + // Web Service endpoint. + pszEndpoint = argv[2]; + } + else + { + usage(); + } + + // The current version of SDO does not support the embedded schema in the wsdl file, + // so we have to load an external schema. + XSDHelperPtr xsdHelper = HelperProvider::getXSDHelper(); + + try + { + cout << "define file: " << pszXSD <<endl; + pszTargetNamespace = xsdHelper->defineFile(pszXSD); + } + catch (SDORuntimeException ex) + { + cout << ex << endl; + exit(1); + } + cout << "define file done: " << pszTargetNamespace <<endl; + + + // Create an SDO for the request + DataFactoryPtr factory = xsdHelper->getDataFactory(); + DataObjectPtr requestDO = 0; + + try + { + // Create the root element for the operation and then add the parameters + // we need to invoke the operation. + requestDO = factory->create(pszTargetNamespace, pcszOperationName); + requestDO->setCString("customerID", "12345"); + } + catch (SDORuntimeException e) + { + cout << "SDORuntimeException: " << e << endl; + exit(1); + } + + // + // Create an SDOStub that will use the request SDO to invoke the operation. + // + SDOStub *stub = new SDOStub(); + stub->setEndpoint(pszEndpoint); + stub->setOperationName(pcszOperationName); + stub->setTargetNamespace(pszTargetNamespace); + stub->setOperationResponseName(pcszOperationResponseName); + stub->setSoapAction(pcszSoapAction); + // DEBUG - Don't let the soap transport timeout while debugging. + stub->setTransportTimeout(0); + // DEBUG + + try + { + // Invoke the operation. + DataObjectPtr responseDO = stub->invoke(requestDO, factory); + // Print the response. + if (responseDO != 0) + { + cout << "MyValueClient: response DataObject = " << endl; + Utils::printDO(responseDO); + cout << endl; + float fValue = responseDO->getFloat("myValue"); + cout << "MyValueClient: myValue = " << fValue; + } + else + { + cout << "MyValueClient: MyValueService did not return a result" << endl; + } + } + catch (SDORuntimeException& e) + { + cout << "SDORuntimeException: " << e << endl; + } + catch (ServiceRuntimeException& e) + { + cout << "ServiceRuntimeException: " << e << endl; + } + catch(exception& e) + { + cout << "Exception: " << e.what() << endl; + } + + + return 0; +} + +// +// Print usage message. +// +void usage() +{ + cout << "MyValueClient.exe: Invoke operations on MyValueService Web Service" << endl; + cout << "Usage: MyValueClient XSD endpoint" << endl; + cout << "where XSD = path and name of XSD file that defines the MyValue types" << endl; + cout << " endpoint = web service endpoint" << endl; + exit(1); +} diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Makefile.am new file mode 100644 index 0000000000..ede24623cf --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/Makefile.am @@ -0,0 +1,22 @@ +SUBDIRS = MyValueComposite Client + +deploy_dir = $(top_builddir)/samples/runtime +deploy_composite = $(deploy_dir)/packages/MyValueComposite + +install-exec-local: + cp MyValueSubsystem/sca.subsystem $(deploy_dir)/configuration/MyValueSubsystem + cp MyValueComposite/sca.composite $(deploy_composite) + cp MyValueComposite/CustomerInfo.fragment $(deploy_composite) + cp MyValueComposite/CustomerInfo/CustomerInfoImpl.componentType $(deploy_composite)/CustomerInfo + cp MyValueComposite/CustomerInfo/.libs/libCustomerInfo$libsuffix) $(deploy_composite)/CustomerInfo + cp MyValueComposite/CustomerInfo/CustomerInfo.h $(deploy_composite)/CustomerInfo + cp MyValueComposite/CustomerInfo/CustomerInfoImpl.h $(deploy_composite)/CustomerInfo + cp MyValueComposite/MyValue/MyValueImpl.componentType $(deploy_composite)/MyValue + cp MyValueComposite/MyValue/MyValue.h $(deploy_composite)/MyValue + cp MyValueComposite/MyValue/MyValueImpl.h $(deploy_composite)/MyValue + cp MyValueComposite/MyValue/MyValueService.wsdl $(deploy_composite)/MyValue + cp MyValueComposite/MyValue/.libs/libMyValue$libsuffix) $(deploy_composite)/MyValue + cp MyValueComposite/StockQuoteService/StockQuoteService.h $(deploy_composite)/StockQuoteService + cp MyValueComposite/StockQuoteService/StockQuoteService.wsdl $(deploy_composite)/StockQuoteService + + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo.fragment b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo.fragment new file mode 100755 index 0000000000..2227f730dd --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo.fragment @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+-->
+
+<compositeFragment xmlns="http://www.osoa.org/xmlns/sca/0.9"
+ xmlns:v="http://www.osoa.org/xmlns/sca/values/0.9"
+ xmlns:mvs="http://www.myvalue.org/MyValueService/"
+ name="CustomerInfoComponent">
+
+
+ <component name="CustomerInfoComponent">
+ <implementation.cpp dll="CustomerInfo/libCustomerInfo.so" header="CustomerInfo/CustomerInfoImpl.h"></implementation.cpp>
+ <properties>
+ <v:Fred>x</v:Fred>
+ <v:Joe>23</v:Joe>
+ <Joe>42</Joe>
+ </properties>
+ <references>
+ </references>
+ </component>
+
+</compositeFragment>
+
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfo.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfo.h new file mode 100755 index 0000000000..61d3e18133 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfo.h @@ -0,0 +1,32 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef CustomerInfo_h +#define CustomerInfo_h + +class CustomerInfo +{ +public: + virtual const char* getCustomerInformation(const char* customerID) = 0; + +}; + +#endif diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.componentType new file mode 100755 index 0000000000..caed4c5327 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.componentType @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/0.9" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="CustomerInfoService"> + <interface.cpp header="CustomerInfo/CustomerInfo.h"> + </interface.cpp> + </service> + + <property name="Fred" type="xs:string"/> + <property name="Joe" type="xs:integer" many="true"/> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.cpp new file mode 100755 index 0000000000..1a50dd4426 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.cpp @@ -0,0 +1,81 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#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-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.h new file mode 100755 index 0000000000..e2721ea03d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/CustomerInfoImpl.h @@ -0,0 +1,38 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#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-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/Makefile.am new file mode 100644 index 0000000000..78161c429c --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/CustomerInfo/Makefile.am @@ -0,0 +1,15 @@ +lib_LTLIBRARIES = libCustomerInfo.la + +libCustomerInfo_la_SOURCES = \ +CustomerInfoImpl.cpp \ +CustomerInfoImpl_CustomerInfoService_Proxy.cpp \ +CustomerInfoImpl_CustomerInfoService_Wrapper.cpp + +libCustomerInfo_la_LIBADD = -L$(top_builddir)/runtime/core/src -ltuscany_sca \ + -L${TUSCANY_SDOCPP}/lib -ltuscany_sdo + +INCLUDES = -I.. \ + -I$(top_builddir)/runtime/core/src \ + -I${TUSCANY_SDOCPP}/include + +install:
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/Makefile.am new file mode 100644 index 0000000000..1dc2c169b7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/Makefile.am @@ -0,0 +1,10 @@ +SUBDIRS = CustomerInfo MyValue + +BUILT_SOURCES = scagen + +scagen: + cd $(top_builddir)/bin && \ + ./scagen.sh -dir $(prefix)/samples/MyValue/MyValueComposite -output $(prefix)/samples/MyValue/MyValueComposite + mv CustomerInfoImpl_* CustomerInfo + mv MyValueImpl_* MyValue + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/Makefile.am new file mode 100644 index 0000000000..85e1077998 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/Makefile.am @@ -0,0 +1,17 @@ +lib_LTLIBRARIES = libMyValue.la + +libMyValue_la_SOURCES = \ +MyValueImpl.cpp \ +MyValueImpl_customerInfo_Proxy.cpp \ +MyValueImpl_MyValueService_Proxy.cpp \ +MyValueImpl_MyValueService_Wrapper.cpp \ +MyValueImpl_stockQuote_Proxy.cpp + +libMyValue_la_LIBADD = -L$(top_builddir)/runtime/core/src -ltuscany_sca \ + -L${TUSCANY_SDOCPP}/lib -ltuscany_sdo + +INCLUDES = -I.. \ + -I$(top_builddir)/runtime/core/src \ + -I${TUSCANY_SDOCPP}/include + +install:
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValue.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValue.h new file mode 100755 index 0000000000..615f62bde5 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValue.h @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef MyValue_h +#define MyValue_h + +#include "commonj/sdo/SDO.h" +using commonj::sdo::DataObjectPtr; + +class MyValue +{ +public: + virtual DataObjectPtr getMyValue(DataObjectPtr inDataObject) = 0; +}; + +#endif diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.componentType new file mode 100755 index 0000000000..b03760247b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.componentType @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/0.9"> + + <service name="MyValueService"> + <interface.cpp header="MyValue/MyValue.h"> + </interface.cpp> + </service> + + <reference name="customerInfo"> + <interface.cpp header="CustomerInfo/CustomerInfo.h"> + </interface.cpp> + </reference> + + <reference name="stockQuote"> + <interface.cpp header="StockQuoteService/StockQuoteService.h"> + </interface.cpp> + </reference> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.cpp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.cpp new file mode 100755 index 0000000000..5c0d5506d3 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.cpp @@ -0,0 +1,147 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +// +// MyValueImpl.cpp: implementation of the MyValueImpl class. +// + +#include "commonj/sdo/HelperProvider.h" +#include "commonj/sdo/SDO.h" +#include "osoa/sca/sca.h" +#include "MyValueImpl.h" +#include "CustomerInfo/CustomerInfo.h" +#include "StockQuoteService/StockQuoteService.h" +#include <iostream> + +using namespace std; +using namespace osoa::sca; +using namespace commonj::sdo; + +////////////////////////////////////////////////////////////////////// +// Construction/Destruction +////////////////////////////////////////////////////////////////////// + +MyValueImpl::MyValueImpl() +{ + cout << "Construct MyValueImpl" << endl; + +} + +MyValueImpl::~MyValueImpl() +{ + cout << "Destroy MyValueImpl" << endl; +} + +////////////////////////////////////////////////////////////////////// +// Other methods +////////////////////////////////////////////////////////////////////// +DataObjectPtr MyValueImpl::getMyValue(DataObjectPtr inDataObject) +{ + DataObjectPtr responseDO = 0; + + string customerID = inDataObject->getCString("customerID"); + cout << "In getMyValue with customerid: " << customerID << endl; + + // Get the CustomerInfo service. + ComponentContext myContext = ComponentContext::getCurrent(); + CustomerInfo* customerInfoService = (CustomerInfo*)myContext.getService("customerInfo"); + + if (customerInfoService == 0) + { + cout << "Unable to find customer info service" << endl; + + return responseDO; + } + + // Get the name of the stock for customer 'customerID' from the customerInfoService. + const char * stock; + try + { + stock = customerInfoService->getCustomerInformation(customerID.c_str()); + } + catch(const char* x) + { + cout << "Exception caught: " << x <<endl; + throw; + } + + + // Check that we get the same stock back when iterating over the customerInfo services. + ServiceList serviceList = myContext.getServices("customerInfo"); + for (int i=0; i<serviceList.size();i++) + { + CustomerInfo* service = (CustomerInfo*)(serviceList[i]); + stock = service->getCustomerInformation(customerID.c_str()); + cout << "Stock from getServices " << i << " : " << stock <<endl; + + } + + // Use a second SCA reference to get the stock price for the customer's stock. + StockQuoteService* stockQuoteService = (StockQuoteService*)myContext.getService("stockQuote"); + + if (stockQuoteService == 0) + { + cout << "Unable to find stock quote service" << endl; + + return responseDO; + } + + // Create a data object representing the requests (use dynamic API until static is available) + DataObjectPtr stockQuoteRequestDO; + DataFactoryPtr factory; + try + { + // Create the request DO for the StockQuoteService. + factory = myContext.getDataFactory(); + stockQuoteRequestDO = factory->create("http://swanandmokashi.com", "GetQuotes"); + stockQuoteRequestDO->setCString("QuoteTicker", stock); + + // Invoke the StockQuoteService + DataObjectPtr stockQuoteResponseDO = stockQuoteService->GetStockQuotes(stockQuoteRequestDO); + + // DEBUG (Print the response from the StockQuoteService) + XMLHelperPtr xmlHelper = HelperProvider::getXMLHelper(factory);; + XMLDocumentPtr responseDoc = + xmlHelper->createDocument(stockQuoteResponseDO, "http://swanandmokashi.com", "GetQuotesResponse"); + responseDoc->setXMLDeclaration(false); + char *responseXML = xmlHelper->save(responseDoc); + cout << "Response XML from StockQuoteService = " << endl; + cout << responseXML << endl; + cout << endl; + // DEBUG + + // Create the MyValueService response DataObject using the results of the StockQuoteService. + responseDO = factory->create("http://www.myvalue.org/MyValueService/", "getMyValueResponse"); + DataObjectPtr getQuotesResultDO = stockQuoteResponseDO->getDataObject("GetQuotesResult"); + DataObjectList& quoteList = getQuotesResultDO->getList("Quote"); + float fQuote = quoteList[0]->getFloat("StockQuote"); + + responseDO->setFloat("myValue", fQuote); + } + catch (SDORuntimeException sdoE) + { + cout << sdoE; + } + + return responseDO; + +} + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.h new file mode 100755 index 0000000000..6380dac5e0 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueImpl.h @@ -0,0 +1,37 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + + +#ifndef MyValueImpl_h +#define MyValueImpl_h + +#include "MyValue.h" + + +class MyValueImpl : public MyValue +{ +public: + MyValueImpl(); + virtual ~MyValueImpl(); + virtual DataObjectPtr getMyValue(DataObjectPtr inDataObject); +}; + +#endif diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueService.wsdl new file mode 100755 index 0000000000..6ea196e311 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueService.wsdl @@ -0,0 +1,84 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://www.myvalue.org/MyValueService/" + targetNamespace="http://www.myvalue.org/MyValueService/"> + <types> + <xs:schema targetNamespace="http://www.myvalue.org/MyValueService/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://www.myvalue.org/MyValueService/" + elementFormDefault="qualified"> + + <xs:element name="getMyValue"> + <xs:complexType> + <xs:sequence> + <xs:element name="customerID" type="xs:string" minOccurs="1"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="getMyValueResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="myValue" type="xs:float" minOccurs="1"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </types> + + <message name="getMyValueRequestMsg"> + <part name="body" element="tns:getMyValue"/> + </message> + + <message name="getMyValueResponseMsg"> + <part name="body" element="tns:getMyValueResponse"/> + </message> + + <portType name="MyValueServicePortType"> + <operation name="getMyValue"> + <input message="tns:getMyValueRequestMsg"/> + <output message="tns:getMyValueResponseMsg"/> + </operation> + </portType> + + <binding name="MyValueServiceBinding" type="tns:MyValueServicePortType"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <operation name="getMyValue"> + <soap:operation soapAction="MyValueService#getMyValue"/> + <input> + <soap:body use="literal"/> + </input> + <output> + <soap:body use="literal"/> + </output> + </operation> + </binding> + + <service name="MyValueService"> + <port name="MyValueServicePort" binding="tns:MyValueServiceBinding"> + <soap:address location="http://localhost/axis/MyValueService"/> + </port> + </service> +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueService.xsd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueService.xsd new file mode 100755 index 0000000000..ab2f25a826 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/MyValue/MyValueService.xsd @@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<xs:schema targetNamespace="http://www.myvalue.org/MyValueService/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://www.myvalue.org/MyValueService/" + elementFormDefault="qualified"> + + <xs:element name="getMyValue"> + <xs:complexType> + <xs:sequence> + <xs:element name="customerID" type="xs:string" minOccurs="1"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="getMyValueResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="myValue" type="xs:float" minOccurs="1"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/StockQuoteService/StockQuoteService.h b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/StockQuoteService/StockQuoteService.h new file mode 100755 index 0000000000..fda8a80e89 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/StockQuoteService/StockQuoteService.h @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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$ */ + +#ifndef StockQuoteService_h +#define StockQuoteService_h +#include <string> +#include "commonj/sdo/SDO.h" +using std::string; +class StockQuoteService +{ +public: + virtual commonj::sdo::DataObjectPtr GetStockQuotes(commonj::sdo::DataObjectPtr request) = 0; + +}; + +#endif // StockQuoteService_h diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/StockQuoteService/StockQuoteService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/StockQuoteService/StockQuoteService.wsdl new file mode 100755 index 0000000000..159d15c2d8 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/StockQuoteService/StockQuoteService.wsdl @@ -0,0 +1,157 @@ +<?xml version="1.0" encoding="utf-8" ?> +<definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:s0="http://swanandmokashi.com" + xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" + xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + targetNamespace="http://swanandmokashi.com" + xmlns="http://schemas.xmlsoap.org/wsdl/"> + <types> + <s:schema elementFormDefault="qualified" + targetNamespace="http://swanandmokashi.com" + xmlns:s="http://www.w3.org/2001/XMLSchema"> + <s:element name="GetQuotes"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="QuoteTicker" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="GetQuotesResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="GetQuotesResult" type="s0:ArrayOfQuote" /> + </s:sequence> + </s:complexType> + </s:element> + <s:complexType name="ArrayOfQuote"> + <s:sequence> + <s:element minOccurs="0" maxOccurs="unbounded" + name="Quote" type="s0:Quote" /> + </s:sequence> + </s:complexType> + <s:complexType name="Quote"> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="CompanyName" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="StockTicker" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="StockQuote" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="LastUpdated" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" name="Change" + type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="OpenPrice" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="DayHighPrice" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="DayLowPrice" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" name="Volume" + type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="MarketCap" type="s:string" /> + <s:element minOccurs="0" maxOccurs="1" + name="YearRange" type="s:string" /> + </s:sequence> + </s:complexType> + <s:element name="ArrayOfQuote" nillable="true" + type="s0:ArrayOfQuote" /> + </s:schema> + </types> + <message name="GetQuotesSoapIn"> + <part name="parameters" element="s0:GetQuotes" /> + </message> + <message name="GetQuotesSoapOut"> + <part name="parameters" element="s0:GetQuotesResponse" /> + </message> + <message name="GetQuotesHttpGetIn"> + <part name="QuoteTicker" type="s:string" /> + </message> + <message name="GetQuotesHttpGetOut"> + <part name="Body" element="s0:ArrayOfQuote" /> + </message> + <message name="GetQuotesHttpPostIn"> + <part name="QuoteTicker" type="s:string" /> + </message> + <message name="GetQuotesHttpPostOut"> + <part name="Body" element="s0:ArrayOfQuote" /> + </message> + <portType name="StockQuotesSoap"> + <operation name="GetStockQuotes"> + <input name="GetQuotes" message="s0:GetQuotesSoapIn" /> + <output name="GetQuotes" message="s0:GetQuotesSoapOut" /> + </operation> + </portType> + <portType name="StockQuotesHttpGet"> + <operation name="GetStockQuotes"> + <input name="GetQuotes" message="s0:GetQuotesHttpGetIn" /> + <output name="GetQuotes" message="s0:GetQuotesHttpGetOut" /> + </operation> + </portType> + <portType name="StockQuotesHttpPost"> + <operation name="GetStockQuotes"> + <input name="GetQuotes" message="s0:GetQuotesHttpPostIn" /> + <output name="GetQuotes" message="s0:GetQuotesHttpPostOut" /> + </operation> + </portType> + <binding name="StockQuotesSoap" type="s0:StockQuotesSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" + style="document" /> + <operation name="GetStockQuotes"> + <soap:operation + soapAction="http://swanandmokashi.com/GetQuotes" style="document" /> + <input name="GetQuotes"> + <soap:body use="literal" /> + </input> + <output name="GetQuotes"> + <soap:body use="literal" /> + </output> + </operation> + </binding> + <binding name="StockQuotesHttpGet" type="s0:StockQuotesHttpGet"> + <http:binding verb="GET" /> + <operation name="GetStockQuotes"> + <http:operation location="/GetQuotes" /> + <input name="GetQuotes"> + <http:urlEncoded /> + </input> + <output name="GetQuotes"> + <mime:mimeXml part="Body" /> + </output> + </operation> + </binding> + <binding name="StockQuotesHttpPost" type="s0:StockQuotesHttpPost"> + <http:binding verb="POST" /> + <operation name="GetStockQuotes"> + <http:operation location="/GetQuotes" /> + <input name="GetQuotes"> + <mime:content type="application/x-www-form-urlencoded" /> + </input> + <output name="GetQuotes"> + <mime:mimeXml part="Body" /> + </output> + </operation> + </binding> + <service name="StockQuotes"> + <port name="StockQuotesSoap" binding="s0:StockQuotesSoap"> + <soap:address + location="http://www.swanandmokashi.com/HomePage/WebServices/StockQuotes.asmx" /> + </port> + <port name="StockQuotesHttpGet" + binding="s0:StockQuotesHttpGet"> + <http:address + location="http://www.swanandmokashi.com/HomePage/WebServices/StockQuotes.asmx" /> + </port> + <port name="StockQuotesHttpPost" + binding="s0:StockQuotesHttpPost"> + <http:address + location="http://www.swanandmokashi.com/HomePage/WebServices/StockQuotes.asmx" /> + </port> + </service> +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/sca.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/sca.composite new file mode 100755 index 0000000000..52461c7650 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueComposite/sca.composite @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="ASCII"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<composite xmlns="http://www.osoa.org/xmlns/sca/0.9" + xmlns:v="http://www.osoa.org/xmlns/sca/values/0.9" + xmlns:mvs="http://www.myvalue.org/MyValueService/" + name="MyValueComposite"> + + <!-- Expose as a web service --> + <entryPoint name="MyValueService" multiplicity="1..1"> + <interface.wsdl interface="MyValue/MyValueService.wsdl" callbackInterface=""></interface.wsdl> + <binding.ws endpoint="mvs:MyValueServiceBinding"></binding.ws> + <reference>MyValueServiceComponent</reference> + </entryPoint> + + <component name="MyValueServiceComponent"> + <implementation.cpp dll="MyValue/libMyValue.so" header="MyValue/MyValueImpl.h"></implementation.cpp> + <properties> + </properties> + <references> + <customerInfo>CustomerInfoComponent</customerInfo> + <stockQuote>StockQuoteService</stockQuote> + </references> + </component> + + <externalService name="StockQuoteService"> + <interface.cpp header="StockQuoteService/StockQuoteService.h"/> + <binding.ws endpoint="http://swanandmokashi.com#wsdl.endpoint(StockQuotes/StockQuotesSoap)"/> + </externalService> + + <!--wire> + <source.uri>MyValueServiceComponent/customerInfo</source.uri> + <target.uri>CustomerInfoComponent</target.uri> + </wire--> + +</composite> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueSubsystem/sca.subsystem b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueSubsystem/sca.subsystem new file mode 100755 index 0000000000..7336b818b7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/MyValueSubsystem/sca.subsystem @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+-->
+
+<subsystem xmlns="http://www.osoa.org/xmlns/sca/0.9"
+
+ name="MyValueSubsystem">
+
+ <compositeComponent name="MyValue" composite="MyValueComposite">
+
+ </compositeComponent>
+
+</subsystem>
+
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/runMyValueClient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/runMyValueClient.sh new file mode 100755 index 0000000000..6a8a60c490 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/runMyValueClient.sh @@ -0,0 +1,53 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +export SCA4CPP_HOME="$APFULLDIR" +if [ x$SCA4CPP = x ]; then +export TUSCANY_SCACPP="$SCA4CPP_HOME" +fi +echo "Using SCA installed at $SCA4CPP_HOME" + +if [ x$AXISCPP_DEPLOY = x ]; then +echo "AXISCPP_DEPLOY not set" +exit; +fi +echo "Using Axis C++ installed at $AXISCPP_DEPLOY" + +if [ x$XERCES_DEPLOY = x ]; then +echo "XERCES_DEPLOY not set" +exit; +fi +echo "Using Xerces C++ installed at $XERCES_DEPLOY" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set"exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +TEST_ROOT=$SCA4CPP_HOME/runtime/core/test + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$LD_LIBRARY_PATH:$AXISCPP_DEPLOY/lib:$XERCES_DEPLOY/lib + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_ROOT/testSCASystem +export TUSCANY_SCACPP_DEFAULT_COMPOSITE=SubSystem1 + +cd $TUSCANY_SCACPP/bin/test +./tuscany_sca_test diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/server.wsdd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/server.wsdd new file mode 100755 index 0000000000..1a82ab85a7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/MyValue/server.wsdd @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+-->
+
+<!-- The Entity, wspath in the following internal subset allows setting a path for the webservices location -->
+<!--<!DOCTYPE vars [ <!ENTITY wspath "/Apache2.0.54/Apache2/Axis/webservices/"> ]>-->
+
+<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:C="http://xml.apache.org/axis/wsdd/providers/C" xmlns:CPP="http://xml.apache.org/axis/wsdd/providers/CPP">
+ <globalConfiguration>
+ </globalConfiguration>
+
+ <service name="MyValueService" provider="CPP:DOCUMENT" description="MyValueService">
+ <requestFlow>
+ <handler name="SCAWSHandler" type="C:\Apache2.0.54\Apache2\Axis\handlers\tuscany_sca_axis_handler.dll">
+ <parameter name="targetNamespace" value="http://www.myvalue.org/MyValueService/"/>
+ <parameter name="scaEntryPoint" value="MyValueSubsystem/MyValue/MyValueService"/>
+ </handler>
+ </requestFlow>
+
+ <parameter name="className" value="C:\Apache2.0.54\Apache2\Axis\webservices\tuscany_sca_axis_wrapper.dll"/>
+ <parameter name="allowedMethods" value="getMyValue "/>
+ </service>
+
+</deployment>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/NEWS b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/NEWS new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/NEWS diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/NOTICE b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/NOTICE new file mode 100644 index 0000000000..bfb81409ad --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/NOTICE @@ -0,0 +1,2 @@ +This product includes software developed by +The Apache Software Foundation (http://www.apache.org/)
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/Makefile.am new file mode 100644 index 0000000000..49dea6f6eb --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/Makefile.am @@ -0,0 +1,4 @@ +deploydir=$(prefix)/samples/PythonCalculator/deploy +SUBDIRS = sample.calculator sample.calculator.client sample.calculator.wsclient +EXTRA_DIST = *.composite README.html +deploy_DATA = *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/README new file mode 100644 index 0000000000..b9e787c768 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/README @@ -0,0 +1,24 @@ +Tuscany SCA for C++ Samples - Calculator Sample +=============================================== + +This is a very simple sample to show how an SCA composite can wire together +two components to implement a Calculator service and expose that service as +a Web Service. + +There are three sub projects in this workspace: + - sample.calculator + This contains the source code and SCDL artifacts for the SCA Calculator. + composite implementing the sample Calculator. + + - sample.calculator.client + A sample client which does a local call to the Calculator service. + + - sample.calculator.wsclient + A sample Axis2 Web Service client which calls the Calculator Web service. + + +Additionally, there is the sample.calculator.solution.composite file. This +describes the configuration of the SCA Calculator composite deployed to the +SCA runtime. + +See the README.html file for instructions to build and run this sample diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/README.html b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/README.html new file mode 100644 index 0000000000..72b79dac56 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/README.html @@ -0,0 +1,252 @@ + +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<!-- + Copyright 2006 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. + --> +<HTML> +<HEAD> + <META CONTENT="text/html; charset=iso-8859-1" HTTP-EQUIV="Content-Type"> + <META CONTENT="text/css" HTTP-EQUIV="Content-Style-Type"> + <STYLE MEDIA="all" TYPE="text/css"> +@import url("../../doc/css/maven-base.css"); +@import url("../../doc/css/maven-theme.css"); + </STYLE> + + <LINK HREF="../doc/css/maven-theme.css" MEDIA="print" REL="stylesheet" + TYPE="text/css"> + <TITLE>Tuscany SCA for C++ Samples - PythonCalculator Sample</TITLE> +</HEAD> + +<BODY> +<DIV ID="bodyColumn"> + <DIV ID="contentBox"> + <DIV CLASS="section"> + <H2>Tuscany SCA for C++ Samples - PythonCalculator Sample</H2> + + <P>This is a very simple sample to show how an SCA composite can wire + together two Python components to implement a Calculator service and expose + that service as a Web Service. + </P> + <P>See the <A HREF="../../doc/PythonExtension.html">Python extension</A> + documentation for information about building the Tuscany Python extension + and using Python in SCA composites. + </P> + <P>There are three sub projects in this workspace:</P> + <UL> + <LI>sample.calculator<BR/> + This contains the Python scripts and SCDL artifacts for the SCA Calculator + composite implementing the sample Calculator. + </LI> + <LI>sample.calculator.client<BR/> + A sample client which does a local call to the Calculator service. + </LI> + <LI>sample.calculator.wsclient<BR/> + A sample client which does a local call to a composite that contains a Web Service reference + that calls the Calculator Web Service. + </LI> + </UL> + <P>Additionally, there is the sample.calculator.solution.composite file. This + describes the configuration of the SCA Calculator composite deployed to the SCA + runtime. + </P> + + </DIV> + + <DIV CLASS="section"> + <H2>Contents</H2> + <OL> + <LI><A HREF="#linuxbld">Building the Python samples on Linux</A></LI> + <LI><A HREF="#linuxrun">Running the PythonCalculator sample on Linux:</A></LI> + <UL> + <LI><A HREF="#linuxbasic">Running the basic client</A></LI> + <LI><A HREF="#linuxws">Running the Web Service client</A></LI> + </UL> + <LI><A HREF="#winbld">Building the PythonCalculator sample on Windows</A></LI> + <LI><A HREF="#winrun">Running the PythonCalculator sample on Windows:</A></LI> + <UL> + <LI><A HREF="#winbasic">Running the basic client</A></LI> + <LI><A HREF="#winws">Running the Web Service client</A></LI> + </UL> + <LI><A HREF="#help">Getting help</A></LI> + </OL> + </DIV> + + + <DIV CLASS="section"> + <A NAME="linuxbld"><H2>Building the Python samples on Linux</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#linuxrun">Running the samples on Linux</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>As the PythonCalculator sample is based on Python scripts, a specific compilation step is not necessary - + only deployment is required. Deploy the Python samples only with the following command sequence: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples</LI> + <LI>./configure --enable-python --enable-cpp=no --prefix=$TUSCANY_SCACPP</LI> + <LI>make install</LI> + </UL> + NOTE: If you don't provide the --prefix configure option, it will by default install into + /usr/local/tuscany/sca/samples/PythonCalculator</LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="linuxrun"><H2>Running the PythonCalculator sample on Linux</H2></A> + <A NAME="linuxbasic"><H3>PythonCalculator with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator/deploy/sample.calculator.client</LI> + <LI>./runclient.sh</LI> + </UL> + </LI> + </OL> + <A NAME="linuxws"><H3>PythonCalculator with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator/deploy/sample.calculator</LI> + <LI>./runwsserver.sh</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variable is required: + <UL> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator/deploy/sample.calculator.wsclient</LI> + <LI>./runwsclient.sh</LI> + </OL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winbld"><H2>Building the PythonCalculator sample on Windows</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#winrun">Running the samples on Windows</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>As this sample is based on Python scripts, a specific compilation step is not necessary - + only deployment is required. Deploy the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator</LI> + <LI>./deploy.cmd</LI> + </UL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winrun"><H2>Running the PythonCalculator sample on Windows</H2></A> + <A NAME="winbasic"><H3>PythonCalculator with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator/deploy/sample.calculator.client</LI> + <LI>./runclient.bat</LI> + </UL> + </LI> + </OL> + <A NAME="winws"><H3>PythonCalculator with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator/deploy/sample.calculator</LI> + <LI>./runwsserver.bat</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/PythonCalculator/deploy/sample.calculator.wsclient</LI> + <LI>./runwsclient.bat</LI> + </OL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="help"><H2>Getting Help</H2></A> + + <P>First place to look is at the Tuscany FAQ at + <A HREF="http://incubator.apache.org/tuscany/faq.html" + TARGET="_blank">http://incubator.apache.org/tuscany/faq.html</A> </P> + + <P>Any problem with this release can be reported to the Tuscany + <A HREF="http://incubator.apache.org/tuscany/mail-lists.html" + TARGET="_blank">mailing lists</A> or create a JIRA issue at <A HREF="http://issues.apache.org/jira/browse/Tuscany" + TARGET="_blank">http://issues.apache.org/jira/browse/Tuscany</A>.</P> + </DIV> + </DIV> +</DIV> +</BODY> + +</HTML> + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/deploy.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/deploy.cmd new file mode 100644 index 0000000000..7db890865a --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/deploy.cmd @@ -0,0 +1,57 @@ +@echo off
+@REM Licensed to the Apache Software Foundation (ASF) under one
+@REM or more contributor license agreements. See the NOTICE file
+@REM distributed with this work for additional information
+@REM regarding copyright ownership. The ASF licenses this file
+@REM to you under the Apache License, Version 2.0 (the
+@REM "License"); you may not use this file except in compliance
+@REM with the License. You may obtain a copy of the License at
+@REM
+@REM http://www.apache.org/licenses/LICENSE-2.0
+@REM
+@REM Unless required by applicable law or agreed to in writing,
+@REM software distributed under the License is distributed on an
+@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+@REM KIND, either express or implied. See the License for the
+@REM specific language governing permissions and limitations
+@REM under the License.
+
+rem Will copy the correct files from the source tree for packaging and deployment of the
+rem SCA sample.
+setlocal
+set currentPath=%~d0%~p0
+set sourcePath=%currentPath%
+
+set deploydir=%TUSCANY_SCACPP%
+set samplesdir=%deploydir%\samples
+set calcdir=%samplesdir%\PythonCalculator
+
+if . == %1. (
+set destinationPath=%calcdir%\deploy
+) ELSE (
+set destinationPath=%1
+)
+
+if not exist %samplesdir% mkdir %samplesdir%
+if not exist %calcdir% mkdir %calcdir%
+if not exist %destinationPath% mkdir %destinationPath%
+if not exist %destinationPath%\sample.calculator mkdir %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\*.componentType %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\*.composite %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\*.py %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\Calculator.wsdl %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\runwsserver.bat %destinationPath%\sample.calculator
+
+if not exist %destinationPath%\sample.calculator.client mkdir %destinationPath%\sample.calculator.client
+copy %sourcePath%\sample.calculator.client\calculator_client.py %destinationPath%\sample.calculator.client
+copy %sourcePath%\sample.calculator.client\runclient.bat %destinationPath%\sample.calculator.client
+
+if not exist %destinationPath%\sample.calculator.wsclient mkdir %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\calculator_wsclient.py %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\sample.calculator.wsclient.composite %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\Calculator.wsdl %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\runwsclient.bat %destinationPath%\sample.calculator.wsclient
+
+copy %sourcePath%\*.composite %destinationPath%
+
+endlocal
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/Makefile.am new file mode 100644 index 0000000000..e3789b1cfe --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/Makefile.am @@ -0,0 +1,6 @@ +deploydir=$(prefix)/samples/PythonCalculator/deploy +clientdir=$(deploydir)/sample.calculator.client + +client_DATA = *.py +client_SCRIPTS = runclient.sh +EXTRA_DIST = runclient.sh *.py diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/calculator_client.py b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/calculator_client.py new file mode 100644 index 0000000000..58d6f45606 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/calculator_client.py @@ -0,0 +1,50 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# +# +# +# This Python code is a simple sample that provides a Python +# client for the Calculator sample + + +import sys +import sca + +op = sys.argv[1] +val1 = sys.argv[2] +val2 = sys.argv[3] + +# Locate the calculator service +calc = sca.locateservice("CalculatorComponent") + +# Invoke the calculator operations +if op == 'add': + result = calc.add(val1, val2) + +elif op == 'sub': + result = calc.sub(val1, val2) + +elif op == 'mul': + result = calc.mul(val1, val2) + +elif op == 'div': + result = calc.div(val1, val2) + + +print "calculator_client: ",op,"(",val1,",",val2,") = ",result + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/runclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/runclient.bat new file mode 100644 index 0000000000..d02d5fced8 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/runclient.bat @@ -0,0 +1,50 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\python\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% +set PYTHONPATH=%TUSCANY_SCACPP%\extensions\python\bin + +cd %TUSCANY_SCACPP_SYSTEM_ROOT%\sample.calculator.client +python calculator_client.py div 5 2 + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/runclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/runclient.sh new file mode 100755 index 0000000000..ced35b5f6b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.client/runclient.sh @@ -0,0 +1,49 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SCACPP/extensions/python/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH +export PYTHONPATH=$TUSCANY_SCACPP/extensions/python/lib:$PYTHONPATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +cd $TUSCANY_SCACPP_SYSTEM_ROOT/sample.calculator.client +python calculator_client.py div 5 2 diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.solution.composite new file mode 100644 index 0000000000..0a8ae343db --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.solution.composite @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator.solution"> + + <component name="sample.calculator.CalculatorComponent"> + <implementation.composite name="sample.calculator" /> + </component> + + <component name="sample.calculator.CalculatorWSClientComponent"> + <implementation.composite name="sample.calculator.wsclient" /> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/Calculator.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/Calculator.wsdl new file mode 100644 index 0000000000..f74c3d5c33 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/Calculator.wsdl @@ -0,0 +1,114 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" + targetNamespace="http://sample/calculator"> + <types> + <xs:schema targetNamespace="http://sample/calculator" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" elementFormDefault="qualified"> + + <xs:element name="add"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="sub"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="mul"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="div"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="result"> + <xs:complexType> + <xs:sequence> + <xs:element name="data" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </types> + + <message name="addRequestMsg"> + <part name="body" element="tns:add" /> + </message> + <message name="subRequestMsg"> + <part name="body" element="tns:sub" /> + </message> + <message name="mulRequestMsg"> + <part name="body" element="tns:mul" /> + </message> + <message name="divRequestMsg"> + <part name="body" element="tns:div" /> + </message> + + <message name="calculatorResponseMsg"> + <part name="body" element="tns:result" /> + </message> + + <portType name="Calculator"> + <operation name="add"> + <input message="tns:addRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="sub"> + <input message="tns:subRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="mul"> + <input message="tns:mulRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="div"> + <input message="tns:divRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + </portType> + +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/Makefile.am new file mode 100644 index 0000000000..b2c7c4d718 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/Makefile.am @@ -0,0 +1,6 @@ +deploydir=$(prefix)/samples/PythonCalculator/deploy +wsclientdir=$(deploydir)/sample.calculator.wsclient + +wsclient_DATA = *.py *.wsdl *.composite +wsclient_SCRIPTS = runwsclient.sh +EXTRA_DIST = runwsclient.sh *.py *.wsdl *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/calculator_wsclient.py b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/calculator_wsclient.py new file mode 100644 index 0000000000..1ec1f66d83 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/calculator_wsclient.py @@ -0,0 +1,50 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# +# +# +# This Python code is a simple sample that provides a Python +# client for the Calculator sample + + +import sys +import sca + +op = sys.argv[1] +val1 = sys.argv[2] +val2 = sys.argv[3] + +# Locate the calculator service +calc = sca.locateservice("CalculatorService") + +# Invoke the calculator operations +if op == 'add': + result = calc.add(val1, val2) + +elif op == 'sub': + result = calc.sub(val1, val2) + +elif op == 'mul': + result = calc.mul(val1, val2) + +elif op == 'div': + result = calc.div(val1, val2) + + +print "calculator_wsclient: ",op,"(",val1,",",val2,") = ",result + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/runwsclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/runwsclient.bat new file mode 100644 index 0000000000..dbcdf06313 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/runwsclient.bat @@ -0,0 +1,50 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorWSClientComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\python\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% +set PYTHONPATH=%TUSCANY_SCACPP%\extensions\python\bin + +cd %TUSCANY_SCACPP_SYSTEM_ROOT%\sample.calculator.wsclient +python calculator_wsclient.py div 5 2 + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/runwsclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/runwsclient.sh new file mode 100755 index 0000000000..a02f607d08 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/runwsclient.sh @@ -0,0 +1,49 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SCACPP/extensions/python/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH +export PYTHONPATH=$TUSCANY_SCACPP/extensions/python/lib:$PYTHONPATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorWSClientComponent + +cd $TUSCANY_SCACPP_SYSTEM_ROOT/sample.calculator.wsclient +python calculator_wsclient.py div 5 2 diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/sample.calculator.wsclient.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/sample.calculator.wsclient.composite new file mode 100644 index 0000000000..6ee1169645 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator.wsclient/sample.calculator.wsclient.composite @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator.wsclient"> + + <reference name="CalculatorService"> + <interface.wsdl interface="http://sample/calculator#wsdl.interface(Calculator)"/> + <binding.ws uri="http://localhost:9090/axis2/services/CalculatorService"/> + </reference> + +</composite>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/Calculator.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/Calculator.wsdl new file mode 100644 index 0000000000..37529c06c5 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/Calculator.wsdl @@ -0,0 +1,161 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" + targetNamespace="http://sample/calculator"> + <types> + <xs:schema targetNamespace="http://sample/calculator" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" elementFormDefault="qualified"> + + <xs:element name="add"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="sub"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="mul"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="div"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="result"> + <xs:complexType> + <xs:sequence> + <xs:element name="data" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </types> + + <message name="addRequestMsg"> + <part name="body" element="tns:add" /> + </message> + <message name="subRequestMsg"> + <part name="body" element="tns:sub" /> + </message> + <message name="mulRequestMsg"> + <part name="body" element="tns:mul" /> + </message> + <message name="divRequestMsg"> + <part name="body" element="tns:div" /> + </message> + + <message name="calculatorResponseMsg"> + <part name="body" element="tns:result" /> + </message> + + <portType name="Calculator"> + <operation name="add"> + <input message="tns:addRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="sub"> + <input message="tns:subRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="mul"> + <input message="tns:mulRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="div"> + <input message="tns:divRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + </portType> + + <binding name="CalculatorBinding" + type="tns:Calculator"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" /> + <operation name="add"> + <soap:operation soapAction="CalculatorService#add" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + <operation name="sub"> + <soap:operation soapAction="CalculatorService#sub" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + <operation name="mul"> + <soap:operation soapAction="CalculatorService#mul" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + <operation name="div"> + <soap:operation soapAction="CalculatorService#div" /> + <input> + <soap:body use="literal" /> + </input> + <output> + <soap:body use="literal" /> + </output> + </operation> + </binding> + + <service name="CalculatorService"> + <port name="CalculatorPort" + binding="tns:CalculatorBinding"> + <soap:address location="http://localhost:9090/axis2/services/CalculatorService" /> + </port> + </service> +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/CalculatorImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/CalculatorImpl.componentType new file mode 100644 index 0000000000..b54b4e22b1 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/CalculatorImpl.componentType @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"> + + <service name="CalculatorService"> + <interface.python/> + </service> + + <reference name="divideService"> + <interface.python/> + </reference> + +</componentType>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/CalculatorImpl.py b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/CalculatorImpl.py new file mode 100644 index 0000000000..86dbef9e4d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/CalculatorImpl.py @@ -0,0 +1,56 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# +# +# +# This Python code is a simple sample that provides a Python implementation of +# the Calculator sample +# + + +# The module-level add function +def add(val1, val2): + result = float(val1) + float(val2) + print "Python - CalculatorImpl.add " + str(val1) + " + " + str(val2) + " = " + str(result) + return result + +# The module-level sub function +def sub(val1, val2): + result = float(val1) - float(val2) + print "Python - CalculatorImpl.sub " + str(val1) + " - " + str(val2) + " = " + str(result) + return result + +# The module-level mul function +def mul(val1, val2): + result = float(val1) * float(val2) + print "Python - CalculatorImpl.mul " + str(val1) + " * " + str(val2) + " = " + str(result) + return result + +# The module-level div function +def div(val1, val2): + + + print "Python - CalculatorImpl.div calling divideService to determine " + str(val1) + " / " + str(val2) + + # Use the divideService reference + result = divideService.divide(val1, val2) + + print "Python - CalculatorImpl.div divideService returned " + str(result) + + return result + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/DivideImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/DivideImpl.componentType new file mode 100644 index 0000000000..fa2938279a --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/DivideImpl.componentType @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <service name="DivideService"> + <interface.python/> + </service> + + <property name="doRounding" type="xsd:boolean"/> + +</componentType> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/DivideImpl.py b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/DivideImpl.py new file mode 100644 index 0000000000..3921731de6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/DivideImpl.py @@ -0,0 +1,65 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# +# +# +# This Python code is a simple sample that provides a Python implementation of +# the Divide Service used in the Calculator sample +# +# Either use the divide function in the DivideClass class (using classes allows +# composite scoping to be used) +# e.g. in CalculatorComposite.composite use the line: +# <implementation.python module="DivideImpl" class="DivideClass"/> +# +# Or just use the module-level divide function +# e.g. in CalculatorComposite.composite use the line: +# <implementation.python module="DivideImpl" /> +# + + +class DivideClass: + "A class to handle dividing" + + def __init__(self): + print "Python - DivideImpl.DivideClass constructor" + + # The class-level divide function + def divide(self, val1, val2): + result = float(val1) / float(val2) + + print "Python - DivideImpl.DivideClass.divide " + str( val1 ) + " / " + str(val2) + " = " + str(result) + + # Use the doRounding property + if doRounding: + result = round(result) + print "Python - DivideImpl.DivideClass.divide is rounding the result to " + str(result) + + return result + +# The module-level divide function +def divide(val1, val2): + result = float(val1) / float(val2) + print "Python - DivideImpl.divide " + str(val1) + " / " + str(val2) + " = " + str(result) + + # Use the doRounding property + if doRounding: + result = round(result) + print "Python - DivideImpl.divide is rounding the result to " + str(result) + + return result + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/Makefile.am new file mode 100644 index 0000000000..f8aaaac0c9 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/Makefile.am @@ -0,0 +1,7 @@ +deploydir=$(prefix)/samples/PythonCalculator/deploy +compositedir=$(deploydir)/sample.calculator + +composite_DATA = *.composite *.componentType *.wsdl *.py +composite_SCRIPTS = runwsserver.sh +EXTRA_DIST = *.composite *.componentType *.wsdl *.py runwsserver.sh + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/runwsserver.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/runwsserver.bat new file mode 100644 index 0000000000..2e5df325b2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/runwsserver.bat @@ -0,0 +1,50 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\python\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% +set PYTHONPATH=%TUSCANY_SCACPP%\extensions\python\bin + +cd %AXIS2C_HOME%\bin +.\axis2_http_server.exe + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/runwsserver.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/runwsserver.sh new file mode 100755 index 0000000000..570a439b4f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/runwsserver.sh @@ -0,0 +1,49 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SCACPP/extensions/python/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH +export PYTHONPATH=$TUSCANY_SCACPP/extensions/python/lib:$PYTHONPATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +cd $AXIS2C_HOME/bin +./axis2_http_server diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/sample.calculator.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/sample.calculator.composite new file mode 100644 index 0000000000..caac112edf --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/PythonCalculator/sample.calculator/sample.calculator.composite @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator"> + + <service name="CalculatorService"> + <interface.wsdl interface="http://sample/calculator#wsdl.interface(Calculator)"/> + <binding.ws/> + <reference>CalculatorComponent</reference> + </service> + + <component name="CalculatorComponent"> + <implementation.python module="CalculatorImpl" scope="composite"/> + <reference name="divideService">DivideComponent</reference> + </component> + + <component name="DivideComponent"> + <implementation.python module="DivideImpl" scope="composite"/> + <property name="doRounding">true</property> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/README new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/README diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/Makefile.am new file mode 100644 index 0000000000..6a5f96c750 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/Makefile.am @@ -0,0 +1,4 @@ +deploydir=$(prefix)/samples/RubyBank/deploy +SUBDIRS = bigbank.account bigbank.client +EXTRA_DIST = *.composite README.html +deploy_DATA = *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/README new file mode 100644 index 0000000000..266b66cc9a --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/README @@ -0,0 +1,22 @@ +Tuscany SCA for C++ Samples - RubyBank Sample +=============================================== + +This sample implements the "Simplified BigBank" scenario. A whitepaper +describing the scenario based on the SCA 0.9 Assembly specification can be +found here. This sample uses multiple Ruby components, calls out to an +external Web Service via a reference, exposes the service as a Web Service +and also provides a PHP based client. + +There are two sub projects in this workspace: + - bigbank.account + This contains the source code and SCDL artifacts for the SCA BigBank + composite implementing the account services. + + - bigbank.client + A sample client which does a local call to the BigBank service. + +Additionally, there is the bigbank.accountmanagement.composite file. This +describes the configuration of the SCA Calculator composite deployed to the +SCA runtime. + +See the README.html file for instructions to build and run this sample diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/README.html b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/README.html new file mode 100644 index 0000000000..0d59d27c23 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/README.html @@ -0,0 +1,235 @@ + +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<!-- + Copyright 2006 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. + --> +<HTML> +<HEAD> + <META CONTENT="text/html; charset=iso-8859-1" HTTP-EQUIV="Content-Type"> + <META CONTENT="text/css" HTTP-EQUIV="Content-Style-Type"> + <STYLE MEDIA="all" TYPE="text/css"> +@import url("../../doc/css/maven-base.css"); +@import url("../../doc/css/maven-theme.css"); + </STYLE> + + <LINK HREF="../doc/css/maven-theme.css" MEDIA="print" REL="stylesheet" + TYPE="text/css"> + <TITLE>Tuscany SCA for C++ Samples - RubyBank Sample</TITLE> +</HEAD> + +<BODY> +<DIV ID="bodyColumn"> + <DIV ID="contentBox"> + <DIV CLASS="section"> + <H2>Tuscany SCA for C++ Samples - RubyBank Sample</H2> + + <P>This sample implements the "Simplified RubyBank" scenario. A whitepaper describing + the scenario based on the SCA 0.9 Assembly specification can be found + <A HREF="http://www.osoa.org/display/Main/SCA+-+Previously+Published+Specifications">here</A>. + This sample uses multiple Ruby components, calls out to an external Web Service via a reference + and exposes the service as a Web Service. + </P> + <P>There are two sub projects in this workspace:</P> + <UL> + <LI>bigbank.account<BR/> + This contains the source code and SCDL artifacts for the SCA RubyBank + composite implementing the account services. + </LI> + <LI>bigbank.client<BR/> + A sample client which does a local call to the RubyBank service. + </LI> + </UL> + <P>Additionally, there is the bigbank.accountmanagement.composite file. This + describes the configuration of the SCA Calculator composite deployed to the SCA + runtime. + </P> + </DIV> + + <DIV CLASS="section"> + <H2>Contents</H2> + <OL> + <LI><A HREF="#linuxbld">Building the C++ samples on Linux</A></LI> + <LI><A HREF="#linuxrun">Running the RubyBank sample on Linux:</A></LI> + <UL> + <LI><A HREF="#linuxbasic">Running the basic client</A></LI> + <LI><A HREF="#linuxws">Running with Web Service clients</A></LI> + </UL> + <LI><A HREF="#winbld">Building the RubyBank sample on Windows</A></LI> + <LI><A HREF="#winrun">Running the RubyBank sample on Windows:</A></LI> + <UL> + <LI><A HREF="#winbasic">Running the basic client</A></LI> + <LI><A HREF="#winws">Running with Web Service clients</A></LI> + </UL> + <LI><A HREF="#help">Getting help</A></LI> + </OL> + </DIV> + + + <DIV CLASS="section"> + <A NAME="linuxbld"><H2>Building the C++ samples on Linux</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#linuxrun">Running the samples on Linux</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>As the RubyBank sample is based on Ruby scripts, a specific compilation step is not necessary - + only deployment is required. Deploy the Ruby samples only with the following command sequence: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples</LI> + <LI>./configure --enable-ruby --enable-cpp=no --prefix=$TUSCANY_SCACPP</LI> + <LI>make install</LI> + </UL> + NOTE: If you don't provide the --prefix configure option, it will by default install into + /usr/local/tuscany/sca/samples/RubyBank + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="linuxrun"><H2>Running the RubyBank sample on Linux</H2></A> + <A NAME="linuxbasic"><H3>RubyBank with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.92></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/RubyBank/deploy/bigbank.client</LI> + <LI>./runclient.sh</LI> + </UL> + </LI> + </OL> + <A NAME="linuxws"><H3>RubyBank with Web Service clients</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/RubyBank/deploy/bigbank.account + </LI> + <LI>./runwsserver.sh</LI> + </OL> + </LI> + <LI>The Web Service client and PHP web client detailed in the + <A HREF="../BigBank/README.html">BigBank</A> sample can both be used + with the RubyBank service that is served by the Axis2C http server started above. + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winbld"><H2>Building the RubyBank sample on Windows</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#winrun">Running the samples on Windows</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>As this sample is based on Ruby scripts, a specific compilation step is not necessary - + only deployment is required. Deploy the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/RubyBank</LI> + <LI>./deploy.cmd</LI> + </UL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winrun"><H2>Running the RubyBank sample on Windows</H2></A> + <A NAME="winbasic"><H3>RubyBank with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/RubyBank/deploy/bigbank.client</LI> + <LI>./runclient.bat</LI> + </UL> + </LI> + </OL> + <A NAME="winws"><H3>RubyBank with Web Service clients</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/RubyBank/deploy/bigbank.account + </LI> + <LI>./runwsserver.bat</LI> + </OL> + </LI> + <LI>The Web Service client and PHP web client detailed in the + <A HREF="../BigBank/README.html">BigBank</A> sample can both be used + with the RubyBank service that is served by the Axis2C http server started above. + </LI> + </OL> + </DIV> + + + + <DIV CLASS="section"> + <A NAME="help"><H2>Getting Help</H2></A> + + <P>First place to look is at the Tuscany FAQ at + <A HREF="http://incubator.apache.org/tuscany/faq.html" + TARGET="_blank">http://incubator.apache.org/tuscany/faq.html</A> </P> + + <P>Any problem with this release can be reported to the Tuscany + <A HREF="http://incubator.apache.org/tuscany/mail-lists.html" + TARGET="_blank">mailing lists</A> or create a JIRA issue at + <A HREF="http://issues.apache.org/jira/browse/Tuscany" + TARGET="_blank">http://issues.apache.org/jira/browse/Tuscany</A>.</P> + </DIV> + </DIV> +</DIV> +</BODY> + +</HTML> + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountDataServiceImpl.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountDataServiceImpl.rb new file mode 100644 index 0000000000..8ae0e23bab --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountDataServiceImpl.rb @@ -0,0 +1,72 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# + +require "rexml/document" +include REXML + +class AccountDataServiceImpl + + def initialize() + print "Ruby - AccountDataServiceImpl.initialize\n" + end + + def getCheckingAccount(id) + print "Ruby - AccountDataServiceImpl.getCheckingAccount ", id, "\n" + + result = Document.new <<-eof + <CheckingAccount xmlns="http://www.bigbank.com/AccountService" + xsi:type="CheckingAccount" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <accountNumber>#{ id.to_s + "_CHA12345"}</accountNumber> + <balance>1500.0</balance> + </CheckingAccount> + eof + + return result + end + + def getSavingsAccount(id) + print "Ruby - AccountDataServiceImpl.getSavingsAccount ", id, "\n" + + result = Document.new <<-eof + <SavingsAccount xmlns="http://www.bigbank.com/AccountService" + xsi:type="SavingsAccount" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <accountNumber>#{ id.to_s + "_SAA12345"}</accountNumber> + <balance>1500.0</balance> + </SavingsAccount> + eof + + return result + end + + def getStockAccount(id) + print "Ruby - AccountDataServiceImpl.getStockAccount ", id, "\n" + + result = Document.new <<-eof + <StockAccount xmlns="http://www.bigbank.com/AccountService" + xsi:type="StockAccount" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <accountNumber>#{ id.to_s + "_STA12345"}</accountNumber> + <symbol>IBM</symbol> + <quantity>100</quantity> + <balance></balance> + </StockAccount> + eof + + return result + end + +end diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountService.wsdl new file mode 100644 index 0000000000..cbfe180692 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountService.wsdl @@ -0,0 +1,126 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://www.bigbank.com/AccountService" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + targetNamespace="http://www.bigbank.com/AccountService" + name="AccountService"> + + <wsdl:types> + <xsd:schema + targetNamespace="http://www.bigbank.com/AccountService" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:element name="getAccountReport"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="customerID" + type="xsd:string" /> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + + <xsd:element name="getAccountReportResponse"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="result" + type="tns:AccountReport" /> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + + <xsd:complexType name="AccountReport"> + <xsd:sequence> + <xsd:element name="checking" + type="tns:CheckingAccount" maxOccurs="unbounded" /> + <xsd:element name="savings" + type="tns:SavingsAccount" maxOccurs="unbounded" /> + <xsd:element name="stocks" type="tns:StockAccount" + maxOccurs="unbounded" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="StockAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="symbol" type="xsd:string" /> + <xsd:element name="quantity" type="xsd:integer" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="CheckingAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="SavingsAccount"> + <xsd:sequence> + <xsd:element name="accountNumber" type="xsd:string" /> + <xsd:element name="balance" type="xsd:float" /> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="getAccountReportRequest"> + <wsdl:part element="tns:getAccountReport" + name="getAccountReportRequest" /> + </wsdl:message> + + <wsdl:message name="getAccountReportResponse"> + <wsdl:part element="tns:getAccountReportResponse" + name="getAccountReportResponse" /> + </wsdl:message> + + <wsdl:portType name="AccountService"> + <wsdl:operation name="getAccountReport"> + <wsdl:input message="tns:getAccountReportRequest" /> + <wsdl:output message="tns:getAccountReportResponse" /> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="AccountServiceSOAP" type="tns:AccountService"> + <soap:binding style="document" + transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getAccountReport"> + <soap:operation + soapAction="http://www.bigbank.com/AccountService/getAccountReport" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="AccountService"> + <wsdl:port binding="tns:AccountServiceSOAP" + name="AccountServiceSOAP"> + <soap:address + location="http://localhost:9090/axis2/services/AccountService" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountServiceImpl.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountServiceImpl.rb new file mode 100644 index 0000000000..a82b226a76 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/AccountServiceImpl.rb @@ -0,0 +1,94 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# + +require "rexml/document" +include REXML + +class AccountServiceImpl + + attr_writer :accountDataService + attr_writer :stockQuoteService + attr_writer :currency + + def initialize() + print "Ruby - AccountServiceImpl.initialize\n" + end + + def getAccountReport(customerID) + + checking = @accountDataService.getCheckingAccount(customerID) + + savings = @accountDataService.getSavingsAccount(customerID) + + stock = @accountDataService.getStockAccount(customerID); + symbol = stock.root.elements["symbol"].text + quantity = stock.root.elements["quantity"].text + + price = @stockQuoteService.getQuote(symbol); + + balance = fromUSDollarToCurrency(price.to_f * quantity.to_f) + + report = Document.new <<-eof + <AccountReport xmlns="http://www.bigbank.com/AccountService" + xsi:type="AccountReport" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + + <checking> + <accountNumber> + #{ checking.root.elements["accountNumber"].text } + </accountNumber> + <balance> + #{ fromUSDollarToCurrency(checking.root.elements["balance"].text) } + </balance> + </checking> + + <savings> + <accountNumber> + #{ savings.root.elements["accountNumber"].text } + </accountNumber> + <balance> + #{ fromUSDollarToCurrency(savings.root.elements["balance"].text) } + </balance> + </savings> + + <stocks> + <accountNumber> + #{ stock.root.elements["accountNumber"].text } + </accountNumber> + <symbol> + #{ symbol } + </symbol> + <quantity> + #{ quantity } + </quantity> + <balance> + #{ balance } + </balance> + </stocks> + + </AccountReport> + eof + + return report + end + + def fromUSDollarToCurrency(value) + return value.to_f * 0.8 if @currency == "EURO" + return value.to_f + end + +end diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/Makefile.am new file mode 100644 index 0000000000..66344fc2bf --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/Makefile.am @@ -0,0 +1,7 @@ +deploydir=$(prefix)/samples/RubyBank/deploy +compositedir=$(deploydir)/bigbank.account + +composite_SCRIPTS = runwsserver.sh + +composite_DATA = *.composite *.wsdl *.xsd *.rb +EXTRA_DIST = *.composite *.wsdl *.xsd runwsserver.sh *.rb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteServiceImpl.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteServiceImpl.rb new file mode 100644 index 0000000000..c8bbe248a3 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteServiceImpl.rb @@ -0,0 +1,41 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# + +require "rexml/document" +include REXML + +class StockQuoteServiceImpl + + attr_writer :webService + + def initialize() + print "Ruby - StockQuoteServiceImpl.initialize\n" + end + + def getQuote(symbol) + print "Ruby - StockQuoteServiceImpl.getQuote ", symbol, "\n" + + result = @webService.GetQuote(symbol) + doc = Document.new(result) + + price = doc.root.elements["Stock"].elements["Last"].text; + + return price.to_f + end + +end
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteTypes.xsd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteTypes.xsd new file mode 100644 index 0000000000..2f7012b5fb --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteTypes.xsd @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <xs:element name="StockQuotes" type="tStockQuotes"/> + <xs:complexType name="tStockQuotes"> + <xs:sequence> + <xs:element name="Stock" type="tStock" minOccurs="0" maxOccurs="unbounded"/> + <xs:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + <xs:anyAttribute namespace="##any" processContents="lax"/> + </xs:complexType> + + <xs:complexType name="tStock"> + <xs:sequence> + <xs:element minOccurs="0" maxOccurs="1" name="Symbol" type="xs:string"/> + <xs:element minOccurs="0" maxOccurs="1" name="Last" type="xs:float"/> + <xs:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + <xs:anyAttribute namespace="##any" processContents="lax"/> + </xs:complexType> +</xs:schema>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteWebService.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteWebService.wsdl new file mode 100644 index 0000000000..c14f97c87b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/StockQuoteWebService.wsdl @@ -0,0 +1,165 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" + xmlns:tns="http://www.webserviceX.NET/" + xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + targetNamespace="http://www.webserviceX.NET/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:types> + <s:schema elementFormDefault="qualified" + targetNamespace="http://www.webserviceX.NET/"> + <s:element name="GetQuote"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="symbol" type="s:string" /> + </s:sequence> + </s:complexType> + + </s:element> + <s:element name="GetQuoteResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" + name="GetQuoteResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="string" nillable="true" type="s:string" /> + + </s:schema> + </wsdl:types> + <wsdl:message name="GetQuoteSoapIn"> + <wsdl:part name="parameters" element="tns:GetQuote" /> + </wsdl:message> + <wsdl:message name="GetQuoteSoapOut"> + <wsdl:part name="parameters" element="tns:GetQuoteResponse" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpGetIn"> + + <wsdl:part name="symbol" type="s:string" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpGetOut"> + <wsdl:part name="Body" element="tns:string" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpPostIn"> + <wsdl:part name="symbol" type="s:string" /> + </wsdl:message> + <wsdl:message name="GetQuoteHttpPostOut"> + + <wsdl:part name="Body" element="tns:string" /> + </wsdl:message> + <wsdl:portType name="StockQuoteSoap"> + <wsdl:operation name="GetQuote"> + <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"> + Get Stock quote for a company Symbol + </documentation> + <wsdl:input message="tns:GetQuoteSoapIn" /> + <wsdl:output message="tns:GetQuoteSoapOut" /> + </wsdl:operation> + + </wsdl:portType> + <wsdl:portType name="StockQuoteHttpGet"> + <wsdl:operation name="GetQuote"> + <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"> + Get Stock quote for a company Symbol + </documentation> + <wsdl:input message="tns:GetQuoteHttpGetIn" /> + <wsdl:output message="tns:GetQuoteHttpGetOut" /> + </wsdl:operation> + </wsdl:portType> + + <wsdl:portType name="StockQuoteHttpPost"> + <wsdl:operation name="GetQuote"> + <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"> + Get Stock quote for a company Symbol + </documentation> + <wsdl:input message="tns:GetQuoteHttpPostIn" /> + <wsdl:output message="tns:GetQuoteHttpPostOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="StockQuoteSoap" type="tns:StockQuoteSoap"> + + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" + style="document" /> + <wsdl:operation name="GetQuote"> + <soap:operation + soapAction="http://www.webserviceX.NET/GetQuote" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="StockQuoteHttpGet" + type="tns:StockQuoteHttpGet"> + <http:binding verb="GET" /> + <wsdl:operation name="GetQuote"> + <http:operation location="/GetQuote" /> + <wsdl:input> + <http:urlEncoded /> + </wsdl:input> + + <wsdl:output> + <mime:mimeXml part="Body" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="StockQuoteHttpPost" + type="tns:StockQuoteHttpPost"> + <http:binding verb="POST" /> + <wsdl:operation name="GetQuote"> + <http:operation location="/GetQuote" /> + + <wsdl:input> + <mime:content type="application/x-www-form-urlencoded" /> + </wsdl:input> + <wsdl:output> + <mime:mimeXml part="Body" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="StockQuote"> + + <wsdl:port name="StockQuoteSoap" binding="tns:StockQuoteSoap"> + <soap:address + location="http://www.webservicex.net/stockquote.asmx" /> + </wsdl:port> + <wsdl:port name="StockQuoteHttpGet" + binding="tns:StockQuoteHttpGet"> + <http:address + location="http://www.webservicex.net/stockquote.asmx" /> + </wsdl:port> + <wsdl:port name="StockQuoteHttpPost" + binding="tns:StockQuoteHttpPost"> + <http:address + location="http://www.webservicex.net/stockquote.asmx" /> + </wsdl:port> + + </wsdl:service> +</wsdl:definitions>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/bigbank.account.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/bigbank.account.composite new file mode 100644 index 0000000000..96f0bd652f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/bigbank.account.composite @@ -0,0 +1,53 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="bigbank.account"> + + <service name="AccountService"> + <interface.wsdl interface="http://www.bigbank.com/AccountService#wsdl.interface(AccountService)"/> + <!-- The endpoint is optional --> + <!-- <binding.ws endpoint="http://www.bigbank.com/AccountService#wsdl.endpoint(AccountService/AccountServiceSOAP)"/> --> + <binding.ws/> + <reference>AccountServiceComponent</reference> + </service> + + <component name="AccountServiceComponent"> + <implementation.ruby script="AccountServiceImpl.rb" class="AccountServiceImpl"/> + <reference name="accountDataService">AccountDataServiceComponent</reference> + <reference name="stockQuoteService">StockQuoteServiceComponent</reference> + <property name="currency">EURO</property> + </component> + + <component name="AccountDataServiceComponent"> + <implementation.ruby script="AccountDataServiceImpl.rb" class="AccountDataServiceImpl"/> + </component> + + <component name="StockQuoteServiceComponent"> + <implementation.ruby script="StockQuoteServiceImpl.rb" class="StockQuoteServiceImpl"/> + <reference name="webService">StockQuoteWebService</reference> + </component> + + <reference name="StockQuoteWebService"> + <interface.wsdl interface="http://www.webserviceX.NET/#wsdl.interface(StockQuoteSoap)"/> + <binding.ws endpoint="http://www.webserviceX.NET/#wsdl.endpoint(StockQuote/StockQuoteSoap)"/> + </reference> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/runwsserver.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/runwsserver.bat new file mode 100644 index 0000000000..f95d5136ef --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/runwsserver.bat @@ -0,0 +1,51 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo Using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo Using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo Using Axis2C installed at %AXIS2C_HOME% + +set APFULLDIR=%~d0%~p0 +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +rem Run the client +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SCACPP%\extensions\cpp\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %AXIS2C_HOME%\bin +.\axis2_http_server.exe + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/runwsserver.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/runwsserver.sh new file mode 100755 index 0000000000..eb20a3d670 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.account/runwsserver.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/extensions/cpp/lib:$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +cd $AXIS2C_HOME/bin +./axis2_http_server diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.accountmanagement.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.accountmanagement.composite new file mode 100644 index 0000000000..f5f0bbbb57 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.accountmanagement.composite @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="bigbank.accountmanagement"> + + <component name="bigbank.AccountManagementComponent"> + <implementation.composite name="bigbank.account"/> + </component> + +</composite> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/AccountClient.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/AccountClient.rb new file mode 100644 index 0000000000..731c77c9ce --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/AccountClient.rb @@ -0,0 +1,26 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# + +require("tuscany_sca_ruby") + +accountService = SCA::locateService("AccountServiceComponent") + +report = accountService.getAccountReport(1234) + +print report diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/Makefile.am new file mode 100644 index 0000000000..4b0b201ac7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/Makefile.am @@ -0,0 +1,6 @@ +deploydir=$(prefix)/samples/RubyBank/deploy +clientdir=$(deploydir)/bigbank.client + +client_DATA = *.rb +client_SCRIPTS = runclient.sh +EXTRA_DIST = runclient.sh *.rb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/runclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/runclient.bat new file mode 100644 index 0000000000..f50bc2aa2d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/runclient.bat @@ -0,0 +1,51 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo Using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo Using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo Using Axis2C installed at %AXIS2C_HOME% + +set APFULLDIR=%~d0%~p0 +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +rem Run the client +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %TUSCANY_SCACPP_SYSTEM_ROOT%\bigbank.client +ruby -I%TUSCANY_SCACPP%\extensions\ruby\bin AccountClient.rb + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/runclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/runclient.sh new file mode 100755 index 0000000000..7ed579d393 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/bigbank.client/runclient.sh @@ -0,0 +1,49 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=bigbank.AccountManagementComponent + +cd $TUSCANY_SCACPP_SYSTEM_ROOT/bigbank.client +ruby -I$TUSCANY_SCACPP/extensions/ruby/lib AccountClient.rb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/deploy.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/deploy.cmd new file mode 100644 index 0000000000..59b797e564 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyBank/deploy.cmd @@ -0,0 +1,53 @@ +@echo off
+@REM Licensed to the Apache Software Foundation (ASF) under one
+@REM or more contributor license agreements. See the NOTICE file
+@REM distributed with this work for additional information
+@REM regarding copyright ownership. The ASF licenses this file
+@REM to you under the Apache License, Version 2.0 (the
+@REM "License"); you may not use this file except in compliance
+@REM with the License. You may obtain a copy of the License at
+@REM
+@REM http://www.apache.org/licenses/LICENSE-2.0
+@REM
+@REM Unless required by applicable law or agreed to in writing,
+@REM software distributed under the License is distributed on an
+@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+@REM KIND, either express or implied. See the License for the
+@REM specific language governing permissions and limitations
+@REM under the License.
+
+rem Will copy the correct files from the source tree for packaging and deployment of the
+rem SCA sample.
+setlocal
+set currentPath=%~d0%~p0
+set sourcePath=%currentPath%
+
+set deploydir=%TUSCANY_SCACPP%
+set samplesdir=%deploydir%\samples
+set bbdir=%samplesdir%\RubyBank
+
+
+if . == %1. (
+set destinationPath=%bbdir%\deploy
+) ELSE (
+set destinationPath=%1
+)
+
+if not exist %samplesdir% mkdir %samplesdir%
+if not exist %bbdir% mkdir %bbdir%
+if not exist %destinationPath% mkdir %destinationPath%
+if not exist %destinationPath%\bigbank.account mkdir %destinationPath%\bigbank.account
+if not exist %destinationPath%\bigbank.client mkdir %destinationPath%\bigbank.client
+
+copy %sourcePath%\bigbank.account\*.rb %destinationPath%\bigbank.account
+copy %sourcePath%\bigbank.account\*.composite %destinationPath%\bigbank.account
+copy %sourcePath%\bigbank.account\*.wsdl %destinationPath%\bigbank.account
+copy %sourcePath%\bigbank.account\*.xsd %destinationPath%\bigbank.account
+copy %sourcePath%\bigbank.account\*.bat %destinationPath%\bigbank.account
+
+copy %sourcePath%\bigbank.client\*.rb %destinationPath%\bigbank.client
+copy %sourcePath%\bigbank.client\*.bat %destinationPath%\bigbank.client
+
+copy %sourcePath%\*.composite %destinationPath%
+
+endlocal
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/Makefile.am new file mode 100644 index 0000000000..908112e3cd --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/Makefile.am @@ -0,0 +1,4 @@ +deploydir=$(prefix)/samples/RubyCalculator/deploy +SUBDIRS = sample.calculator sample.calculator.client sample.calculator.wsclient +EXTRA_DIST = *.composite README.html +deploy_DATA = *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/README b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/README new file mode 100644 index 0000000000..4104ff46b6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/README @@ -0,0 +1,23 @@ +Tuscany SCA for C++ Samples - Calculator Sample +=============================================== + +This is a very simple sample to show how an SCA composite can wire together +two components to implement a Calculator service and expose that service as +a Web Service. + +There are three sub projects in this workspace: + - sample.calculator + This contains the source code and SCDL artifacts for the SCA Calculator. + composite implementing the sample Calculator. + + - sample.calculator.client + A sample client which does a local call to the Calculator service. + + - sample.calculator.wsclient + A sample Axis2 Web Service client which calls the Calculator Web service. + +Additionally, there is the sample.calculator.solution.composite file. This +describes the configuration of the SCA Calculator composite deployed to the +SCA runtime. + +See the README.html file for instructions to build and run this sample diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/README.html b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/README.html new file mode 100644 index 0000000000..e5e2a832cf --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/README.html @@ -0,0 +1,249 @@ + +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<!-- + Copyright 2006 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. + --> +<HTML> +<HEAD> + <META CONTENT="text/html; charset=iso-8859-1" HTTP-EQUIV="Content-Type"> + <META CONTENT="text/css" HTTP-EQUIV="Content-Style-Type"> + <STYLE MEDIA="all" TYPE="text/css"> +@import url("../../doc/css/maven-base.css"); +@import url("../../doc/css/maven-theme.css"); + </STYLE> + + <LINK HREF="../doc/css/maven-theme.css" MEDIA="print" REL="stylesheet" + TYPE="text/css"> + <TITLE>Tuscany SCA for C++ Samples - RubyCalculator Sample</TITLE> +</HEAD> + +<BODY> +<DIV ID="bodyColumn"> + <DIV ID="contentBox"> + <DIV CLASS="section"> + <H2>Tuscany SCA for C++ Samples - RubyCalculator Sample</H2> + + <P>This is a very simple sample to show how an SCA composite can wire + together two Ruby components to implement a Calculator service and expose + that service as a Web Service. + </P> + <P>There are three sub projects in this workspace:</P> + <UL> + <LI>sample.calculator<BR/> + This contains the Ruby scripts and SCDL artifacts for the SCA Calculator + composite implementing the sample Calculator. + </LI> + <LI>sample.calculator.client<BR/> + A sample client which does a local call to the Calculator service. + </LI> + <LI>sample.calculator.wsclient<BR/> + A sample client which does a local call to a composite that contains a Web Service reference + that calls the Calculator Web Service. + </LI> + </UL> + <P>Additionally, there is the sample.calculator.solution.composite file. This + describes the configuration of the SCA Calculator composite deployed to the SCA + runtime. + </P> + </DIV> + + <DIV CLASS="section"> + <H2>Contents</H2> + <OL> + <LI><A HREF="#linuxbld">Building the Ruby samples on Linux</A></LI> + <LI><A HREF="#linuxrun">Running the RubyCalculator sample on Linux:</A></LI> + <UL> + <LI><A HREF="#linuxbasic">Running the basic client</A></LI> + <LI><A HREF="#linuxws">Running the Web Service client</A></LI> + </UL> + <LI><A HREF="#winbld">Building the RubyCalculator sample on Windows</A></LI> + <LI><A HREF="#winrun">Running the RubyCalculator sample on Windows:</A></LI> + <UL> + <LI><A HREF="#winbasic">Running the basic client</A></LI> + <LI><A HREF="#winws">Running the Web Service client</A></LI> + </UL> + <LI><A HREF="#help">Getting help</A></LI> + </OL> + </DIV> + + + <DIV CLASS="section"> + <A NAME="linuxbld"><H2>Building the Ruby samples on Linux</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#linuxrun">Running the samples on Linux</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>As the RubyCalculator sample is based on Ruby scripts, a specific compilation step is not necessary - + only deployment is required. Deploy the Ruby samples only with the following command sequence: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples</LI> + <LI>./configure --enable-ruby --enable-cpp=no --prefix=$TUSCANY_SCACPP</LI> + <LI>make install</LI> + </UL> + NOTE: If you don't provide the --prefix configure option, it will by default install into + /usr/local/tuscany/sca/samples/RubyCalculator</LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="linuxrun"><H2>Running the RubyCalculator sample on Linux</H2></A> + <A NAME="linuxbasic"><H3>RubyCalculator with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator/deploy/sample.calculator.client</LI> + <LI>./runclient.sh</LI> + </UL> + </LI> + </OL> + <A NAME="linuxws"><H3>RubyCalculator with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator/deploy/sample.calculator</LI> + <LI>./runwsserver.sh</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variable is required: + <UL> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator/deploy/sample.calculator.wsclient</LI> + <LI>./runwsclient.sh</LI> + </OL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winbld"><H2>Building the RubyCalculator sample on Windows</H2></A> + <P>If using the binary distribution the samples are built and installed in + <tuscany_sca_install_dir>/samples - go directly to <A HREF="#winrun">Running the samples on Windows</A>.</P> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL></LI> + </LI> + <LI>As this sample is based on Ruby scripts, a specific compilation step is not necessary - + only deployment is required. Deploy the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator</LI> + <LI>./deploy.cmd</LI> + </UL> + </LI> + </OL> + </DIV> + + <DIV CLASS="section"> + <A NAME="winrun"><H2>Running the RubyCalculator sample on Windows</H2></A> + <A NAME="winbasic"><H3>RubyCalculator with basic client</H3></A> + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>Run the sample with the following commands: + <UL> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator/deploy/sample.calculator.client</LI> + <LI>./runclient.bat</LI> + </UL> + </LI> + </OL> + <A NAME="winws"><H3>RubyCalculator with Web Service client</H3></A> + <OL> + <LI>Ensure you have enabled Axis2C to run Tuscany SCA services. Follow the instructions + found <A HREF="../../../doc/Axis2CWSService.html">here</A>. + </LI> + <LI>Start the Axis2C simple http server: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator/deploy/sample.calculator</LI> + <LI>./runwsserver.bat</LI> + </OL> + </LI> + <LI>Run the client: + <OL> + <LI>The following environment variables are required: + <UL> + <LI>TUSCANY_SCACPP=<path to installed Tuscany SCA></LI> + <LI>TUSCANY_SDOCPP=<path to installed Tuscany SDO></LI> + <LI>AXIS2C_HOME=<path to axis2c version 0.94></LI> + </UL> + </LI> + <LI>cd <tuscany_sca_install_dir>/samples/RubyCalculator/deploy/sample.calculator.wsclient</LI> + <LI>./runwsclient.bat</LI> + </OL> + </LI> + </OL> + </DIV> + + + + <DIV CLASS="section"> + <A NAME="help"><H2>Getting Help</H2></A> + + <P>First place to look is at the Tuscany FAQ at + <A HREF="http://incubator.apache.org/tuscany/faq.html" + TARGET="_blank">http://incubator.apache.org/tuscany/faq.html</A> </P> + + <P>Any problem with this release can be reported to the Tuscany + <A HREF="http://incubator.apache.org/tuscany/mail-lists.html" + TARGET="_blank">mailing lists</A> or create a JIRA issue at <A HREF="http://issues.apache.org/jira/browse/Tuscany" + TARGET="_blank">http://issues.apache.org/jira/browse/Tuscany</A>.</P> + </DIV> + </DIV> +</DIV> +</BODY> + +</HTML> + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/deploy.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/deploy.cmd new file mode 100644 index 0000000000..2609c3b1e5 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/deploy.cmd @@ -0,0 +1,56 @@ +@echo off
+@REM Licensed to the Apache Software Foundation (ASF) under one
+@REM or more contributor license agreements. See the NOTICE file
+@REM distributed with this work for additional information
+@REM regarding copyright ownership. The ASF licenses this file
+@REM to you under the Apache License, Version 2.0 (the
+@REM "License"); you may not use this file except in compliance
+@REM with the License. You may obtain a copy of the License at
+@REM
+@REM http://www.apache.org/licenses/LICENSE-2.0
+@REM
+@REM Unless required by applicable law or agreed to in writing,
+@REM software distributed under the License is distributed on an
+@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+@REM KIND, either express or implied. See the License for the
+@REM specific language governing permissions and limitations
+@REM under the License.
+
+rem Will copy the correct files from the source tree for packaging and deployment of the
+rem SCA sample.
+setlocal
+set currentPath=%~d0%~p0
+set sourcePath=%currentPath%
+
+set deploydir=%TUSCANY_SCACPP%
+set samplesdir=%deploydir%\samples
+set calcdir=%samplesdir%\RubyCalculator
+
+if . == %1. (
+set destinationPath=%calcdir%\deploy
+) ELSE (
+set destinationPath=%1
+)
+
+if not exist %samplesdir% mkdir %samplesdir%
+if not exist %calcdir% mkdir %calcdir%
+if not exist %destinationPath% mkdir %destinationPath%
+if not exist %destinationPath%\sample.calculator mkdir %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\*.composite %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\*.rb %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\Calculator.wsdl %destinationPath%\sample.calculator
+copy %sourcePath%\sample.calculator\runwsserver.bat %destinationPath%\sample.calculator
+
+if not exist %destinationPath%\sample.calculator.client mkdir %destinationPath%\sample.calculator.client
+copy %sourcePath%\sample.calculator.client\CalculatorClient.rb %destinationPath%\sample.calculator.client
+copy %sourcePath%\sample.calculator.client\runclient.bat %destinationPath%\sample.calculator.client
+
+if not exist %destinationPath%\sample.calculator.wsclient mkdir %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\CalculatorWSClient.rb %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\sample.calculator.wsclient.composite %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\Calculator.wsdl %destinationPath%\sample.calculator.wsclient
+copy %sourcePath%\sample.calculator.wsclient\runwsclient.bat %destinationPath%\sample.calculator.wsclient
+
+copy %sourcePath%\*.composite %destinationPath%
+
+endlocal
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/CalculatorClient.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/CalculatorClient.rb new file mode 100644 index 0000000000..253928df0c --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/CalculatorClient.rb @@ -0,0 +1,25 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# + +require("tuscany_sca_ruby") + +calculator = SCA::locateService("CalculatorComponent") + +x = calculator.div(5, 2) +print x, "\n" diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/Makefile.am new file mode 100644 index 0000000000..06ffb81173 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/Makefile.am @@ -0,0 +1,6 @@ +deploydir=$(prefix)/samples/RubyCalculator/deploy +clientdir=$(deploydir)/sample.calculator.client + +client_DATA = *.rb +client_SCRIPTS = runclient.sh +EXTRA_DIST = runclient.sh *.rb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/runclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/runclient.bat new file mode 100644 index 0000000000..4e9cc0f2cd --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/runclient.bat @@ -0,0 +1,49 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %TUSCANY_SCACPP_SYSTEM_ROOT%\sample.calculator.client +ruby -I%TUSCANY_SCACPP%\extensions\ruby\bin CalculatorClient.rb + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/runclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/runclient.sh new file mode 100755 index 0000000000..974dd2e41c --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.client/runclient.sh @@ -0,0 +1,49 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +cd $TUSCANY_SCACPP_SYSTEM_ROOT/sample.calculator.client +ruby -I$TUSCANY_SCACPP/extensions/ruby/lib CalculatorClient.rb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.solution.composite new file mode 100644 index 0000000000..0a8ae343db --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.solution.composite @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator.solution"> + + <component name="sample.calculator.CalculatorComponent"> + <implementation.composite name="sample.calculator" /> + </component> + + <component name="sample.calculator.CalculatorWSClientComponent"> + <implementation.composite name="sample.calculator.wsclient" /> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/Calculator.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/Calculator.wsdl new file mode 100644 index 0000000000..f74c3d5c33 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/Calculator.wsdl @@ -0,0 +1,114 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" + targetNamespace="http://sample/calculator"> + <types> + <xs:schema targetNamespace="http://sample/calculator" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" elementFormDefault="qualified"> + + <xs:element name="add"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="sub"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="mul"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="div"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="result"> + <xs:complexType> + <xs:sequence> + <xs:element name="data" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </types> + + <message name="addRequestMsg"> + <part name="body" element="tns:add" /> + </message> + <message name="subRequestMsg"> + <part name="body" element="tns:sub" /> + </message> + <message name="mulRequestMsg"> + <part name="body" element="tns:mul" /> + </message> + <message name="divRequestMsg"> + <part name="body" element="tns:div" /> + </message> + + <message name="calculatorResponseMsg"> + <part name="body" element="tns:result" /> + </message> + + <portType name="Calculator"> + <operation name="add"> + <input message="tns:addRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="sub"> + <input message="tns:subRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="mul"> + <input message="tns:mulRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="div"> + <input message="tns:divRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + </portType> + +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/CalculatorWSClient.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/CalculatorWSClient.rb new file mode 100644 index 0000000000..4022f8a636 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/CalculatorWSClient.rb @@ -0,0 +1,25 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# + +require("tuscany_sca_ruby") + +calculator = SCA::locateService("CalculatorService") + +x = calculator.div(5, 2) +print x, "\n" diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/Makefile.am new file mode 100644 index 0000000000..ab977e5b64 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/Makefile.am @@ -0,0 +1,6 @@ +deploydir=$(prefix)/samples/RubyCalculator/deploy +wsclientdir=$(deploydir)/sample.calculator.wsclient + +wsclient_DATA = *.rb *.wsdl *.composite +wsclient_SCRIPTS = runwsclient.sh +EXTRA_DIST = runwsclient.sh *.rb *.wsdl *.composite diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/runwsclient.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/runwsclient.bat new file mode 100644 index 0000000000..f9a1ad62a7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/runwsclient.bat @@ -0,0 +1,49 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorWSClientComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %TUSCANY_SCACPP_SYSTEM_ROOT%\sample.calculator.wsclient +ruby -I%TUSCANY_SCACPP%\extensions\ruby\bin CalculatorWSClient.rb + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/runwsclient.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/runwsclient.sh new file mode 100755 index 0000000000..ec4053fb74 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/runwsclient.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorWSClientComponent + +cd $TUSCANY_SCACPP_SYSTEM_ROOT/sample.calculator.wsclient +ruby -I$TUSCANY_SCACPP/extensions/ruby/lib CalculatorWSClient.rb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/sample.calculator.wsclient.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/sample.calculator.wsclient.composite new file mode 100644 index 0000000000..22d31b539c --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator.wsclient/sample.calculator.wsclient.composite @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator.wsclient"> + + <reference name="CalculatorService"> + <interface.wsdl interface="http://sample/calculator#wsdl.interface(Calculator)"/> + <binding.ws uri="http://localhost:9090/axis2/services/CalculatorService"/> + </reference> + +</composite>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/Calculator.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/Calculator.wsdl new file mode 100644 index 0000000000..f74c3d5c33 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/Calculator.wsdl @@ -0,0 +1,114 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" + targetNamespace="http://sample/calculator"> + <types> + <xs:schema targetNamespace="http://sample/calculator" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:tns="http://sample/calculator" elementFormDefault="qualified"> + + <xs:element name="add"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="sub"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="mul"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="div"> + <xs:complexType> + <xs:sequence> + <xs:element name="param1" type="xs:float"/> + <xs:element name="param2" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="result"> + <xs:complexType> + <xs:sequence> + <xs:element name="data" type="xs:float"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </types> + + <message name="addRequestMsg"> + <part name="body" element="tns:add" /> + </message> + <message name="subRequestMsg"> + <part name="body" element="tns:sub" /> + </message> + <message name="mulRequestMsg"> + <part name="body" element="tns:mul" /> + </message> + <message name="divRequestMsg"> + <part name="body" element="tns:div" /> + </message> + + <message name="calculatorResponseMsg"> + <part name="body" element="tns:result" /> + </message> + + <portType name="Calculator"> + <operation name="add"> + <input message="tns:addRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="sub"> + <input message="tns:subRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="mul"> + <input message="tns:mulRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + <operation name="div"> + <input message="tns:divRequestMsg" /> + <output message="tns:calculatorResponseMsg" /> + </operation> + </portType> + +</definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/CalculatorImpl.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/CalculatorImpl.rb new file mode 100644 index 0000000000..36ed15ff9b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/CalculatorImpl.rb @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# + +class CalculatorImpl + + attr_writer :divideService + + def initialize() + print "Ruby - CalculatorImpl.initialize\n" + end + + def div(arg1, arg2) + print "Ruby - CalculatorImpl.div\n" + @divideService.divide(arg1.to_f, arg2.to_f) + end + + def add(arg1, arg2) + print "Ruby - CalculatorImpl.add\n" + arg1.to_f + arg2.to_f + end + + def sub(arg1, arg2) + print "Ruby - CalculatorImpl.sub\n" + arg1.to_f - arg2.to_f + end + + def mul(arg1, arg2) + print "Ruby - CalculatorImpl.mul\n" + arg1.to_f * arg2.to_f + end + +end
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/DivideImpl.rb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/DivideImpl.rb new file mode 100644 index 0000000000..c6615bfcfa --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/DivideImpl.rb @@ -0,0 +1,39 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# +# + +class DivideImpl + + attr_writer :round + + def initialize() + print "Ruby - DivideImpl.initialize\n" + end + + def divide(arg1, arg2) + print "Ruby - DivideImpl.divide ", arg1, " / ", arg2, "\n" + res = arg1.to_f / arg2.to_f + if @round then + res = res.round + print "DivideImpl.divide rounding\n" + end + print "DivideImpl.divide ", res, "\n" + res + end + +end
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/Makefile.am b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/Makefile.am new file mode 100644 index 0000000000..6e85ad28a4 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/Makefile.am @@ -0,0 +1,7 @@ +deploydir=$(prefix)/samples/RubyCalculator/deploy +compositedir=$(deploydir)/sample.calculator + +composite_SCRIPTS = runwsserver.sh + +composite_DATA = *.composite *.wsdl *.rb +EXTRA_DIST = *.composite *.wsdl *.rb runwsserver.sh diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/runwsserver.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/runwsserver.bat new file mode 100644 index 0000000000..9870d4600d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/runwsserver.bat @@ -0,0 +1,49 @@ +@echo off + +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal + +if "%TUSCANY_SCACPP%" == "" ( +echo "TUSCANY_SCACPP not set" +goto end +) +echo using SCA installed at %TUSCANY_SCACPP% + +if "%TUSCANY_SDOCPP%" == "" ( +echo "TUSCANY_SDOCPP not set" +goto end +) +echo using SDO installed at %TUSCANY_SDOCPP% + +if "%AXIS2C_HOME%" == "" ( +echo "AXIS2C_HOME not set" +goto end +) +echo using Axis2C installed at %AXIS2C_HOME% + +set TUSCANY_SCACPP_SYSTEM_ROOT=%~d0%~p0\..\ +set TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +set PATH=%TUSCANY_SCACPP%\bin;%TUSCANY_SDOCPP%\bin;%AXIS2C_HOME%\lib;%PATH% + +cd %AXIS2C_HOME%\bin +.\axis2_http_server.exe + +:end +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/runwsserver.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/runwsserver.sh new file mode 100755 index 0000000000..69906579b2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/runwsserver.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +APFULLDIR=`pwd` + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +TEST_SYSTEM=$APFULLDIR/../ + +export LD_LIBRARY_PATH=$TUSCANY_SCACPP/lib:$TUSCANY_SDOCPP/lib:$AXIS2C_HOME/lib:$LD_LIBRARY_PATH + +export TUSCANY_SCACPP_SYSTEM_ROOT=$TEST_SYSTEM +export TUSCANY_SCACPP_DEFAULT_COMPONENT=sample.calculator.CalculatorComponent + +cd $AXIS2C_HOME/bin +./axis2_http_server diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/sample.calculator.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/sample.calculator.composite new file mode 100644 index 0000000000..90f68e8234 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/RubyCalculator/sample.calculator/sample.calculator.composite @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="sample.calculator"> + + <service name="CalculatorService"> + <interface.wsdl interface="http://sample/calculator#wsdl.interface(Calculator)"/> + <binding.ws/> + <reference>CalculatorComponent</reference> + </service> + + <component name="CalculatorComponent"> + <implementation.ruby script="CalculatorImpl.rb" class="CalculatorImpl"/> + <reference name="divideService">DivideComponent</reference> + </component> + + <component name="DivideComponent"> + <implementation.ruby script="DivideImpl.rb" class="DivideImpl"/> + <property name="round">true</property> + </component> + +</composite>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo.solution.composite new file mode 100644 index 0000000000..cf0df165ae --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo.solution.composite @@ -0,0 +1,34 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.demo.solution"> + + <component name="supplychain.DemoClient"> + <implementation.composite name="supplychain.demo"/> + <reference name="retailer">supplychain.Retailer/RetailerService</reference> + <reference name="logging">supplychain.Logging/LoggingService</reference> + </component> + + <component name="supplychain.Logging"> + <implementation.composite name="supplychain.logging"/> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo/DemoClientImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo/DemoClientImpl.componentType new file mode 100644 index 0000000000..a63e4c37d3 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo/DemoClientImpl.componentType @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <reference name="retailer"> + <interface.cpp header="Retailer.h"/> + </reference> + + <reference name="logging"> + <interface.cpp header="Logging.h"/> + </reference> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo/supplychain.demo.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo/supplychain.demo.composite new file mode 100644 index 0000000000..20b0e49ec1 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.demo/supplychain.demo.composite @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.demo"> + + <component name="DemoClient"> + <implementation.cpp library="demo" header="DemoClientImpl.h"/> + <reference name="retailer">retailer</reference> + <reference name="logging">logging</reference> + </component> + + <reference name="retailer"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl#wsdl.interface(RetailerPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl#wsdl.endpoint(RetailerService/RetailerPort)" + uri="http://localhost:9090/axis2/services/supplychain.retailer.solution/RetailerService"/> + </reference> + + <reference name="logging"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.interface(LoggingFacilityLogPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.endpoint(LoggingFacilityService/LoggingFacilityPort)"/> + </reference> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/LoggerImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/LoggerImpl.componentType new file mode 100644 index 0000000000..e78e602635 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/LoggerImpl.componentType @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="LoggingService"> + <interface.cpp header="Logging.h"/> + </service> + +</componentType>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/LoggingFacility.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/LoggingFacility.wsdl new file mode 100644 index 0000000000..c78357b1a8 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/LoggingFacility.wsdl @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> +<wsdl:definitions name="LoggingFacility" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl" + xmlns:tns="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + + <wsdl:import + namespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl" + location="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl" /> + + <wsdl:service name="LoggingFacilityService"> + <wsdl:port name="LoggingFacilityPort" + binding="tns:LoggingFacilitySoapBinding"> + <soap:address + location="http://localhost:9090/axis2/services/LoggingFacility" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/supplychain.logging.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/supplychain.logging.composite new file mode 100644 index 0000000000..2b28c8f9e2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.logging/supplychain.logging.composite @@ -0,0 +1,34 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.logging"> + + <service name="LoggingService"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.interface(LoggingFacilityLogPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.endpoint(LoggingFacilityService/LoggingFacilityPort)"/> + <reference>Logger/Logging</reference> + </service> + + <component name="Logger"> + <implementation.cpp library="logging" header="LoggerImpl.h"/> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/Manufacturer.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/Manufacturer.wsdl new file mode 100644 index 0000000000..fb0c8a5676 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/Manufacturer.wsdl @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions name="Manufacturer" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + targetNamespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl" + xmlns:tns="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl"> + + <wsdl:import + namespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl" + location="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl" /> + + <wsdl:service name="ManufacturerService"> + <wsdl:port name="ManufacturerPort" + binding="tns:ManufacturerSoapBinding"> + <soap:address + location="http://localhost:9090/axis2/services/Manufacturer" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/ManufacturerImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/ManufacturerImpl.componentType new file mode 100644 index 0000000000..63530bc0ee --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/ManufacturerImpl.componentType @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="ManufacturerService"> + <interface.cpp header="Manufacturer.h"/> + </service> + + <reference name="callback"> + <interface.cpp header="WarehouseCallback.h"/> + </reference> + + <reference name="logging"> + <interface.cpp header="Logging.h"/> + </reference> + + <property name="manufacturerID" type="xs:string"/> + +</componentType>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/WarehouseCallback.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/WarehouseCallback.wsdl new file mode 100644 index 0000000000..256671f64f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/WarehouseCallback.wsdl @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions name="WarehouseCallback" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + targetNamespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl" + xmlns:tns="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl"> + + <wsdl:import + namespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl" + location="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl" /> + + <wsdl:service name="WarehouseCallbackService"> + <wsdl:port name="WarehouseCallbackPort" + binding="tns:WarehouseCallbackSoapBinding"> + <soap:address + location="http://localhost:9090/axis2/services/WarehouseCallback" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/supplychain.manufacturer.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/supplychain.manufacturer.composite new file mode 100644 index 0000000000..c61657c0a7 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturer/supplychain.manufacturer.composite @@ -0,0 +1,50 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + name="supplychain.manufacturer"> + + <service name="ManufacturerService"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.interface(ManufacturerPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.endpoint(ManufacturerService/ManufacturerPort)"/> + <reference>ManufacturerProcess/ManufacturerService</reference> + </service> + + <property name="manufacturerID" type="xs:string"/> + + <component name="ManufacturerProcess"> + <implementation.cpp library="manufacturer" header="ManufacturerImpl.h"/> + <reference name="callback">callback</reference> + <reference name="logging">logging</reference> + <property name="manufacturerID" source="$manufacturerID"/> + </component> + + <reference name="logging"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.interface(LoggingFacilityLogPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.endpoint(LoggingFacilityService/LoggingFacilityPort)"/> + </reference> + + <reference name="callback"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.interface(WarehouseCallbackPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.endpoint(WarehouseCallbackService/WarehouseCallbackPort)"/> + </reference> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerA.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerA.solution.composite new file mode 100644 index 0000000000..17449e51fa --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerA.solution.composite @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.manufacturerA.solution"> + + <component name="supplychain.manufacturerA"> + <implementation.composite name="supplychain.manufacturer"/> + <reference name="logging">supplychain.Logging/LoggingService</reference> + <property name="manufacturerID">manufacturerA</property> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerB.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerB.solution.composite new file mode 100644 index 0000000000..94535d704a --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerB.solution.composite @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.manufacturerB.solution"> + + <component name="supplychain.manufacturerB"> + <implementation.composite name="supplychain.manufacturer"/> + <reference name="logging">supplychain.Logging/LoggingService</reference> + <property name="manufacturerID">manufacturerB</property> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerC.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerC.solution.composite new file mode 100644 index 0000000000..b4b9380af0 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.manufacturerC.solution.composite @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.manufacturerC.solution"> + + <component name="supplychain.manufacturerC"> + <implementation.composite name="supplychain.manufacturer"/> + <reference name="logging">supplychain.Logging/LoggingService</reference> + <property name="manufacturerID">manufacturerC</property> + </component> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer.solution.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer.solution.composite new file mode 100644 index 0000000000..f7bad01614 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer.solution.composite @@ -0,0 +1,66 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.retailer.solution"> + + <component name="supplychain.Retailer"> + <implementation.composite name="supplychain.retailer"/> + <reference name="warehouse">supplychain.WarehouseA/WarehouseService</reference> + <reference name="warehouse">supplychain.WarehouseB/WarehouseService</reference> + <reference name="warehouse">supplychain.WarehouseC/WarehouseService</reference> + <reference name="logging">supplychain.Logging/LoggingService</reference> + </component> + + <component name="supplychain.WarehouseA"> + <implementation.composite name="supplychain.warehouse"/> + <reference name="manufacturer">supplychain.manufacturerA/ManufacturerService</reference> + <reference name="logging">supplychain.Logging/LoggingService</reference> + <property name="warehouseID">warehouseA</property> + </component> + + <component name="supplychain.WarehouseB"> + <implementation.composite name="supplychain.warehouse"/> + <reference name="manufacturer">supplychain.manufacturerB/ManufacturerService</reference> + <reference name="logging">supplychain.Logging/LoggingService</reference> + <property name="warehouseID">warehouseB</property> + </component> + + <component name="supplychain.WarehouseC"> + <implementation.composite name="supplychain.warehouse"/> + <reference name="manufacturer">supplychain.manufacturerA/ManufacturerService</reference> + <reference name="logging">supplychain.Logging/LoggingService</reference> + <property name="warehouseID">warehouseC</property> + </component> + + <wire> + <source>supplychain.manufacturerA/callback</source> + <target>supplychain.WarehouseA/WarehouseCallbackService</target> + </wire> + <wire> + <source>supplychain.manufacturerB/callback</source> + <target>supplychain.WarehouseB/WarehouseCallbackService</target> + </wire> + <wire> + <source>supplychain.manufacturerC/callback</source> + <target>supplychain.WarehouseC/WarehouseCallbackService</target> + </wire> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/Retailer.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/Retailer.wsdl new file mode 100644 index 0000000000..39bd1963f2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/Retailer.wsdl @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions name="Retailer" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl" + xmlns:tns="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns="http://schemas.xmlsoap.org/wsdl/"> + + <wsdl:import + namespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl" + location="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl" /> + + <wsdl:service name="RetailerService"> + <wsdl:port name="RetailerPort" + binding="tns:RetailerSoapBinding"> + <soap:address + location="http://localhost:9090/axis2/services/Retailer" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/RetailerImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/RetailerImpl.componentType new file mode 100644 index 0000000000..fb381ec9a6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/RetailerImpl.componentType @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="RetailerService"> + <interface.cpp header="Retailer.h"/> + </service> + + <reference name="warehouses" multiplicity="0..n"> + <interface.cpp header="Warehouse.h"/> + </reference> + + <reference name="logging"> + <interface.cpp header="Logging.h"/> + </reference> + +</componentType> +
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/supplychain.retailer.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/supplychain.retailer.composite new file mode 100644 index 0000000000..51a2b96b1b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.retailer/supplychain.retailer.composite @@ -0,0 +1,46 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + name="supplychain.retailer"> + + <service name="RetailerService"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl#wsdl.interface(RetailerPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Retailer.wsdl#wsdl.endpoint(RetailerService/RetailerPort)"/> + <reference>RetailerProcess/RetailerService</reference> + </service> + + <component name="RetailerProcess"> + <implementation.cpp library="retailer" header="RetailerImpl.h"/> + <reference name="warehouses">warehouses</reference> + <reference name="logging">logging</reference> + </component> + + <reference name="warehouses" multiplicity="0..n"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl#wsdl.interface(WarehouseShipmentsPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl#wsdl.endpoint(WarehouseShipmentsService/WarehouseShipmentsPort)"/> + </reference> + + <reference name="logging"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.interface(LoggingFacilityLogPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.endpoint(LoggingFacilityService/LoggingFacilityPort)"/> + </reference> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/Warehouse.wsdl b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/Warehouse.wsdl new file mode 100644 index 0000000000..a007f9957b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/Warehouse.wsdl @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<wsdl:definitions name="Warehouse" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl" + xmlns:tns="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + + <wsdl:import + namespace="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl" + location="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl" /> + + <wsdl:service name="WarehouseService"> + <wsdl:port name="WarehousePort" + binding="tns:WarehouseSoapBinding"> + <soap:address + location="http://localhost:9090/axis2/services/Warehouse" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/WarehouseCallbackImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/WarehouseCallbackImpl.componentType new file mode 100644 index 0000000000..fbc1edb462 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/WarehouseCallbackImpl.componentType @@ -0,0 +1,34 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="WarehouseCallbackService"> + <interface.cpp header="WarehouseCallback.h"/> + </service> + + <reference name="logging"> + <interface.cpp header="Logging.h"/> + </reference> + + <property name="warehouseID" type="xs:string"/> + +</componentType>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/WarehouseImpl.componentType b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/WarehouseImpl.componentType new file mode 100644 index 0000000000..7f63d3b571 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/WarehouseImpl.componentType @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + + +<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <service name="WarehouseService"> + <interface.cpp header="Warehouse.h"/> + </service> + + <reference name="manufacturer"> + <interface.cpp header="Manufacturer.h"/> + </reference> + + <reference name="logging"> + <interface.cpp header="Logging.h"/> + </reference> + + <property name="warehouseID" type="xs:string"/> + +</componentType>
\ No newline at end of file diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/supplychain.warehouse.composite b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/supplychain.warehouse.composite new file mode 100644 index 0000000000..e44b964eb4 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/SupplyChain/supplychain.warehouse/supplychain.warehouse.composite @@ -0,0 +1,62 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you 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. +--> + +<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + name="supplychain.warehouse"> + + <service name="WarehouseService"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl#wsdl.interface(WarehouseShipmentsPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/Warehouse.wsdl#wsdl.endpoint(WarehouseService/WarehousePort)"/> + <reference>WarehouseProcess/WarehouseService</reference> + </service> + + <service name="WarehouseCallbackService"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.interface(WarehouseCallbackPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.endpoint(WarehouseCallbackService/WarehouseCallbackPort)"/> + <reference>WarehouseCallbackProcess/WarehouseCallbackService</reference> + </service> + + <property name="warehouseID" type="xs:string"/> + + <component name="WarehouseProcess"> + <implementation.cpp library="warehouse" header="WarehouseImpl.h"/> + <reference name="manufacturer">manufacturer</reference> + <reference name="logging">logging</reference> + <property name="warehouseID" source="$warehouseID"/> + </component> + + <component name="WarehouseCallbackProcess"> + <implementation.cpp library="warehouse" header="WarehouseCallbackImpl.h"/> + <reference name="logging">logging</reference> + <property name="warehouseID" source="$warehouseID"/> + </component> + + <reference name="manufacturer"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.interface(ManufacturerPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-10/Manufacturer.wsdl#wsdl.endpoint(ManufacturerService/ManufacturerPort)"/> + </reference> + + <reference name="logging"> + <interface.wsdl interface="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.interface(LoggingFacilityLogPortType)"/> + <binding.ws endpoint="http://www.ws-i.org/SampleApplications/SupplyChainManagement/2002-08/LoggingFacility.wsdl#wsdl.endpoint(LoggingFacilityService/LoggingFacilityPort)"/> + </reference> + +</composite> diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/autogen.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/autogen.sh new file mode 100755 index 0000000000..18277601c8 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/autogen.sh @@ -0,0 +1,31 @@ +#!/bin/bash + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +for i in "libtoolize --force" aclocal autoconf autoheader +do + echo -n "Running $i..." + $i || exit 1 + echo 'done.' +done + +echo -n 'Running automake...' +automake --add-missing +echo 'done.' +exit 0 + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/build.sh b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/build.sh new file mode 100755 index 0000000000..7a3c439e8b --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/build.sh @@ -0,0 +1,42 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + + +if [ x$TUSCANY_SCACPP = x ]; then +echo "TUSCANY_SCACPP not set" +exit; +fi +echo "Using SCA installed at $TUSCANY_SCACPP" + +if [ x$TUSCANY_SDOCPP = x ]; then +echo "TUSCANY_SDOCPP not set" +exit; +fi +echo "Using SDO installed at $TUSCANY_SDOCPP" + +if [ x$AXIS2C_HOME = x ]; then +echo "AXIS2C_HOME not set" +exit; +fi +echo "Using Axis2C installed at $AXIS2C_HOME" + +./configure --prefix=${TUSCANY_SCACPP} --enable-static=no +make +make install + diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/configure.ac b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/configure.ac new file mode 100644 index 0000000000..ad22b15181 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/configure.ac @@ -0,0 +1,150 @@ +dnl run autogen.sh to generate the configure script. + +AC_PREREQ(2.59) +AC_INIT(tuscany_sca_samples, 1.0-incubator-M2) +AC_CANONICAL_SYSTEM +AM_CONFIG_HEADER(config.h) +AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION) +AC_PREFIX_DEFAULT(/usr/local/tuscany/sca/samples) + +# Checks for programs. +AC_PROG_CXX +AC_PROG_CC +AC_PROG_CPP +AC_PROG_INSTALL +AC_PROG_LN_S +AC_PROG_MAKE_SET +AC_PROG_LIBTOOL + +# Check for dynamic library suffixes +AC_MSG_CHECKING([checking for dynamic library suffix]) +AC_CHECK_HEADER([sys/appleapiopts.h], + [AC_SUBST([libsuffix],[".dylib"]) AC_MSG_RESULT([using .dylib])], + [AC_SUBST([libsuffix],[".so"]) AC_MSG_RESULT([using .so])] +) + +# Checks for libraries. + +# Checks for header files. +AC_HEADER_DIRENT +AC_HEADER_STDC +AC_CHECK_HEADERS([inttypes.h stdlib.h string.h sys/time.h unistd.h]) + +# Checks for typedefs, structures, and compiler characteristics. +AC_HEADER_STDBOOL +AC_C_CONST +AC_C_INLINE + +# Checks for library functions. +AC_FUNC_CLOSEDIR_VOID +AC_FUNC_STAT +AC_FUNC_VPRINTF +AC_CHECK_FUNCS([getcwd putenv strdup]) + +AC_MSG_CHECKING(whether to build all samples) +AC_ARG_ENABLE(all-samples, [AS_HELP_STRING([--enable-all-samples],[build all samples [default=no]])], +[ case "${enableval}" in + no) + AC_MSG_RESULT(no) + want_all_samples=false + ;; + *) + AC_MSG_RESULT(yes) + want_all_samples=true + ;; + esac ], +[ AC_MSG_RESULT(no) + want_all_samples=false ] +) +AM_CONDITIONAL([WANT_ALL_SAMPLES], [test x$want_all_samples = xtrue]) + +AC_MSG_CHECKING(whether to build C++ samples) +AC_ARG_ENABLE(cpp, [AS_HELP_STRING([--enable-cpp],[build C++ samples [default=yes]])], +[ case "${enableval}" in + no) + AC_MSG_RESULT(no) + want_cpp_samples=false + ;; + *) + AC_MSG_RESULT(yes) + want_cpp_samples=true + ;; + esac ], +[ AC_MSG_RESULT(yes) + want_cpp_samples=true ] +) +AM_CONDITIONAL([WANT_CPP_SAMPLES], [test x$want_cpp_samples = xtrue]) + +AC_MSG_CHECKING(whether to build Python samples) +AC_ARG_ENABLE(python, [AS_HELP_STRING([--enable-python],[build Python samples [default=no]])], +[ case "${enableval}" in + no) + AC_MSG_RESULT(no) + want_python_samples=false + ;; + *) + AC_MSG_RESULT(yes) + want_python_samples=true + ;; + esac ], +[ AC_MSG_RESULT(no) + want_python_samples=false ] +) +AM_CONDITIONAL([WANT_PYTHON_SAMPLES], [test x$want_python_samples = xtrue]) + +AC_MSG_CHECKING(whether to build Ruby samples) +AC_ARG_ENABLE(ruby, [AS_HELP_STRING([--enable-ruby],[build Ruby samples [default=no]])], +[ case "${enableval}" in + no) + AC_MSG_RESULT(no) + want_ruby_samples=false + ;; + *) + AC_MSG_RESULT(yes) + want_ruby_samples=true + ;; + esac ], +[ AC_MSG_RESULT(no) + want_ruby_samples=false ] +) +AM_CONDITIONAL([WANT_RUBY_SAMPLES], [test x$want_ruby_samples = xtrue]) + +AC_MSG_CHECKING(whether to build PHP samples) +AC_ARG_ENABLE(php, [AS_HELP_STRING([--enable-php],[build PHP samples [default=no]])], +[ case "${enableval}" in + no) + AC_MSG_RESULT(no) + want_php_samples=false + ;; + *) + AC_MSG_RESULT(yes) + want_php_samples=true + ;; + esac ], +[ AC_MSG_RESULT(no) + want_php_samples=false ] +) +AM_CONDITIONAL([WANT_PHP_SAMPLES], [test x$want_php_samples = xtrue]) + +AC_CONFIG_FILES([Makefile + Calculator/Makefile + Calculator/sample.calculator/Makefile + Calculator/sample.calculator.client/Makefile + Calculator/sample.calculator.wsclient/Makefile + RubyCalculator/Makefile + RubyCalculator/sample.calculator/Makefile + RubyCalculator/sample.calculator.client/Makefile + RubyCalculator/sample.calculator.wsclient/Makefile + PythonCalculator/Makefile + PythonCalculator/sample.calculator/Makefile + PythonCalculator/sample.calculator.client/Makefile + PythonCalculator/sample.calculator.wsclient/Makefile + BigBank/Makefile + BigBank/bigbank.account/Makefile + BigBank/bigbank.client/Makefile + BigBank/bigbank.wsclient/Makefile + RubyBank/Makefile + RubyBank/bigbank.account/Makefile + RubyBank/bigbank.client/Makefile + ]) +AC_OUTPUT diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/AccountClient/AccountClient.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/AccountClient/AccountClient.dsp new file mode 100644 index 0000000000..afc73a11e9 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/AccountClient/AccountClient.dsp @@ -0,0 +1,116 @@ +# Microsoft Developer Studio Project File - Name="AccountClient" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=AccountClient - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "AccountClient.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "AccountClient.mak" CFG="AccountClient - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "AccountClient - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "AccountClient - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "AccountClient - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\..\BigBank\bigbank.account" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "NDEBUG"
+# ADD RSC /l 0x809 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /machine:I386
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /machine:I386 /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\BigBank\deployclient.bat ..\..\..\..\..\BigBank Release call ..\..\..\..\..\scagen.bat ..\..\..\..\..\BigBank\bigbank.account
+# End Special Build Tool
+
+!ELSEIF "$(CFG)" == "AccountClient - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\..\..\..\BigBank\bigbank.account" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /GZ /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "_DEBUG"
+# ADD RSC /l 0x809 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\BigBank\deployclient.bat ..\..\..\..\..\BigBank Debug call ..\..\..\..\..\scagen.bat ..\..\..\..\..\BigBank\bigbank.account
+# End Special Build Tool
+
+!ENDIF
+
+# Begin Target
+
+# Name "AccountClient - Win32 Release"
+# Name "AccountClient - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.client\AccountClient.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.client\AccountService.h
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# End Group
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/AccountClient/AccountClient.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/AccountClient/AccountClient.mak new file mode 100644 index 0000000000..0368231581 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/AccountClient/AccountClient.mak @@ -0,0 +1,214 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on AccountClient.dsp
+!IF "$(CFG)" == ""
+CFG=AccountClient - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to AccountClient - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "AccountClient - Win32 Release" && "$(CFG)" != "AccountClient - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "AccountClient.mak" CFG="AccountClient - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "AccountClient - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "AccountClient - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+!IF "$(CFG)" == "AccountClient - Win32 Release"
+
+OUTDIR=.\Release
+INTDIR=.\Release
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+ALL : "$(OUTDIR)\AccountClient.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\AccountClient.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(OUTDIR)\AccountClient.exe"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "..\..\..\..\..\BigBank\bigbank.account" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\AccountClient.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\AccountClient.pdb" /machine:I386 /out:"$(OUTDIR)\AccountClient.exe" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\AccountClient.obj"
+
+"$(OUTDIR)\AccountClient.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\AccountClient.exe"
+ call ..\..\..\..\..\BigBank\deployclient.bat ..\..\..\..\..\BigBank Release
+ call ..\..\..\..\..\scagen.bat ..\..\..\..\..\BigBank\bigbank.account
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ELSEIF "$(CFG)" == "AccountClient - Win32 Debug"
+
+OUTDIR=.\Debug
+INTDIR=.\Debug
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+ALL : "$(OUTDIR)\AccountClient.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\AccountClient.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(INTDIR)\vc60.pdb"
+ -@erase "$(OUTDIR)\AccountClient.exe"
+ -@erase "$(OUTDIR)\AccountClient.ilk"
+ -@erase "$(OUTDIR)\AccountClient.pdb"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\..\..\..\BigBank\bigbank.account" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\AccountClient.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\AccountClient.pdb" /debug /machine:I386 /out:"$(OUTDIR)\AccountClient.exe" /pdbtype:sept /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\AccountClient.obj"
+
+"$(OUTDIR)\AccountClient.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\AccountClient.exe"
+ call ..\..\..\..\..\BigBank\deployclient.bat ..\..\..\..\..\BigBank Debug
+ call ..\..\..\..\..\scagen.bat ..\..\..\..\..\BigBank\bigbank.account
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ENDIF
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("AccountClient.dep")
+!INCLUDE "AccountClient.dep"
+!ELSE
+!MESSAGE Warning: cannot find "AccountClient.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "AccountClient - Win32 Release" || "$(CFG)" == "AccountClient - Win32 Debug"
+SOURCE=..\..\..\..\..\BigBank\bigbank.client\AccountClient.cpp
+
+"$(INTDIR)\AccountClient.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Accounts/Accounts.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Accounts/Accounts.dsp new file mode 100644 index 0000000000..91b6640c91 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Accounts/Accounts.dsp @@ -0,0 +1,253 @@ +# Microsoft Developer Studio Project File - Name="Accounts" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=Accounts - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "Accounts.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Accounts.mak" CFG="Accounts - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Accounts - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "Accounts - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+MTL=midl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "Accounts - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACCOUNTS_EXPORTS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACCOUNTS_EXPORTS" /FD /c
+# SUBTRACT CPP /YX
+# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0x809 /d "NDEBUG"
+# ADD RSC /l 0x809 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 /machine:I386
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /dll /machine:I386 /out:"Release/Account.dll" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\BigBank\deploy.bat ..\..\..\..\..\BigBank Release
+# End Special Build Tool
+
+!ELSEIF "$(CFG)" == "Accounts - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACCOUNTS_EXPORTS" /YX /FD /GZ /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACCOUNTS_EXPORTS" /FD /GZ /c
+# SUBTRACT CPP /YX
+# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0x809 /d "_DEBUG"
+# ADD RSC /l 0x809 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /dll /debug /machine:I386 /out:"Debug/Account.dll" /pdbtype:sept /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\BigBank\deploy.bat ..\..\..\..\..\BigBank Debug
+# End Special Build Tool
+
+!ENDIF
+
+# Begin Target
+
+# Name "Accounts - Win32 Release"
+# Name "Accounts - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Wrapper.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_accountDataService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Wrapper.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_stockQuoteService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Wrapper.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_webService_Proxy.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataService.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Wrapper.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountService.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_accountDataService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Wrapper.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_stockQuoteService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteService.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Wrapper.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_webService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteWebService.h
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.componentType
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountService.wsdl
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.componentType
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\bigbank.account.composite
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.componentType
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteTypes.xsd
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteWebService.wsdl
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Accounts/Accounts.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Accounts/Accounts.mak new file mode 100644 index 0000000000..b173c70132 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Accounts/Accounts.mak @@ -0,0 +1,344 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on Accounts.dsp
+!IF "$(CFG)" == ""
+CFG=Accounts - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to Accounts - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "Accounts - Win32 Release" && "$(CFG)" != "Accounts - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Accounts.mak" CFG="Accounts - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Accounts - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "Accounts - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+CPP=cl.exe
+MTL=midl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "Accounts - Win32 Release"
+
+OUTDIR=.\Release
+INTDIR=.\Release
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+!IF "$(RECURSE)" == "0"
+
+ALL : "$(OUTDIR)\Account.dll"
+
+!ELSE
+
+ALL : "AccountClient - Win32 Release" "$(OUTDIR)\Account.dll"
+
+!ENDIF
+
+!IF "$(RECURSE)" == "1"
+CLEAN :"AccountClient - Win32 ReleaseCLEAN"
+!ELSE
+CLEAN :
+!ENDIF
+ -@erase "$(INTDIR)\AccountDataServiceImpl.obj"
+ -@erase "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Proxy.obj"
+ -@erase "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Wrapper.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_accountDataService_Proxy.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_AccountService_Proxy.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_AccountService_Wrapper.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_stockQuoteService_Proxy.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Proxy.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Wrapper.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl_webService_Proxy.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(OUTDIR)\Account.dll"
+ -@erase "$(OUTDIR)\Account.exp"
+ -@erase "$(OUTDIR)\Account.lib"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACCOUNTS_EXPORTS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
+MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\Accounts.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /dll /incremental:no /pdb:"$(OUTDIR)\Account.pdb" /machine:I386 /out:"$(OUTDIR)\Account.dll" /implib:"$(OUTDIR)\Account.lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\AccountDataServiceImpl.obj" \
+ "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Proxy.obj" \
+ "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Wrapper.obj" \
+ "$(INTDIR)\AccountServiceImpl.obj" \
+ "$(INTDIR)\AccountServiceImpl_accountDataService_Proxy.obj" \
+ "$(INTDIR)\AccountServiceImpl_AccountService_Proxy.obj" \
+ "$(INTDIR)\AccountServiceImpl_AccountService_Wrapper.obj" \
+ "$(INTDIR)\AccountServiceImpl_stockQuoteService_Proxy.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Proxy.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Wrapper.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl_webService_Proxy.obj"
+
+"$(OUTDIR)\Account.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "AccountClient - Win32 Release" "$(OUTDIR)\Account.dll"
+ call ..\..\..\..\..\BigBank\deploy.bat ..\..\..\..\..\BigBank Release
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ELSEIF "$(CFG)" == "Accounts - Win32 Debug"
+
+OUTDIR=.\Debug
+INTDIR=.\Debug
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+!IF "$(RECURSE)" == "0"
+
+ALL : "$(OUTDIR)\Account.dll"
+
+!ELSE
+
+ALL : "AccountClient - Win32 Debug" "$(OUTDIR)\Account.dll"
+
+!ENDIF
+
+!IF "$(RECURSE)" == "1"
+CLEAN :"AccountClient - Win32 DebugCLEAN"
+!ELSE
+CLEAN :
+!ENDIF
+ -@erase "$(INTDIR)\AccountDataServiceImpl.obj"
+ -@erase "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Proxy.obj"
+ -@erase "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Wrapper.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_accountDataService_Proxy.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_AccountService_Proxy.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_AccountService_Wrapper.obj"
+ -@erase "$(INTDIR)\AccountServiceImpl_stockQuoteService_Proxy.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Proxy.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Wrapper.obj"
+ -@erase "$(INTDIR)\StockQuoteServiceImpl_webService_Proxy.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(INTDIR)\vc60.pdb"
+ -@erase "$(OUTDIR)\Account.dll"
+ -@erase "$(OUTDIR)\Account.exp"
+ -@erase "$(OUTDIR)\Account.ilk"
+ -@erase "$(OUTDIR)\Account.lib"
+ -@erase "$(OUTDIR)\Account.pdb"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACCOUNTS_EXPORTS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
+MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\Accounts.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /dll /incremental:yes /pdb:"$(OUTDIR)\Account.pdb" /debug /machine:I386 /out:"$(OUTDIR)\Account.dll" /implib:"$(OUTDIR)\Account.lib" /pdbtype:sept /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\AccountDataServiceImpl.obj" \
+ "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Proxy.obj" \
+ "$(INTDIR)\AccountDataServiceImpl_AccountDataService_Wrapper.obj" \
+ "$(INTDIR)\AccountServiceImpl.obj" \
+ "$(INTDIR)\AccountServiceImpl_accountDataService_Proxy.obj" \
+ "$(INTDIR)\AccountServiceImpl_AccountService_Proxy.obj" \
+ "$(INTDIR)\AccountServiceImpl_AccountService_Wrapper.obj" \
+ "$(INTDIR)\AccountServiceImpl_stockQuoteService_Proxy.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Proxy.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Wrapper.obj" \
+ "$(INTDIR)\StockQuoteServiceImpl_webService_Proxy.obj"
+
+"$(OUTDIR)\Account.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "AccountClient - Win32 Debug" "$(OUTDIR)\Account.dll"
+ call ..\..\..\..\..\BigBank\deploy.bat ..\..\..\..\..\BigBank Debug
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ENDIF
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("Accounts.dep")
+!INCLUDE "Accounts.dep"
+!ELSE
+!MESSAGE Warning: cannot find "Accounts.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "Accounts - Win32 Release" || "$(CFG)" == "Accounts - Win32 Debug"
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.cpp
+
+"$(INTDIR)\AccountDataServiceImpl.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Proxy.cpp
+
+"$(INTDIR)\AccountDataServiceImpl_AccountDataService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Wrapper.cpp
+
+"$(INTDIR)\AccountDataServiceImpl_AccountDataService_Wrapper.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.cpp
+
+"$(INTDIR)\AccountServiceImpl.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_accountDataService_Proxy.cpp
+
+"$(INTDIR)\AccountServiceImpl_accountDataService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Proxy.cpp
+
+"$(INTDIR)\AccountServiceImpl_AccountService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Wrapper.cpp
+
+"$(INTDIR)\AccountServiceImpl_AccountService_Wrapper.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_stockQuoteService_Proxy.cpp
+
+"$(INTDIR)\AccountServiceImpl_stockQuoteService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.cpp
+
+"$(INTDIR)\StockQuoteServiceImpl.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Proxy.cpp
+
+"$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Wrapper.cpp
+
+"$(INTDIR)\StockQuoteServiceImpl_StockQuoteService_Wrapper.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_webService_Proxy.cpp
+
+"$(INTDIR)\StockQuoteServiceImpl_webService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+!IF "$(CFG)" == "Accounts - Win32 Release"
+
+"AccountClient - Win32 Release" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Release"
+ cd "..\Accounts"
+
+"AccountClient - Win32 ReleaseCLEAN" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Accounts"
+
+!ELSEIF "$(CFG)" == "Accounts - Win32 Debug"
+
+"AccountClient - Win32 Debug" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Debug"
+ cd "..\Accounts"
+
+"AccountClient - Win32 DebugCLEAN" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Accounts"
+
+!ENDIF
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.dsw b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.dsw new file mode 100644 index 0000000000..5771d655c1 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.dsw @@ -0,0 +1,77 @@ +Microsoft Developer Studio Workspace File, Format Version 6.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "AccountClient"=.\AccountClient\AccountClient.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Project: "Accounts"=.\Accounts\Accounts.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name AccountClient
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "Build"=.\Build\Build.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name Accounts
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name AccountClient
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name WSAccountClient
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "WSAccountClient"=.\WSAccountClient\WSAccountClient.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+}}}
+
+###############################################################################
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.ncb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.ncb Binary files differnew file mode 100644 index 0000000000..df956231ae --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.ncb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.opt b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.opt Binary files differnew file mode 100644 index 0000000000..bbe2b7f841 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/BigBank.opt diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/Build.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/Build.dsp new file mode 100644 index 0000000000..e24bca445c --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/Build.dsp @@ -0,0 +1,67 @@ +# Microsoft Developer Studio Project File - Name="Build" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Generic Project" 0x010a
+
+CFG=Build - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "Build.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Build.mak" CFG="Build - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Build - Win32 Release" (based on "Win32 (x86) Generic Project")
+!MESSAGE "Build - Win32 Debug" (based on "Win32 (x86) Generic Project")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+MTL=midl.exe
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Target_Dir ""
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Target_Dir ""
+
+!ENDIF
+
+# Begin Target
+
+# Name "Build - Win32 Release"
+# Name "Build - Win32 Debug"
+# Begin Source File
+
+SOURCE=.\BuildInstructions.txt
+# End Source File
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/Build.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/Build.mak new file mode 100644 index 0000000000..452df03c2d --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/Build.mak @@ -0,0 +1,152 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on Build.dsp
+!IF "$(CFG)" == ""
+CFG=Build - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to Build - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "Build - Win32 Release" && "$(CFG)" != "Build - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Build.mak" CFG="Build - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Build - Win32 Release" (based on "Win32 (x86) Generic Project")
+!MESSAGE "Build - Win32 Debug" (based on "Win32 (x86) Generic Project")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+OUTDIR=.\Release
+INTDIR=.\Release
+
+!IF "$(RECURSE)" == "0"
+
+ALL :
+
+!ELSE
+
+ALL : "WSAccountClient - Win32 Release" "AccountClient - Win32 Release" "Accounts - Win32 Release"
+
+!ENDIF
+
+!IF "$(RECURSE)" == "1"
+CLEAN :"Accounts - Win32 ReleaseCLEAN" "AccountClient - Win32 ReleaseCLEAN" "WSAccountClient - Win32 ReleaseCLEAN"
+!ELSE
+CLEAN :
+!ENDIF
+ -@erase
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+MTL=midl.exe
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+!ENDIF
+
+MTL_PROJ=
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("Build.dep")
+!INCLUDE "Build.dep"
+!ELSE
+!MESSAGE Warning: cannot find "Build.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "Build - Win32 Release" || "$(CFG)" == "Build - Win32 Debug"
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+"Accounts - Win32 Release" :
+ cd "..\Accounts"
+ $(MAKE) /$(MAKEFLAGS) /F .\Accounts.mak CFG="Accounts - Win32 Release"
+ cd "..\Build"
+
+"Accounts - Win32 ReleaseCLEAN" :
+ cd "..\Accounts"
+ $(MAKE) /$(MAKEFLAGS) /F .\Accounts.mak CFG="Accounts - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+"Accounts - Win32 Debug" :
+ cd "..\Accounts"
+ $(MAKE) /$(MAKEFLAGS) /F .\Accounts.mak CFG="Accounts - Win32 Debug"
+ cd "..\Build"
+
+"Accounts - Win32 DebugCLEAN" :
+ cd "..\Accounts"
+ $(MAKE) /$(MAKEFLAGS) /F .\Accounts.mak CFG="Accounts - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ENDIF
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+"AccountClient - Win32 Release" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Release"
+ cd "..\Build"
+
+"AccountClient - Win32 ReleaseCLEAN" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+"AccountClient - Win32 Debug" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Debug"
+ cd "..\Build"
+
+"AccountClient - Win32 DebugCLEAN" :
+ cd "..\AccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\AccountClient.mak CFG="AccountClient - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ENDIF
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+"WSAccountClient - Win32 Release" :
+ cd "..\WSAccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSAccountClient.mak CFG="WSAccountClient - Win32 Release"
+ cd "..\Build"
+
+"WSAccountClient - Win32 ReleaseCLEAN" :
+ cd "..\WSAccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSAccountClient.mak CFG="WSAccountClient - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+"WSAccountClient - Win32 Debug" :
+ cd "..\WSAccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSAccountClient.mak CFG="WSAccountClient - Win32 Debug"
+ cd "..\Build"
+
+"WSAccountClient - Win32 DebugCLEAN" :
+ cd "..\WSAccountClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSAccountClient.mak CFG="WSAccountClient - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ENDIF
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/BuildInstructions.txt b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/BuildInstructions.txt new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/Build/BuildInstructions.txt diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/WSAccountClient/WSAccountClient.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/WSAccountClient/WSAccountClient.dsp new file mode 100644 index 0000000000..1c240d56d4 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/WSAccountClient/WSAccountClient.dsp @@ -0,0 +1,120 @@ +# Microsoft Developer Studio Project File - Name="WSAccountClient" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=WSAccountClient - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "WSAccountClient.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "WSAccountClient.mak" CFG="WSAccountClient - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "WSAccountClient - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "WSAccountClient - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "WSAccountClient - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "$(AXIS2C_HOME)\include" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "NDEBUG"
+# ADD RSC /l 0x809 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /machine:I386
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /machine:I386 /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(AXIS2C_HOME)/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\BigBank\deploywsclient.bat ..\..\..\..\..\BigBank Release
+# End Special Build Tool
+
+!ELSEIF "$(CFG)" == "WSAccountClient - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "$(AXIS2C_HOME)\include" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /GZ /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "_DEBUG"
+# ADD RSC /l 0x809 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(AXIS2C_HOME)/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\BigBank\deploywsclient.bat ..\..\..\..\..\BigBank Debug
+# End Special Build Tool
+
+!ENDIF
+
+# Begin Target
+
+# Name "WSAccountClient - Win32 Release"
+# Name "WSAccountClient - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.wsclient\AccountWSClient.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.wsclient\axis2_Account_stub.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.wsclient\axis2_Account_stub.h
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# End Group
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/WSAccountClient/WSAccountClient.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/WSAccountClient/WSAccountClient.mak new file mode 100644 index 0000000000..9f6881a584 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/WSAccountClient/WSAccountClient.mak @@ -0,0 +1,189 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on WSAccountClient.dsp
+!IF "$(CFG)" == ""
+CFG=WSAccountClient - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to WSAccountClient - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "WSAccountClient - Win32 Release" && "$(CFG)" != "WSAccountClient - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "WSAccountClient.mak" CFG="WSAccountClient - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "WSAccountClient - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "WSAccountClient - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "WSAccountClient - Win32 Release"
+
+OUTDIR=.\Release
+INTDIR=.\Release
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+ALL : "$(OUTDIR)\WSAccountClient.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\AccountWSClient.obj"
+ -@erase "$(INTDIR)\axis2_Account_stub.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(OUTDIR)\WSAccountClient.exe"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "$(AXIS2C_HOME)\include" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\WSAccountClient.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\WSAccountClient.pdb" /machine:I386 /out:"$(OUTDIR)\WSAccountClient.exe" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(AXIS2C_HOME)/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\AccountWSClient.obj" \
+ "$(INTDIR)\axis2_Account_stub.obj"
+
+"$(OUTDIR)\WSAccountClient.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\WSAccountClient.exe"
+ call ..\..\..\..\..\BigBank\deploywsclient.bat ..\..\..\..\..\BigBank Release
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ELSEIF "$(CFG)" == "WSAccountClient - Win32 Debug"
+
+OUTDIR=.\Debug
+INTDIR=.\Debug
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+ALL : "$(OUTDIR)\WSAccountClient.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\AccountWSClient.obj"
+ -@erase "$(INTDIR)\axis2_Account_stub.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(INTDIR)\vc60.pdb"
+ -@erase "$(OUTDIR)\WSAccountClient.exe"
+ -@erase "$(OUTDIR)\WSAccountClient.ilk"
+ -@erase "$(OUTDIR)\WSAccountClient.pdb"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "$(AXIS2C_HOME)\include" /I "$(TUSCANY_SCACPP)\include" /I "$(TUSCANY_SCACPP)\extensions\cpp\include" /I "$(TUSCANY_SDOCPP)\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\WSAccountClient.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\WSAccountClient.pdb" /debug /machine:I386 /out:"$(OUTDIR)\WSAccountClient.exe" /pdbtype:sept /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(AXIS2C_HOME)/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\AccountWSClient.obj" \
+ "$(INTDIR)\axis2_Account_stub.obj"
+
+"$(OUTDIR)\WSAccountClient.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\WSAccountClient.exe"
+ call ..\..\..\..\..\BigBank\deploywsclient.bat ..\..\..\..\..\BigBank Debug
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ENDIF
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("WSAccountClient.dep")
+!INCLUDE "WSAccountClient.dep"
+!ELSE
+!MESSAGE Warning: cannot find "WSAccountClient.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "WSAccountClient - Win32 Release" || "$(CFG)" == "WSAccountClient - Win32 Debug"
+SOURCE=..\..\..\..\..\BigBank\bigbank.wsclient\AccountWSClient.cpp
+
+"$(INTDIR)\AccountWSClient.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\BigBank\bigbank.wsclient\axis2_Account_stub.cpp
+
+"$(INTDIR)\axis2_Account_stub.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/build.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/build.cmd new file mode 100644 index 0000000000..0cf0ac8e3e --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/BigBank/build.cmd @@ -0,0 +1,24 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal +call vcvars32 +cd Build +nmake -f Build.mak CFG="Build - Win32 Release" +cd .. +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/Build.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/Build.dsp new file mode 100644 index 0000000000..e24bca445c --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/Build.dsp @@ -0,0 +1,67 @@ +# Microsoft Developer Studio Project File - Name="Build" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Generic Project" 0x010a
+
+CFG=Build - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "Build.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Build.mak" CFG="Build - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Build - Win32 Release" (based on "Win32 (x86) Generic Project")
+!MESSAGE "Build - Win32 Debug" (based on "Win32 (x86) Generic Project")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+MTL=midl.exe
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Target_Dir ""
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Target_Dir ""
+
+!ENDIF
+
+# Begin Target
+
+# Name "Build - Win32 Release"
+# Name "Build - Win32 Debug"
+# Begin Source File
+
+SOURCE=.\BuildInstructions.txt
+# End Source File
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/Build.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/Build.mak new file mode 100644 index 0000000000..1c01e71a39 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/Build.mak @@ -0,0 +1,155 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on Build.dsp
+!IF "$(CFG)" == ""
+CFG=Build - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to Build - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "Build - Win32 Release" && "$(CFG)" != "Build - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Build.mak" CFG="Build - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Build - Win32 Release" (based on "Win32 (x86) Generic Project")
+!MESSAGE "Build - Win32 Debug" (based on "Win32 (x86) Generic Project")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+OUTDIR=.\Release
+INTDIR=.\Release
+
+!IF "$(RECURSE)" == "0"
+
+ALL :
+
+!ELSE
+
+ALL : "WSClient - Win32 Release" "Client - Win32 Release" "Calculator - Win32 Release"
+
+!ENDIF
+
+!IF "$(RECURSE)" == "1"
+CLEAN :"Calculator - Win32 ReleaseCLEAN" "Client - Win32 ReleaseCLEAN" "WSClient - Win32 ReleaseCLEAN"
+!ELSE
+CLEAN :
+!ENDIF
+ -@erase
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+MTL=midl.exe
+MTL_PROJ=
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+MTL=midl.exe
+MTL_PROJ=
+
+!ENDIF
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("Build.dep")
+!INCLUDE "Build.dep"
+!ELSE
+!MESSAGE Warning: cannot find "Build.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "Build - Win32 Release" || "$(CFG)" == "Build - Win32 Debug"
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+"Calculator - Win32 Release" :
+ cd "..\Calculator"
+ $(MAKE) /$(MAKEFLAGS) /F .\Calculator.mak CFG="Calculator - Win32 Release"
+ cd "..\Build"
+
+"Calculator - Win32 ReleaseCLEAN" :
+ cd "..\Calculator"
+ $(MAKE) /$(MAKEFLAGS) /F .\Calculator.mak CFG="Calculator - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+"Calculator - Win32 Debug" :
+ cd "..\Calculator"
+ $(MAKE) /$(MAKEFLAGS) /F .\Calculator.mak CFG="Calculator - Win32 Debug"
+ cd "..\Build"
+
+"Calculator - Win32 DebugCLEAN" :
+ cd "..\Calculator"
+ $(MAKE) /$(MAKEFLAGS) /F .\Calculator.mak CFG="Calculator - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ENDIF
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+"Client - Win32 Release" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Release"
+ cd "..\Build"
+
+"Client - Win32 ReleaseCLEAN" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+"Client - Win32 Debug" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Debug"
+ cd "..\Build"
+
+"Client - Win32 DebugCLEAN" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ENDIF
+
+!IF "$(CFG)" == "Build - Win32 Release"
+
+"WSClient - Win32 Release" :
+ cd "..\WSClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSClient.mak CFG="WSClient - Win32 Release"
+ cd "..\Build"
+
+"WSClient - Win32 ReleaseCLEAN" :
+ cd "..\WSClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSClient.mak CFG="WSClient - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ELSEIF "$(CFG)" == "Build - Win32 Debug"
+
+"WSClient - Win32 Debug" :
+ cd "..\WSClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSClient.mak CFG="WSClient - Win32 Debug"
+ cd "..\Build"
+
+"WSClient - Win32 DebugCLEAN" :
+ cd "..\WSClient"
+ $(MAKE) /$(MAKEFLAGS) /F .\WSClient.mak CFG="WSClient - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Build"
+
+!ENDIF
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/BuildInstructions.txt b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/BuildInstructions.txt new file mode 100644 index 0000000000..275b01e3e2 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Build/BuildInstructions.txt @@ -0,0 +1,93 @@ + +These sample projects will build: + +A basic calculator SCA service. +A client to test that service. +A WSClient to test the service as exposed by AXIS2C as a web service. + +The sample depdends on the current versions of Tuscany SDO and Tuscany SCA, which in turn +depend on axis2c version 0.92, and libxml2. See the SCA and SDO project installation +details. + +The sample already has the pre-generated proxy and wrapper code in it, but should +you need to regenerate these, you will need the command line tool "scagen" which is +part of the Tuscany SCA project. + +The projects expect to following environment variables to be set: +TUSCANY_SCACPP: +The directory in which the sca runtime is deployed - probably something ending in sca/deploy. + +TUSCANY_SDOCPP: +The directory where the sdo runtime is deployed - probably something ending in sdo/deploy. + +TUSCANY_SCACPP_DEFAULT_COMPONENT=CalculatorSubsystem +This is the default composite to be loaded by SCA. It consists of <subsystem>/<component> + +TUSCANY_SCACPP_SYSTEM_ROOT +This is the point from which SCA will start looking for composites to load. Again this is +set programmatically by the sample. + +AXIS2C_HOME: +This is where axis2c is deployed- this is only required by the WSClient project. + +The Calculator project contains a simple calculator service, and the descriptive files +which help the runtime to find the service. + + +Rebuilding the proxy and wrapper classes +======================================== + +If required, go to the Calculator sample main directory, and +type: +"scagen -dir CalculatorComposite -output CalculatorComposite" + +The generated code is put into the CalculatorComposite subdirectory. + +Building the Client project +=========================== + +Set the active project to be "Client", and then build all. +This will re-build Calculator, then rebuild the Client, +The final step of the build will call a batch file "deploy.cmd", +which copies all the required files to the directory samples/Calculator/deploy + +Use Project..Settings..Debug and check the path to the executable, check also the +path to the working directory. Alter these to match your configuration. + +Run the project, and your SCA service should be called. + +Building the WSClient project +============================= + +Modify the services.xml file, and make the SCA system root defined +within it comply with your SCA system root. + +Set the active project to WSClient and build all. + +The last step of the build will run a wsdeploy script, which +tries to use the environment variable AXIS2C_HOME, to create +a services/Calculator directory, and deploy the services.xml file. +The dll which resolves SCA services is called +tuscany_sca_ws_service.dll - this will be copied to the axis +tree by the same script file. + +To run the axis2 http server, go to the %AXIS2C_HOME%/bin +directory, and launch the executable. + +Now verify that the path to the WSClient executable makes sense +in your project settings, and run the project. + + +Note +==== + +It can be quite hard to debug services which are invoked through axis, as the +dll including the service is loaded on call. One useful technique is to +load the axis http server in visual studio (create an empty project and make +the executable path point to axis2_http_server.exe). +Now use the Project..Settings..Debug..Addition DLLs option and add +services/Calculator/tuscany_sca_ws_service.dll. +You will now be able to set breakpoints in the dll (Axis2EntryPointService_invoke +is a good place - in Axis2EntryPointService_skeleton.cpp). +Run your WSclient from another debugger, and the server debugger will break +on the service code. diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.dsw b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.dsw new file mode 100644 index 0000000000..05f9141d98 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.dsw @@ -0,0 +1,77 @@ +Microsoft Developer Studio Workspace File, Format Version 6.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "Build"=.\Build\Build.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name Calculator
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name Client
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name WSClient
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "Calculator"=.\Calculator\Calculator.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name Client
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "Client"=.\Client\Client.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Project: "WSClient"=.\WSClient\WSClient.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+}}}
+
+###############################################################################
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.ncb b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.ncb Binary files differnew file mode 100644 index 0000000000..4b6b26f308 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.ncb diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.opt b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.opt Binary files differnew file mode 100644 index 0000000000..2dbad4c658 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator.opt diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator/Calculator.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator/Calculator.dsp new file mode 100644 index 0000000000..2dbc91fcf0 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator/Calculator.dsp @@ -0,0 +1,197 @@ +# Microsoft Developer Studio Project File - Name="Calculator" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=Calculator - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "Calculator.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Calculator.mak" CFG="Calculator - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Calculator - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "Calculator - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+MTL=midl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "Calculator - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CALCULATOR_EXPORTS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CALCULATOR_EXPORTS" /FD /c
+# SUBTRACT CPP /YX
+# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0x809 /d "NDEBUG"
+# ADD RSC /l 0x809 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 /machine:I386
+# ADD 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 tuscany_sca_cpp.lib tuscany_sca.lib tuscany_sdo.lib /nologo /dll /machine:I386 /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\Calculator\deploy.bat ..\..\..\..\..\Calculator Release
+# End Special Build Tool
+
+!ELSEIF "$(CFG)" == "Calculator - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CALCULATOR_EXPORTS" /YX /FD /GZ /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CALCULATOR_EXPORTS" /FD /GZ /c
+# SUBTRACT CPP /YX
+# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0x809 /d "_DEBUG"
+# ADD RSC /l 0x809 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sca_cpp.lib tuscany_sca.lib tuscany_sdo.lib /nologo /dll /debug /machine:I386 /pdbtype:sept /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\Calculator\deploy.bat ..\..\..\..\..\Calculator Debug
+# End Special Build Tool
+
+!ENDIF
+
+# Begin Target
+
+# Name "Calculator - Win32 Release"
+# Name "Calculator - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Wrapper.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_divideService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Proxy.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Wrapper.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\Calculator.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Wrapper.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_divideService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\Divide.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Proxy.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Wrapper.h
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\CalculatorComposite\Calculator.wsdl
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\CalculatorComposite\sca.composite
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\CalculatorSubsystem\sca.subsystem
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\CalculatorComposite\services.xml
+# End Source File
+# Begin Source File
+
+SOURCE="..\..\..\..\..\Calculator\CalculatorComposite\Tuscany-model.config"
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator/Calculator.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator/Calculator.mak new file mode 100644 index 0000000000..c0ecc9fecf --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Calculator/Calculator.mak @@ -0,0 +1,328 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on Calculator.dsp
+!IF "$(CFG)" == ""
+CFG=Calculator - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to Calculator - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "Calculator - Win32 Release" && "$(CFG)" != "Calculator - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Calculator.mak" CFG="Calculator - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Calculator - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "Calculator - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+!IF "$(CFG)" == "Calculator - Win32 Release"
+
+OUTDIR=.\Release
+INTDIR=.\Release
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+!IF "$(RECURSE)" == "0"
+
+ALL : "$(OUTDIR)\Calculator.dll"
+
+!ELSE
+
+ALL : "Client - Win32 Release" "$(OUTDIR)\Calculator.dll"
+
+!ENDIF
+
+!IF "$(RECURSE)" == "1"
+CLEAN :"Client - Win32 ReleaseCLEAN"
+!ELSE
+CLEAN :
+!ENDIF
+ -@erase "$(INTDIR)\CalculatorImpl.obj"
+ -@erase "$(INTDIR)\CalculatorImpl_CalculatorService_Proxy.obj"
+ -@erase "$(INTDIR)\CalculatorImpl_CalculatorService_Wrapper.obj"
+ -@erase "$(INTDIR)\CalculatorImpl_divideService_Proxy.obj"
+ -@erase "$(INTDIR)\DivideImpl.obj"
+ -@erase "$(INTDIR)\DivideImpl_DivideService_Proxy.obj"
+ -@erase "$(INTDIR)\DivideImpl_DivideService_Wrapper.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(OUTDIR)\Calculator.dll"
+ -@erase "$(OUTDIR)\Calculator.exp"
+ -@erase "$(OUTDIR)\Calculator.lib"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CALCULATOR_EXPORTS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+MTL=midl.exe
+MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\Calculator.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sca_cpp.lib tuscany_sca.lib tuscany_sdo.lib /nologo /dll /incremental:no /pdb:"$(OUTDIR)\Calculator.pdb" /machine:I386 /out:"$(OUTDIR)\Calculator.dll" /implib:"$(OUTDIR)\Calculator.lib" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\CalculatorImpl.obj" \
+ "$(INTDIR)\CalculatorImpl_CalculatorService_Proxy.obj" \
+ "$(INTDIR)\CalculatorImpl_CalculatorService_Wrapper.obj" \
+ "$(INTDIR)\CalculatorImpl_divideService_Proxy.obj" \
+ "$(INTDIR)\DivideImpl.obj" \
+ "$(INTDIR)\DivideImpl_DivideService_Proxy.obj" \
+ "$(INTDIR)\DivideImpl_DivideService_Wrapper.obj"
+
+"$(OUTDIR)\Calculator.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "Client - Win32 Release" "$(OUTDIR)\Calculator.dll"
+ call ..\..\..\..\..\Calculator\deploy.bat ..\..\..\..\..\Calculator Release
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ELSEIF "$(CFG)" == "Calculator - Win32 Debug"
+
+OUTDIR=.\Debug
+INTDIR=.\Debug
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+!IF "$(RECURSE)" == "0"
+
+ALL : "$(OUTDIR)\Calculator.dll"
+
+!ELSE
+
+ALL : "Client - Win32 Debug" "$(OUTDIR)\Calculator.dll"
+
+!ENDIF
+
+!IF "$(RECURSE)" == "1"
+CLEAN :"Client - Win32 DebugCLEAN"
+!ELSE
+CLEAN :
+!ENDIF
+ -@erase "$(INTDIR)\CalculatorImpl.obj"
+ -@erase "$(INTDIR)\CalculatorImpl_CalculatorService_Proxy.obj"
+ -@erase "$(INTDIR)\CalculatorImpl_CalculatorService_Wrapper.obj"
+ -@erase "$(INTDIR)\CalculatorImpl_divideService_Proxy.obj"
+ -@erase "$(INTDIR)\DivideImpl.obj"
+ -@erase "$(INTDIR)\DivideImpl_DivideService_Proxy.obj"
+ -@erase "$(INTDIR)\DivideImpl_DivideService_Wrapper.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(INTDIR)\vc60.pdb"
+ -@erase "$(OUTDIR)\Calculator.dll"
+ -@erase "$(OUTDIR)\Calculator.exp"
+ -@erase "$(OUTDIR)\Calculator.ilk"
+ -@erase "$(OUTDIR)\Calculator.lib"
+ -@erase "$(OUTDIR)\Calculator.pdb"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CALCULATOR_EXPORTS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+MTL=midl.exe
+MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\Calculator.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sca_cpp.lib tuscany_sca.lib tuscany_sdo.lib /nologo /dll /incremental:yes /pdb:"$(OUTDIR)\Calculator.pdb" /debug /machine:I386 /out:"$(OUTDIR)\Calculator.dll" /implib:"$(OUTDIR)\Calculator.lib" /pdbtype:sept /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\CalculatorImpl.obj" \
+ "$(INTDIR)\CalculatorImpl_CalculatorService_Proxy.obj" \
+ "$(INTDIR)\CalculatorImpl_CalculatorService_Wrapper.obj" \
+ "$(INTDIR)\CalculatorImpl_divideService_Proxy.obj" \
+ "$(INTDIR)\DivideImpl.obj" \
+ "$(INTDIR)\DivideImpl_DivideService_Proxy.obj" \
+ "$(INTDIR)\DivideImpl_DivideService_Wrapper.obj"
+
+"$(OUTDIR)\Calculator.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "Client - Win32 Debug" "$(OUTDIR)\Calculator.dll"
+ call ..\..\..\..\..\Calculator\deploy.bat ..\..\..\..\..\Calculator Debug
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ENDIF
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("Calculator.dep")
+!INCLUDE "Calculator.dep"
+!ELSE
+!MESSAGE Warning: cannot find "Calculator.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "Calculator - Win32 Release" || "$(CFG)" == "Calculator - Win32 Debug"
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl.cpp
+
+"$(INTDIR)\CalculatorImpl.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Proxy.cpp
+
+"$(INTDIR)\CalculatorImpl_CalculatorService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Wrapper.cpp
+
+"$(INTDIR)\CalculatorImpl_CalculatorService_Wrapper.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_divideService_Proxy.cpp
+
+"$(INTDIR)\CalculatorImpl_divideService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl.cpp
+
+"$(INTDIR)\DivideImpl.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Proxy.cpp
+
+"$(INTDIR)\DivideImpl_DivideService_Proxy.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Wrapper.cpp
+
+"$(INTDIR)\DivideImpl_DivideService_Wrapper.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+!IF "$(CFG)" == "Calculator - Win32 Release"
+
+"Client - Win32 Release" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Release"
+ cd "..\Calculator"
+
+"Client - Win32 ReleaseCLEAN" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Release" RECURSE=1 CLEAN
+ cd "..\Calculator"
+
+!ELSEIF "$(CFG)" == "Calculator - Win32 Debug"
+
+"Client - Win32 Debug" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Debug"
+ cd "..\Calculator"
+
+"Client - Win32 DebugCLEAN" :
+ cd "..\Client"
+ $(MAKE) /$(MAKEFLAGS) /F .\Client.mak CFG="Client - Win32 Debug" RECURSE=1 CLEAN
+ cd "..\Calculator"
+
+!ENDIF
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Client/Client.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Client/Client.dsp new file mode 100644 index 0000000000..2efa614a43 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Client/Client.dsp @@ -0,0 +1,113 @@ +# Microsoft Developer Studio Project File - Name="Client" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=Client - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "Client.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Client.mak" CFG="Client - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Client - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "Client - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "Client - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\..\Calculator\sample.calculator" /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "NDEBUG"
+# ADD RSC /l 0x809 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /machine:I386
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /machine:I386 /out:"Release/calculator_client.exe" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\Calculator\deployclient.bat ..\..\..\..\..\Calculator Release call ..\..\..\..\..\scagen.bat ..\..\..\..\..\Calculator\sample.calculator
+# End Special Build Tool
+
+!ELSEIF "$(CFG)" == "Client - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\..\..\..\Calculator\sample.calculator" /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /GZ /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "_DEBUG"
+# ADD RSC /l 0x809 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD 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 tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /debug /machine:I386 /out:"Debug/calculator_client.exe" /pdbtype:sept /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+# SUBTRACT LINK32 /pdb:none
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\Calculator\deployclient.bat ..\..\..\..\..\Calculator Debug call ..\..\..\..\..\scagen.bat ..\..\..\..\..\Calculator\sample.calculator
+# End Special Build Tool
+
+!ENDIF
+
+# Begin Target
+
+# Name "Client - Win32 Release"
+# Name "Client - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.client\CalculatorClient.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# End Group
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Client/Client.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Client/Client.mak new file mode 100644 index 0000000000..cef2af3f3f --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/Client/Client.mak @@ -0,0 +1,214 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on Client.dsp
+!IF "$(CFG)" == ""
+CFG=Client - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to Client - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "Client - Win32 Release" && "$(CFG)" != "Client - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "Client.mak" CFG="Client - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Client - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "Client - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+!IF "$(CFG)" == "Client - Win32 Release"
+
+OUTDIR=.\Release
+INTDIR=.\Release
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+ALL : "$(OUTDIR)\calculator_client.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\CalculatorClient.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(OUTDIR)\calculator_client.exe"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "..\..\..\..\..\Calculator\sample.calculator" /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\Client.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\calculator_client.pdb" /machine:I386 /out:"$(OUTDIR)\calculator_client.exe" /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\CalculatorClient.obj"
+
+"$(OUTDIR)\calculator_client.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\calculator_client.exe"
+ call ..\..\..\..\..\Calculator\deployclient.bat ..\..\..\..\..\Calculator Release
+ call ..\..\..\..\..\scagen.bat ..\..\..\..\..\Calculator\sample.calculator
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ELSEIF "$(CFG)" == "Client - Win32 Debug"
+
+OUTDIR=.\Debug
+INTDIR=.\Debug
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+ALL : "$(OUTDIR)\calculator_client.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\CalculatorClient.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(INTDIR)\vc60.pdb"
+ -@erase "$(OUTDIR)\calculator_client.exe"
+ -@erase "$(OUTDIR)\calculator_client.ilk"
+ -@erase "$(OUTDIR)\calculator_client.pdb"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\..\..\..\Calculator\sample.calculator" /I "$(TUSCANY_SDOCPP)/include" /I "$(TUSCANY_SCACPP)/include" /I "$(TUSCANY_SCACPP)/extensions/cpp/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\Client.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\calculator_client.pdb" /debug /machine:I386 /out:"$(OUTDIR)\calculator_client.exe" /pdbtype:sept /libpath:"$(TUSCANY_SDOCPP)/lib" /libpath:"$(TUSCANY_SCACPP)/lib" /libpath:"$(TUSCANY_SCACPP)/extensions/cpp/lib"
+LINK32_OBJS= \
+ "$(INTDIR)\CalculatorClient.obj"
+
+"$(OUTDIR)\calculator_client.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\calculator_client.exe"
+ call ..\..\..\..\..\Calculator\deployclient.bat ..\..\..\..\..\Calculator Debug
+ call ..\..\..\..\..\scagen.bat ..\..\..\..\..\Calculator\sample.calculator
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ENDIF
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("Client.dep")
+!INCLUDE "Client.dep"
+!ELSE
+!MESSAGE Warning: cannot find "Client.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "Client - Win32 Release" || "$(CFG)" == "Client - Win32 Debug"
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.client\CalculatorClient.cpp
+
+"$(INTDIR)\CalculatorClient.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/WSClient/WSClient.dsp b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/WSClient/WSClient.dsp new file mode 100644 index 0000000000..0c5c7f825e --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/WSClient/WSClient.dsp @@ -0,0 +1,120 @@ +# Microsoft Developer Studio Project File - Name="WSClient" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=WSClient - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "WSClient.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "WSClient.mak" CFG="WSClient - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "WSClient - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "WSClient - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "WSClient - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /W3 /GX /O2 /I "$(TUSCANY_SDOCPP)/include" /I "$(AXIS2C_HOME)/include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "NDEBUG"
+# ADD RSC /l 0x809 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /machine:I386
+# ADD 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 tuscany_sdo.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /machine:I386 /out:"Release/calculator_wsclient.exe" /libpath:"$(TUSCANY_SDOCPP)\lib" /libpath:"$(AXIS2C_HOME)\lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\Calculator\deploywsclient.bat ..\..\..\..\..\Calculator Release
+# End Special Build Tool
+
+!ELSEIF "$(CFG)" == "WSClient - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
+# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "$(TUSCANY_SDOCPP)/include" /I "$(AXIS2C_HOME)/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /GZ /c
+# SUBTRACT CPP /YX
+# ADD BASE RSC /l 0x809 /d "_DEBUG"
+# ADD RSC /l 0x809 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# 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 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 /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD 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 tuscany_sdo.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /debug /machine:I386 /out:"Debug/calculator_wsclient.exe" /pdbtype:sept /libpath:"$(TUSCANY_SDOCPP)\lib" /libpath:"$(AXIS2C_HOME)\lib"
+# Begin Special Build Tool
+SOURCE="$(InputPath)"
+PostBuild_Cmds=call ..\..\..\..\..\Calculator\deploywsclient.bat ..\..\..\..\..\Calculator Debug
+# End Special Build Tool
+
+!ENDIF
+
+# Begin Target
+
+# Name "WSClient - Win32 Release"
+# Name "WSClient - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.wsclient\axis2_Calculator_stub.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.wsclient\CalculatorWSClient.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.wsclient\axis2_Calculator_stub.h
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# End Group
+# End Target
+# End Project
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/WSClient/WSClient.mak b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/WSClient/WSClient.mak new file mode 100644 index 0000000000..366db95229 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/WSClient/WSClient.mak @@ -0,0 +1,222 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on WSClient.dsp
+!IF "$(CFG)" == ""
+CFG=WSClient - Win32 Debug
+!MESSAGE No configuration specified. Defaulting to WSClient - Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "WSClient - Win32 Release" && "$(CFG)" != "WSClient - Win32 Debug"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "WSClient.mak" CFG="WSClient - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "WSClient - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "WSClient - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+!IF "$(OS)" == "Windows_NT"
+NULL=
+!ELSE
+NULL=nul
+!ENDIF
+
+!IF "$(CFG)" == "WSClient - Win32 Release"
+
+OUTDIR=.\Release
+INTDIR=.\Release
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+ALL : "$(OUTDIR)\calculator_wsclient.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\axis2_Calculator_stub.obj"
+ -@erase "$(INTDIR)\CalculatorWSClient.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(OUTDIR)\calculator_wsclient.exe"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /ML /W3 /GX /O2 /I "$(TUSCANY_SDOCPP)/include" /I "$(AXIS2C_HOME)/include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\WSClient.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\calculator_wsclient.pdb" /machine:I386 /out:"$(OUTDIR)\calculator_wsclient.exe" /libpath:"$(TUSCANY_SDOCPP)\lib" /libpath:"$(AXIS2C_HOME)\lib"
+LINK32_OBJS= \
+ "$(INTDIR)\axis2_Calculator_stub.obj" \
+ "$(INTDIR)\CalculatorWSClient.obj"
+
+"$(OUTDIR)\calculator_wsclient.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Release
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\calculator_wsclient.exe"
+ call ..\..\..\..\..\Calculator\deploywsclient.bat ..\..\..\..\..\Calculator Release
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ELSEIF "$(CFG)" == "WSClient - Win32 Debug"
+
+OUTDIR=.\Debug
+INTDIR=.\Debug
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+ALL : "$(OUTDIR)\calculator_wsclient.exe"
+
+
+CLEAN :
+ -@erase "$(INTDIR)\axis2_Calculator_stub.obj"
+ -@erase "$(INTDIR)\CalculatorWSClient.obj"
+ -@erase "$(INTDIR)\vc60.idb"
+ -@erase "$(INTDIR)\vc60.pdb"
+ -@erase "$(OUTDIR)\calculator_wsclient.exe"
+ -@erase "$(OUTDIR)\calculator_wsclient.ilk"
+ -@erase "$(OUTDIR)\calculator_wsclient.pdb"
+
+"$(OUTDIR)" :
+ if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
+
+CPP=cl.exe
+CPP_PROJ=/nologo /MLd /W3 /Gm /GX /ZI /Od /I "$(TUSCANY_SDOCPP)/include" /I "$(AXIS2C_HOME)/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
+
+.c{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.obj::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.c{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cpp{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+.cxx{$(INTDIR)}.sbr::
+ $(CPP) @<<
+ $(CPP_PROJ) $<
+<<
+
+RSC=rc.exe
+BSC32=bscmake.exe
+BSC32_FLAGS=/nologo /o"$(OUTDIR)\WSClient.bsc"
+BSC32_SBRS= \
+
+LINK32=link.exe
+LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib tuscany_sdo.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\calculator_wsclient.pdb" /debug /machine:I386 /out:"$(OUTDIR)\calculator_wsclient.exe" /pdbtype:sept /libpath:"$(TUSCANY_SDOCPP)\lib" /libpath:"$(AXIS2C_HOME)\lib"
+LINK32_OBJS= \
+ "$(INTDIR)\axis2_Calculator_stub.obj" \
+ "$(INTDIR)\CalculatorWSClient.obj"
+
+"$(OUTDIR)\calculator_wsclient.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
+ $(LINK32) @<<
+ $(LINK32_FLAGS) $(LINK32_OBJS)
+<<
+
+SOURCE="$(InputPath)"
+DS_POSTBUILD_DEP=$(INTDIR)\postbld.dep
+
+ALL : $(DS_POSTBUILD_DEP)
+
+# Begin Custom Macros
+OutDir=.\Debug
+# End Custom Macros
+
+$(DS_POSTBUILD_DEP) : "$(OUTDIR)\calculator_wsclient.exe"
+ call ..\..\..\..\..\Calculator\deploywsclient.bat ..\..\..\..\..\Calculator Debug
+ echo Helper for Post-build step > "$(DS_POSTBUILD_DEP)"
+
+!ENDIF
+
+
+!IF "$(NO_EXTERNAL_DEPS)" != "1"
+!IF EXISTS("WSClient.dep")
+!INCLUDE "WSClient.dep"
+!ELSE
+!MESSAGE Warning: cannot find "WSClient.dep"
+!ENDIF
+!ENDIF
+
+
+!IF "$(CFG)" == "WSClient - Win32 Release" || "$(CFG)" == "WSClient - Win32 Debug"
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.wsclient\axis2_Calculator_stub.cpp
+
+"$(INTDIR)\axis2_Calculator_stub.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+SOURCE=..\..\..\..\..\Calculator\sample.calculator.wsclient\CalculatorWSClient.cpp
+
+"$(INTDIR)\CalculatorWSClient.obj" : $(SOURCE) "$(INTDIR)"
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+
+
+!ENDIF
+
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/build.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/build.cmd new file mode 100644 index 0000000000..0cf0ac8e3e --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/build.cmd @@ -0,0 +1,24 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +setlocal +call vcvars32 +cd Build +nmake -f Build.mak CFG="Build - Win32 Release" +cd .. +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/deploy.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/deploy.cmd new file mode 100644 index 0000000000..6e956aa4e6 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/deploy.cmd @@ -0,0 +1,73 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA Calculator sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +if . == .%2 ( +echo input directory not specified +goto usage +) +set inpath=%2 +echo %inpath% + + +set deploydir=%TUSCANY_SCACPP%\deploy +set samplesdir=%deploydir%\samples +set calcdir=%samplesdir%\Calculator +set calcdeploydir=%calcdir%\deploy + +if not exist %deploydir% mkdir %deploydir% +if not exist %samplesir% mkdir %samplesir% +if not exist %calcdir% mkdir %calcdir% +if not exist %calcdeploydir% mkdir %calcdeploydir% + +if not exist %destinationPath%\packages mkdir %destinationPath%\packages +if not exist %destinationPath%\packages\CalculatorComposite mkdir %destinationPath%\packages\CalculatorComposite + +copy %sourcePath%\CalculatorComposite\*.componentType %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\*.composite %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\Calculator.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\CalculatorImpl.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\DivideService.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\DivideServiceImpl.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\Calculator.wsdl %destinationPath%\packages\CalculatorComposite +copy %currentPath%\Calculator\%buildMode%\CalculatorComposite.dll %destinationPath%\packages\CalculatorComposite + +if not exist %destinationPath%\bin mkdir %destinationPath%\bin +copy %currentPath%\Client\%buildMode%\Client.exe %destinationPath%\bin +if %buildMode% == Debug ( +copy %currentPath%\Client\%buildMode%\Client.pdb %destinationPath%\bin +) +copy %sourcePath%\Client\runclient.cmd %destinationPath%\bin + + +if not exist %destinationPath%\configuration mkdir %destinationPath%\configuration +if not exist %destinationPath%\configuration\CalculatorSubsystem mkdir %destinationPath%\configuration\CalculatorSubsystem + +copy %sourcePath%\CalculatorSubsystem\*.composite %destinationPath%\configuration\CalculatorSubsystem + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/wsdeploy.cmd b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/wsdeploy.cmd new file mode 100644 index 0000000000..5c4f5fac71 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio6/projects/Calculator/wsdeploy.cmd @@ -0,0 +1,64 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA sample. +setlocal +set currentPath=%~d0%~p0 +set sourcePath=%currentPath%..\..\..\..\Calculator + +set buildMode=Release +if .Debug == .%1 ( +set buildMode=Debug +) + + +if . == %2. ( +set destinationPath=%sourcePath%\deploy +) ELSE ( +set destinationPath=%2 +) + + +if not exist %destinationPath%\packages mkdir %destinationPath%\packages +if not exist %destinationPath%\packages\CalculatorComposite mkdir %destinationPath%\packages\CalculatorComposite + +copy %sourcePath%\CalculatorComposite\*.componentType %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\*.composite %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\Calculator.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\CalculatorImpl.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\DivideService.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\DivideServiceImpl.h %destinationPath%\packages\CalculatorComposite +copy %sourcePath%\CalculatorComposite\Calculator.wsdl %destinationPath%\packages\CalculatorComposite +copy %currentPath%\Calculator\%buildMode%\CalculatorComposite.dll %destinationPath%\packages\CalculatorComposite + +if not exist %destinationPath%\bin mkdir %destinationPath%\bin +copy %currentPath%\WSClient\%buildMode%\WSClient.exe %destinationPath%\bin +if %buildMode% == Debug ( +copy %currentPath%\WSClient\%buildMode%\WSClient.pdb %destinationPath%\bin +) +copy %sourcePath%\WSClient\runwsclient.cmd %destinationPath%\bin + + +if not exist %destinationPath%\configuration mkdir %destinationPath%\configuration +if not exist %destinationPath%\configuration\CalculatorSubsystem mkdir %destinationPath%\configuration\CalculatorSubsystem + +copy %sourcePath%\CalculatorSubsystem\*.composite %destinationPath%\configuration\CalculatorSubsystem + + +endlocal diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/AccountClient/AccountClient.vcproj b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/AccountClient/AccountClient.vcproj new file mode 100644 index 0000000000..bf9e9aa352 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/AccountClient/AccountClient.vcproj @@ -0,0 +1,157 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="7.10"
+ Name="AccountClient"
+ SccProjectName=""
+ SccLocalPath="">
+ <Platforms>
+ <Platform
+ Name="Win32"/>
+ </Platforms>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="..\..\..\..\..\BigBank\bigbank.account;"$(TUSCANY_SDOCPP)/include";"$(TUSCANY_SCACPP)\extensions\cpp\include";"$(TUSCANY_SCACPP)/include""
+ PreprocessorDefinitions="WIN32,_DEBUG,_CONSOLE"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderFile=".\Debug/AccountClient.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"
+ DebugInformationFormat="4"
+ CompileAs="0"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="tuscany_sdo.lib tuscany_sca_cpp.lib tuscany_sca.lib"
+ OutputFile=".\Debug/AccountClient.exe"
+ LinkIncremental="2"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories=""$(TUSCANY_SCACPP)/lib";"$(TUSCANY_SCACPP)/extensions/cpp/lib";"$(TUSCANY_SDOCPP)/lib""
+ GenerateDebugInformation="TRUE"
+ ProgramDatabaseFile=".\Debug/AccountClient.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Debug/AccountClient.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\BigBank\deployclient.bat ..\..\..\..\..\BigBank Debug"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="..\..\..\..\..\BigBank\bigbank.account;"$(TUSCANY_SDOCPP)/include";"$(TUSCANY_SCACPP)\extensions\cpp\include";"$(TUSCANY_SCACPP)/include""
+ PreprocessorDefinitions="WIN32,NDEBUG,_CONSOLE"
+ StringPooling="TRUE"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="TRUE"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderFile=".\Release/AccountClient.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="tuscany_sdo.lib tuscany_sca_cpp.lib tuscany_sca.lib"
+ OutputFile=".\Release/AccountClient.exe"
+ LinkIncremental="1"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories=""$(TUSCANY_SCACPP)/lib";"$(TUSCANY_SCACPP)/extensions/cpp/lib";"$(TUSCANY_SDOCPP)/lib""
+ ProgramDatabaseFile=".\Release/AccountClient.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Release/AccountClient.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\BigBank\deployclient.bat ..\..\..\..\..\BigBank Release"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.client\AccountClient.cpp">
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl">
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/Accounts/Accounts.vcproj b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/Accounts/Accounts.vcproj new file mode 100644 index 0000000000..dbeb962b36 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/Accounts/Accounts.vcproj @@ -0,0 +1,270 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="7.10"
+ Name="Accounts"
+ SccProjectName=""
+ SccLocalPath="">
+ <Platforms>
+ <Platform
+ Name="Win32"/>
+ </Platforms>
+ <Configurations>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="2"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="$(TUSCANY_SCACPP)\include,$(TUSCANY_SCACPP)\extensions\cpp\include,$(TUSCANY_SDOCPP)\include"
+ PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;ACCOUNTS_EXPORTS"
+ StringPooling="TRUE"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="TRUE"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderFile=".\Release/Accounts.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="tuscany_sca.lib tuscany_sca_cpp.lib tuscany_sdo.lib"
+ OutputFile=".\Release/Account.dll"
+ LinkIncremental="1"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories=""$(TUSCANY_SCACPP)/extensions/cpp/lib";"$(TUSCANY_SCACPP)/lib";"$(TUSCANY_SDOCPP)/lib""
+ ProgramDatabaseFile=".\Release/Accounts.pdb"
+ ImportLibrary=".\Release/Accounts.lib"/>
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="NDEBUG"
+ MkTypLibCompatible="TRUE"
+ SuppressStartupBanner="TRUE"
+ TargetEnvironment="1"
+ TypeLibraryName=".\Release/Accounts.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\BigBank\deploy.bat ..\..\..\..\..\BigBank Release"/>
+ <Tool
+ Name="VCPreBuildEventTool"
+ CommandLine="$(TUSCANY_SCACPP)/bin/scagen.cmd -dir ..\..\..\..\..\BigBank\bigbank.account -output ..\..\..\..\..\BigBank\bigbank.account -verbose"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="2"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="$(TUSCANY_SCACPP)\include,$(TUSCANY_SCACPP)\extensions\cpp\include,$(TUSCANY_SDOCPP)\include"
+ PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;ACCOUNTS_EXPORTS"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderFile=".\Debug/Accounts.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"
+ DebugInformationFormat="4"
+ CompileAs="0"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="tuscany_sca.lib tuscany_sca_cpp.lib tuscany_sdo.lib"
+ OutputFile=".\Debug/Account.dll"
+ LinkIncremental="2"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories=""$(TUSCANY_SCACPP)/extensions/cpp/lib";"$(TUSCANY_SCACPP)/lib";"$(TUSCANY_SDOCPP)/lib""
+ GenerateDebugInformation="TRUE"
+ ProgramDatabaseFile=".\Debug/Account.pdb"
+ ImportLibrary=".\Debug/Accounts.lib"/>
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="_DEBUG"
+ MkTypLibCompatible="TRUE"
+ SuppressStartupBanner="TRUE"
+ TargetEnvironment="1"
+ TypeLibraryName=".\Debug/Accounts.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\BigBank\deploy.bat ..\..\..\..\..\BigBank Debug"/>
+ <Tool
+ Name="VCPreBuildEventTool"
+ CommandLine="$(TUSCANY_SCACPP)/bin/scagen.cmd -dir ..\..\..\..\..\BigBank\bigbank.account -output ..\..\..\..\..\BigBank\bigbank.account -verbose"
+ ExcludedFromBuild="FALSE"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Wrapper.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_accountDataService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Wrapper.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_stockQuoteService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Wrapper.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_webService_Proxy.cpp">
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl">
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataService.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl_AccountDataService_Wrapper.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountService.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_accountDataService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_AccountService_Wrapper.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl_stockQuoteService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteService.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_StockQuoteService_Wrapper.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl_webService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteWebService.h">
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountDataServiceImpl.componentType">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountService.wsdl">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\AccountServiceImpl.componentType">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\bigbank.account.composite">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.accountmanagement\bigbank.accountmanagement.composite">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteServiceImpl.componentType">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.account\StockQuoteWebService.wsdl">
+ </File>
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/BigBank.sln b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/BigBank.sln new file mode 100644 index 0000000000..26a497d219 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/BigBank.sln @@ -0,0 +1,37 @@ +Microsoft Visual Studio Solution File, Format Version 8.00
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "AccountClient", "AccountClient\AccountClient.vcproj", "{297C9F3A-EDB1-4EA1-86ED-473B0863B996}"
+ ProjectSection(ProjectDependencies) = postProject
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Accounts", "Accounts\Accounts.vcproj", "{87372DC7-582B-46C6-AA0F-960A47972503}"
+ ProjectSection(ProjectDependencies) = postProject
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WSAccountClient", "WSAccountClient\WSAccountClient.vcproj", "{E7F4DDEC-6592-434B-B5D6-4E538298C898}"
+ ProjectSection(ProjectDependencies) = postProject
+ EndProjectSection
+EndProject
+Global
+ GlobalSection(SolutionConfiguration) = preSolution
+ Debug = Debug
+ Release = Release
+ EndGlobalSection
+ GlobalSection(ProjectConfiguration) = postSolution
+ {297C9F3A-EDB1-4EA1-86ED-473B0863B996}.Debug.ActiveCfg = Debug|Win32
+ {297C9F3A-EDB1-4EA1-86ED-473B0863B996}.Debug.Build.0 = Debug|Win32
+ {297C9F3A-EDB1-4EA1-86ED-473B0863B996}.Release.ActiveCfg = Release|Win32
+ {297C9F3A-EDB1-4EA1-86ED-473B0863B996}.Release.Build.0 = Release|Win32
+ {87372DC7-582B-46C6-AA0F-960A47972503}.Debug.ActiveCfg = Debug|Win32
+ {87372DC7-582B-46C6-AA0F-960A47972503}.Debug.Build.0 = Debug|Win32
+ {87372DC7-582B-46C6-AA0F-960A47972503}.Release.ActiveCfg = Release|Win32
+ {87372DC7-582B-46C6-AA0F-960A47972503}.Release.Build.0 = Release|Win32
+ {E7F4DDEC-6592-434B-B5D6-4E538298C898}.Debug.ActiveCfg = Debug|Win32
+ {E7F4DDEC-6592-434B-B5D6-4E538298C898}.Debug.Build.0 = Debug|Win32
+ {E7F4DDEC-6592-434B-B5D6-4E538298C898}.Release.ActiveCfg = Release|Win32
+ {E7F4DDEC-6592-434B-B5D6-4E538298C898}.Release.Build.0 = Release|Win32
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ EndGlobalSection
+ GlobalSection(ExtensibilityAddIns) = postSolution
+ EndGlobalSection
+EndGlobal
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/WSAccountClient/WSAccountClient.vcproj b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/WSAccountClient/WSAccountClient.vcproj new file mode 100644 index 0000000000..ad6e7bfa89 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/BigBank/WSAccountClient/WSAccountClient.vcproj @@ -0,0 +1,163 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="7.10"
+ Name="WSAccountClient"
+ SccProjectName=""
+ SccLocalPath="">
+ <Platforms>
+ <Platform
+ Name="Win32"/>
+ </Platforms>
+ <Configurations>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="$(TUSCANY_SDOCPP)/include,$(AXIS2C_HOME)/include"
+ PreprocessorDefinitions="WIN32,NDEBUG,_CONSOLE"
+ StringPooling="TRUE"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="TRUE"
+ UsePrecompiledHeader="0"
+ PrecompiledHeaderFile=".\Release/WSAccountClient.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="tuscany_sca.lib tuscany_sdo.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib"
+ OutputFile=".\Release/WSAccountClient.exe"
+ LinkIncremental="1"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(TUSCANY_SCACPP)\lib,$(TUSCANY_SDOCPP)\lib,$(AXIS2C_HOME)\lib"
+ ProgramDatabaseFile=".\Release/WSAccountClient.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Release/WSAccountClient.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\BigBank\deploywsclient.bat ..\..\..\..\..\BigBank Release"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="$(TUSCANY_SDOCPP)/include,$(AXIS2C_HOME)/include"
+ PreprocessorDefinitions="WIN32,_DEBUG,_CONSOLE"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderFile=".\Debug/WSAccountClient.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"
+ DebugInformationFormat="4"
+ CompileAs="0"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="tuscany_sca.lib tuscany_sdo.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib"
+ OutputFile=".\Debug/WSAccountClient.exe"
+ LinkIncremental="2"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(TUSCANY_SCACPP)\lib,$(TUSCANY_SDOCPP)\lib,$(AXIS2C_HOME)\lib"
+ GenerateDebugInformation="TRUE"
+ ProgramDatabaseFile=".\Debug/WSAccountClient.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Debug/WSAccountClient.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\BigBank\deploywsclient.bat ..\..\..\..\..\BigBank Debug"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.wsclient\AccountWSClient.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.wsclient\axis2_Account_stub.cpp">
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl">
+ <File
+ RelativePath="..\..\..\..\..\BigBank\bigbank.wsclient\axis2_Account_stub.h">
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator.sln b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator.sln new file mode 100644 index 0000000000..271c1ae327 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator.sln @@ -0,0 +1,39 @@ +Microsoft Visual Studio Solution File, Format Version 8.00
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Calculator", "Calculator\Calculator.vcproj", "{B1C1917A-4423-456D-9F68-3C600C885A1F}"
+ ProjectSection(ProjectDependencies) = postProject
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Client", "Client\Client.vcproj", "{CA2CB545-D0E2-416C-BE93-90BC4DD82B90}"
+ ProjectSection(ProjectDependencies) = postProject
+ {B1C1917A-4423-456D-9F68-3C600C885A1F} = {B1C1917A-4423-456D-9F68-3C600C885A1F}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WSClient", "WSClient\WSClient.vcproj", "{3CDD5BC2-9722-4F7D-8B0E-1A49D34E7A17}"
+ ProjectSection(ProjectDependencies) = postProject
+ {B1C1917A-4423-456D-9F68-3C600C885A1F} = {B1C1917A-4423-456D-9F68-3C600C885A1F}
+ EndProjectSection
+EndProject
+Global
+ GlobalSection(SolutionConfiguration) = preSolution
+ Debug = Debug
+ Release = Release
+ EndGlobalSection
+ GlobalSection(ProjectConfiguration) = postSolution
+ {B1C1917A-4423-456D-9F68-3C600C885A1F}.Debug.ActiveCfg = Debug|Win32
+ {B1C1917A-4423-456D-9F68-3C600C885A1F}.Debug.Build.0 = Debug|Win32
+ {B1C1917A-4423-456D-9F68-3C600C885A1F}.Release.ActiveCfg = Release|Win32
+ {B1C1917A-4423-456D-9F68-3C600C885A1F}.Release.Build.0 = Release|Win32
+ {CA2CB545-D0E2-416C-BE93-90BC4DD82B90}.Debug.ActiveCfg = Debug|Win32
+ {CA2CB545-D0E2-416C-BE93-90BC4DD82B90}.Debug.Build.0 = Debug|Win32
+ {CA2CB545-D0E2-416C-BE93-90BC4DD82B90}.Release.ActiveCfg = Release|Win32
+ {CA2CB545-D0E2-416C-BE93-90BC4DD82B90}.Release.Build.0 = Release|Win32
+ {3CDD5BC2-9722-4F7D-8B0E-1A49D34E7A17}.Debug.ActiveCfg = Debug|Win32
+ {3CDD5BC2-9722-4F7D-8B0E-1A49D34E7A17}.Debug.Build.0 = Debug|Win32
+ {3CDD5BC2-9722-4F7D-8B0E-1A49D34E7A17}.Release.ActiveCfg = Release|Win32
+ {3CDD5BC2-9722-4F7D-8B0E-1A49D34E7A17}.Release.Build.0 = Release|Win32
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ EndGlobalSection
+ GlobalSection(ExtensibilityAddIns) = postSolution
+ EndGlobalSection
+EndGlobal
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator.suo b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator.suo Binary files differnew file mode 100644 index 0000000000..bf0864adfe --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator.suo diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator/Calculator.vcproj b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator/Calculator.vcproj new file mode 100644 index 0000000000..a2b02ca4d9 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Calculator/Calculator.vcproj @@ -0,0 +1,224 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="7.10"
+ Name="Calculator"
+ SccProjectName=""
+ SccLocalPath="">
+ <Platforms>
+ <Platform
+ Name="Win32"/>
+ </Platforms>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="2"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="$(TUSCANY_SDOCPP)/include,$(TUSCANY_SCACPP)/include,$(TUSCANY_SCACPP)/extensions/cpp/include"
+ PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;CALCULATOR_EXPORTS"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="1"
+ UsePrecompiledHeader="0"
+ PrecompiledHeaderFile=".\Debug/Calculator.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"
+ DebugInformationFormat="4"
+ CompileAs="0"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="odbc32.lib odbccp32.lib tuscany_sca.lib tuscany_sdo.lib tuscany_sca_cpp.lib"
+ OutputFile=".\Debug/Calculator.dll"
+ LinkIncremental="2"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(TUSCANY_SDOCPP)/lib,$(TUSCANY_SCACPP)/lib,$(TUSCANY_SCACPP)/extensions/cpp/lib"
+ GenerateDebugInformation="TRUE"
+ ProgramDatabaseFile=".\Debug/Calculator.pdb"
+ ImportLibrary=".\Debug/Calculator.lib"/>
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="_DEBUG"
+ MkTypLibCompatible="TRUE"
+ SuppressStartupBanner="TRUE"
+ TargetEnvironment="1"
+ TypeLibraryName=".\Debug/Calculator.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\Calculator\deploy.bat ..\..\..\..\..\Calculator Debug"/>
+ <Tool
+ Name="VCPreBuildEventTool"
+ CommandLine="$(TUSCANY_SCACPP)/bin/scagen.cmd -dir ../../../../../Calculator/sample.calculator -output ../../../../../Calculator/sample.calculator -verbose"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="2"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="$(TUSCANY_SDOCPP)/include,$(TUSCANY_SCACPP)/include,$(TUSCANY_SCACPP)/extensions/cpp/include"
+ PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;CALCULATOR_EXPORTS"
+ StringPooling="TRUE"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="TRUE"
+ UsePrecompiledHeader="0"
+ PrecompiledHeaderFile=".\Release/Calculator.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="odbc32.lib odbccp32.lib tuscany_sca.lib tuscany_sdo.lib tuscany_sca_cpp.lib"
+ OutputFile=".\Release/Calculator.dll"
+ LinkIncremental="1"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(TUSCANY_SDOCPP)/lib,$(TUSCANY_SCACPP)/lib,,$(TUSCANY_SCACPP)/extensions/cpp/lib"
+ ProgramDatabaseFile=".\Release/Calculator.pdb"
+ ImportLibrary=".\Release/Calculator.lib"/>
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="NDEBUG"
+ MkTypLibCompatible="TRUE"
+ SuppressStartupBanner="TRUE"
+ TargetEnvironment="1"
+ TypeLibraryName=".\Release/Calculator.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\Calculator\deploy.bat ..\..\..\..\..\Calculator Release"/>
+ <Tool
+ Name="VCPreBuildEventTool"
+ CommandLine="$(TUSCANY_SCACPP)/bin/scagen.cmd -dir ../../../../../Calculator/sample.calculator -output ../../../../../Calculator/sample.calculator -verbose"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\Calculator.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Wrapper.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_CalculatorService_Wrapper.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_divideService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl_divideService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\Divide.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Proxy.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Proxy.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Wrapper.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl_DivideService_Wrapper.h">
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\Calculator.wsdl">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\CalculatorImpl.componentType">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\DivideImpl.componentType">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator\sample.calculator.composite">
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl">
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Client/Client.vcproj b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Client/Client.vcproj new file mode 100644 index 0000000000..a53a3eccf3 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/Client/Client.vcproj @@ -0,0 +1,157 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="7.10"
+ Name="Client"
+ SccProjectName=""
+ SccLocalPath="">
+ <Platforms>
+ <Platform
+ Name="Win32"/>
+ </Platforms>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="..\..\..\..\..\Calculator\sample.calculator,$(TUSCANY_SDOCPP)/include,$(TUSCANY_SCACPP)/include,$(TUSCANY_SCACPP)/extensions/cpp/include"
+ PreprocessorDefinitions="WIN32,_DEBUG,_CONSOLE"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ PrecompiledHeaderFile=".\Debug/Client.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"
+ DebugInformationFormat="4"
+ CompileAs="0"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib"
+ OutputFile="./Debug/calculator_client.exe"
+ LinkIncremental="2"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(TUSCANY_SDOCPP)/lib,$(TUSCANY_SCACPP)/lib,$(TUSCANY_SCACPP)/extensions/cpp/lib"
+ GenerateDebugInformation="TRUE"
+ ProgramDatabaseFile=".\Debug/calculator_client.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Debug/Client.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\Calculator\deployclient.bat ..\..\..\..\..\Calculator Debug"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="1"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="..\..\..\..\..\Calculator\sample.calculator,$(TUSCANY_SDOCPP)/include,$(TUSCANY_SCACPP)/include,$(TUSCANY_SCACPP)/extensions/cpp/include"
+ PreprocessorDefinitions="WIN32,NDEBUG,_CONSOLE"
+ StringPooling="TRUE"
+ RuntimeLibrary="2"
+ EnableFunctionLevelLinking="TRUE"
+ UsePrecompiledHeader="0"
+ PrecompiledHeaderFile=".\Release/Client.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="odbc32.lib odbccp32.lib tuscany_sdo.lib tuscany_sca.lib tuscany_sca_cpp.lib"
+ OutputFile=".\Release/calculator_client.exe"
+ LinkIncremental="1"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(TUSCANY_SDOCPP)/lib,$(TUSCANY_SCACPP)/lib,$(TUSCANY_SCACPP)/extensions/cpp/lib"
+ ProgramDatabaseFile=".\Release/calculator_client.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Release/Client.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\Calculator\deployclient.bat ..\..\..\..\..\Calculator Release"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator.client\CalculatorClient.cpp">
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl">
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/WSClient/BuildInstructions.txt b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/WSClient/BuildInstructions.txt new file mode 100644 index 0000000000..6757f3ad3a --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/WSClient/BuildInstructions.txt @@ -0,0 +1,95 @@ + +These sample projects will build: + +A basic calculator SCA service. +A client to test that service. +A WSClient to test the service as exposed by AXIS2C as a web service. + +The sample depdends on the current versions of Tuscany SDO and Tuscany SCA, which in turn +depend on axis2c version 0.92, and libxml2. See the SCA and SDO project installation +details. + +The sample already has the pre-generated proxy and wrapper code in it, but should +you need to regenerate these, you will need the command line tool "scagen" which is +part of the Tuscany SCA project. + +The projects expect to following environment variables to be set: +TUSCANY_SCACPP: +The directory in which the sca runtime is deployed - probably something ending in sca/deploy. + +TUSCANY_SDOCPP: +The directory where the sdo runtime is deployed - probably something ending in sdo/deploy. + +TUSCANY_SCACPP_DEFAULT_COMPOSITE: +This is the default composite to be loaded by SCA. It consists of <subsystem>/<component>. +In the case of this sample - its set programatically by the client - thats easier when +using visual studio. + +TUSCANY_SCACPP_SYSTEM_ROOT +This is the point from which SCA will start looking for composites to load. Again this is +set programmatically by the sample. + +AXIS2C_HOME: +This is where axis2c is deployed- this is only required by the WSClient project. + +The Calculator project contains a simple calculator service, and the descriptive files +which help the runtime to find the service. + + +Rebuilding the proxy and wrapper classes +======================================== + +If required, go to the Calculator sample main directory, and +type: +"scagen -dir CalculatorComposite -output CalculatorComposite" + +The generated code is put into the CalculatorComposite subdirectory. + +Building the Client project +=========================== + +Set the active project to be "Client", and then build all. +This will re-build Calculator, then rebuild the Client, +The final step of the build will call a batch file "deploy.cmd", +which copies all the required files to the directory samples/Calculator/deploy + +Use Project..Settings..Debug and check the path to the executable, check also the +path to the working directory. Alter these to match your configuration. + +Run the project, and your SCA service should be called. + +Building the WSClient project +============================= + +Modify the services.xml file, and make the SCA system root defined +within it comply with your SCA system root. + +Set the active project to WSClient and build all. + +The last step of the build will run a wsdeploy script, which +tries to use the environment variable AXIS2C_HOME, to create +a services/Calculator directory, and deploy the services.xml file. +The dll which resolves SCA services is called +tuscany_sca_ws_service.dll - this will be copied to the axis +tree by the same script file. + +To run the axis2 http server, go to the %AXIS2C_HOME%/bin +directory, and launch the executable. + +Now verify that the path to the WSClient executable makes sense +in your project settings, and run the project. + + +Note +==== + +It can be quite hard to debug services which are invoked through axis, as the +dll including the service is loaded on call. One useful technique is to +load the axis http server in visual studio (create an empty project and make +the executable path point to axis2_http_server.exe). +Now use the Project..Settings..Debug..Addition DLLs option and add +services/Calculator/tuscany_sca_ws_service.dll. +You will now be able to set breakpoints in the dll (Axis2EntryPointService_invoke +is a good place - in Axis2EntryPointService_skeleton.cpp). +Run your WSclient from another debugger, and the server debugger will break +on the service code. diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/WSClient/WSClient.vcproj b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/WSClient/WSClient.vcproj new file mode 100644 index 0000000000..585d66bdbf --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/ides/devstudio7/projects/Calculator/WSClient/WSClient.vcproj @@ -0,0 +1,169 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="7.10"
+ Name="WSClient"
+ SccProjectName=""
+ SccLocalPath="">
+ <Platforms>
+ <Platform
+ Name="Win32"/>
+ </Platforms>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory=".\Debug"
+ IntermediateDirectory=".\Debug"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="$(AXIS2C_HOME)/include"
+ PreprocessorDefinitions="WIN32,_DEBUG,_CONSOLE"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="5"
+ UsePrecompiledHeader="0"
+ PrecompiledHeaderFile=".\Debug/WSClient.pch"
+ AssemblerListingLocation=".\Debug/"
+ ObjectFile=".\Debug/"
+ ProgramDataBaseFileName=".\Debug/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"
+ DebugInformationFormat="4"
+ CompileAs="0"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="odbc32.lib odbccp32.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib"
+ OutputFile=".\Debug/calculator_wsclient.exe"
+ LinkIncremental="2"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(AXIS2C_HOME)\lib"
+ GenerateDebugInformation="TRUE"
+ ProgramDatabaseFile=".\Debug/calculator_wsclient.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Debug/WSClient.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\Calculator\deploywsclient.bat ..\..\..\..\..\Calculator Debug"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory=".\Release"
+ IntermediateDirectory=".\Release"
+ ConfigurationType="1"
+ UseOfMFC="0"
+ ATLMinimizesCRunTimeLibraryUsage="FALSE"
+ CharacterSet="2">
+ <Tool
+ Name="VCCLCompilerTool"
+ InlineFunctionExpansion="1"
+ AdditionalIncludeDirectories="$(AXIS2C_HOME)/include"
+ PreprocessorDefinitions="WIN32,NDEBUG,_CONSOLE"
+ StringPooling="TRUE"
+ RuntimeLibrary="4"
+ EnableFunctionLevelLinking="TRUE"
+ UsePrecompiledHeader="0"
+ PrecompiledHeaderFile=".\Release/WSClient.pch"
+ AssemblerListingLocation=".\Release/"
+ ObjectFile=".\Release/"
+ ProgramDataBaseFileName=".\Release/"
+ WarningLevel="3"
+ SuppressStartupBanner="TRUE"/>
+ <Tool
+ Name="VCCustomBuildTool"/>
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalOptions="/MACHINE:I386"
+ AdditionalDependencies="odbc32.lib odbccp32.lib axis2_engine.lib axis2_parser.lib axis2_util.lib axiom.lib"
+ OutputFile=".\Release/calculator_wsclient.exe"
+ LinkIncremental="1"
+ SuppressStartupBanner="TRUE"
+ AdditionalLibraryDirectories="$(AXIS2C_HOME)\lib"
+ ProgramDatabaseFile=".\Release/calculator_wsclient.pdb"
+ SubSystem="1"/>
+ <Tool
+ Name="VCMIDLTool"
+ TypeLibraryName=".\Release/WSClient.tlb"/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\..\..\Calculator\deploywsclient.bat ..\..\..\..\..\Calculator Release"/>
+ <Tool
+ Name="VCPreBuildEventTool"/>
+ <Tool
+ Name="VCPreLinkEventTool"/>
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="2057"/>
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"/>
+ <Tool
+ Name="VCXMLDataGeneratorTool"/>
+ <Tool
+ Name="VCWebDeploymentTool"/>
+ <Tool
+ Name="VCManagedWrapperGeneratorTool"/>
+ <Tool
+ Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator.wsclient\axis2_Calculator_stub.cpp">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator.wsclient\axis2_Calculator_stub.h">
+ </File>
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator.wsclient\CalculatorWSClient.cpp">
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl">
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
+ <File
+ RelativePath="..\..\..\..\..\Calculator\sample.calculator.wsclient\services.xml">
+ </File>
+ </Filter>
+ <File
+ RelativePath=".\BuildInstructions.txt">
+ </File>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/tags/cpp-1.0-incubating-M2-RC1/sca/samples/scagen.bat b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/scagen.bat new file mode 100644 index 0000000000..a717341086 --- /dev/null +++ b/tags/cpp-1.0-incubating-M2-RC1/sca/samples/scagen.bat @@ -0,0 +1,37 @@ +@echo off +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. + +rem Will copy the correct files from the source tree for packaging and deployment of the +rem SCA Calculator sample. + +setlocal + +if . == .%1 ( +echo source path not specified +goto usage +) +set srcdir=%1 + +%TUSCANY_SCACPP%\bin\scagen.cmd -dir %srcdir% -output %srcdir% -verbose + +goto end +:usage +echo Usage: scagen <sample-src> +:end + +endlocal |