Return-Path: Delivered-To: apmail-ws-axis-c-user-archive@www.apache.org Received: (qmail 77831 invoked from network); 21 Jun 2004 16:27:09 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 21 Jun 2004 16:27:09 -0000 Received: (qmail 82545 invoked by uid 500); 21 Jun 2004 16:27:20 -0000 Delivered-To: apmail-ws-axis-c-user-archive@ws.apache.org Received: (qmail 82528 invoked by uid 500); 21 Jun 2004 16:27:19 -0000 Mailing-List: contact axis-c-user-help@ws.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: List-Id: "Apache AXIS C User List" Reply-To: "Apache AXIS C User List" Delivered-To: mailing list axis-c-user@ws.apache.org Received: (qmail 82409 invoked by uid 99); 21 Jun 2004 16:27:18 -0000 Received: from [134.226.32.56] (HELO mail.cs.tcd.ie) (134.226.32.56) by apache.org (qpsmtpd/0.27.1) with ESMTP; Mon, 21 Jun 2004 09:27:18 -0700 Received: from mail.cs.tcd.ie (localhost [127.0.0.1]) by relay.cs.tcd.ie (Postfix) with ESMTP id E5E947BDC for ; Mon, 21 Jun 2004 17:26:59 +0100 (IST) Received: from pc1600.cs.tcd.ie (pc1600.cs.tcd.ie [134.226.53.239]) by mail.cs.tcd.ie (Postfix) with ESMTP id CBC347BCF for ; Mon, 21 Jun 2004 17:26:59 +0100 (IST) Subject: Re: Axis C++ Calculator example From: Oliver Lyttleton To: Apache AXIS C User List In-Reply-To: <40D6ECE1.90509@etu.univ-savoie.fr> References: <40D6B0F7.1010003@cs.tcd.ie> <40D6C090.50602@etu.univ-savoie.fr> <1087825967.20978.16.camel@pc1600.cs.tcd.ie> <40D6ECE1.90509@etu.univ-savoie.fr> Content-Type: text/plain Organization: Message-Id: <1087835219.20978.18.camel@pc1600.cs.tcd.ie> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.2 (1.2.2-5) Date: 21 Jun 2004 17:26:59 +0100 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Sorry, that still doesn't work! Any other suggestions from anybody?!? On Mon, 2004-06-21 at 15:12, Mansart Jean-sebastien wrote: > Oliver Lyttleton wrote: > > >On the client side, I'm doing exactly as you're telling me. However, I > >am unsure as to what should be done on the server side. Also, I'm a > >little confused by the Calculator.cpp file on the client side.... > > > >if (AXIS_SUCCESS == m_pCall->Invoke()) > > { > > if(AXIS_SUCCESS == m_pCall->CheckMessage("subResponse", > > "http://localhost/axis/Calculator")) > > { > > /*not successful*/ > > } > > } > > > >Does this mean that if the second if statement evaluates to true, the > >invocation has failed? How is the value for the result of an operation > >sent back to the client, should code be inserted to do this where the > >"not successful" comment is? If so, what methods from Call.cpp are used > >to do this? > > > > > Yes I know that this part is a little disturbing... > So, for myself I think that the second statement if evaluate to true is > a success, not a failure... > > >Also, how is the result from the service invocation in > >$AXISCPP/samples/client/simple/Calculator.cpp returned to the CalcClient > >program? In the example taken from the user guide (see below in previous > >mail) the values passed to the Calculator method aren't passed by > >reference. So how can intOut have *any* other value other than the value > >it was instantiated with?!? > > > > > > > > > So here, yes you have to add some code... > so in the calcultator.cpp you have this line: > m_pCall->AddParameter((void*)&Value2, "addReturn", XSD_INT); > try to add a line like this juste after the /*not successful*/ > Value2 = m_pCall->GetElementAsString("addReturn", 0); > this line is for getting the element where the response is... > > I don't have enought time to explain more... > try to make it work with this... > > > > >On Mon, 2004-06-21 at 12:03, Mansart Jean-sebastien wrote: > > > > > >>Oliver Lyttleton wrote: > >> > >> > >> > >>>I'm not sure how I get the Axis C++ Calculator example to work. I know > >>>that the files generated by WSDL2ws are skeletons, and must be completed > >>>by the user, but I don't know what else needs to be added! > >>> > >>> > >>You have to write a client that use the class in claculator.cpp > >>for example create a file CalcClient.cpp and then fill it with this: > >> > >>#include "Calculator.h" > >>#include > >>int main() > >> { > >> Calculator c; > >> int intOut=0; > >> c.add(20, 40, intOut); > >> printf("result is = %d\n", intOut); > >> return 0; > >> } > >> > >> > >> > >> > >>>For instance, do I need to add anything to > >>>$AXISCPP_HOME/samples/client/simple/calculator.cpp > >>>in order to get the example to work? > >>> > >>> > >>see up... > >> > >> > >> > >>>Do I need to add anything to > >>>$AXISCPP_HOME/samples/server/simple/calculator.cpp? > >>> > >>> > >>for the server I don't know... > >>but read the userguide from the internet... I found the code for the > >>client... so maybe there is something for ther server part too... > >> > >> > >> > >>>My question is: what files do I need to add extra code to in order to > >>>get the calculator sample to work? And what code should I add? > >>> > >>>Thanks in advance, > >>> > >>>Oliver > >>> > >>> > >>> > >>> > > > > > > > > >