Re: client side handler

2009-11-20 Thread Amila Suriarachchi
On Thu, Nov 19, 2009 at 4:10 PM, Valerio Synclab wrote:

>  Hi all,
>
>
>
> I am trying to add an handler in my axis2 client and in order to do this I
> followed the “Writing Your Own Axis2 Module” tutorial adapting it for the
> client side.
>
>
>
> The problem is that the handler is not called at all during the web service
> invocation.
>
>
>
> Here is what I have done:
>
>
>
> This is the handler code
>
> **
>
> public class Handler extends AbstractHandler implements
> org.apache.axis2.engine.Handler{
>
> private String name;
>
> public InvocationResponse invoke(MessageContext arg0)
> throws AxisFault {
>
>
> System.out.println(arg0.getEnvelope().toString());
>
>return InvocationResponse.CONTINUE;
>
> }
>
> public void revoke(MessageContext msgContext) {
>
>
> System.out.println(msgContext.getEnvelope().toString());
>
> }
>
> public String getName() {
>
> return name;
>
> }
>
> public void setName(String name) {
>
> this.name = name;
>
> }
>
> }
>
>
>
> This is the module.xml
>
>
>
>
>
> ***
>
> 
>
>
>
> 
>
> 
>
> 
>
>
>
>
>
>
>
> 
>
> 
>
> 
>
>
>
>
>
>
>
>  class="obg.test.client.Handler">
>
> 
>
> 
>
>
>
>
>
>
>
>  class="obg.test.client.Handler">
>
> 
>
> 
>
>
>
> 
>
>
>
>
>
> This is what I added into axis.xml for each phaseOrder
>
>
>
> I tried both
>
>
>
> 
>
>  class="obg.test.client.Handler">
>
>   
>
>   
>
> 
>
>
>
> and
>
>
>
>  
>
>
>
> Finally I create my stub in this way:
>
>
>
> ConfigurationContext ctx = null;
>
>try {
>
>ctx =
> ConfigurationContextFactory.createConfigurationContextFromFileSystem("……/axis2.xml");
>
>} catch (AxisFault e1) {
>
>// TODO Auto-generated catch
> block
>
>e1.printStackTrace();
>
>}
>
>// TODO Auto-generated method stub
>
>try{
>
>SMSServiceStub stub = new
> SMSServiceStub(ctx, "……?wsdl");
>
do
stub._getServiceClient().engangeModule("test");

Amila.

>
>
> * *
>
> What else Do I have to do?
>
>
>
> Any suggestions?
>
> Best regards
>
>
>
> Valerio
>
>
>



-- 
Amila Suriarachchi
WSO2 Inc.
blog: http://amilachinthaka.blogspot.com/


client side handler

2009-11-19 Thread Valerio Synclab
Hi all,

 

I am trying to add an handler in my axis2 client and in order to do this I
followed the "Writing Your Own Axis2 Module" tutorial adapting it for the
client side.

 

The problem is that the handler is not called at all during the web service
invocation.

 

Here is what I have done:

 

This is the handler code

**

public class Handler extends AbstractHandler implements
org.apache.axis2.engine.Handler{

private String name;

public InvocationResponse invoke(MessageContext arg0) throws
AxisFault {

 
System.out.println(arg0.getEnvelope().toString());

   return InvocationResponse.CONTINUE;  

}

public void revoke(MessageContext msgContext) {

 
System.out.println(msgContext.getEnvelope().toString());

}

public String getName() {

return name;

}

public void setName(String name) {

this.name = name;

}

}

 

This is the module.xml

 

 

***



   







   

 

   







   

 

   







   

 

   







   



 

 

This is what I added into axis.xml for each phaseOrder

 

I tried both 

 





  

  



 

and 

 

 

 

Finally I create my stub in this way:

 

ConfigurationContext ctx = null;

   try {

   ctx =
ConfigurationContextFactory.createConfigurationContextFromFileSystem("../axi
s2.xml");

   } catch (AxisFault e1) {

   // TODO Auto-generated catch
block

   e1.printStackTrace();

   }

   // TODO Auto-generated method stub

   try{

   SMSServiceStub stub = new SMSServiceStub(ctx,
"..?wsdl");

 

 

What else Do I have to do?

 

Any suggestions?

Best regards

 

Valerio 

 



RE: How to add a SOAP header in an axis2 custom client-side handler?

2008-08-14 Thread Martin Gainty

Good Morning Allen-

you'll need to use the org.apache.axis2.context.ConfigurationContext to get at 
the SOAPSessionTable 
as in 
ConfigurationContext ctx = 
endpointDesc.getServiceDescription().getAxisConfigContext();
and to get at the session
getServiceGroupContextFromSoapSessionTable
More information available at
http://ws.apache.org/axis2/1_3/api/org/apache/axis2/context/ConfigurationContext.html

HTH
Martin 
__ 
Disclaimer and confidentiality note 
Everything in this e-mail and any attachments relates to the official business 
of Sender. This transmission is of a confidential nature and Sender does not 
endorse distribution to any party other than intended recipient. Sender does 
not necessarily endorse content contained within this transmission. 


Date: Thu, 14 Aug 2008 16:20:35 +0300
From: [EMAIL PROTECTED]
To: axis-user@ws.apache.org
Subject: Re: How to add a SOAP header in an axis2 custom client-side handler?

Hi,
 Should be as simple as:

import org.apache.axiom.soap.*;

SOAPHeader header = context.getEnvelope().getHeader(); //context is Axis2 
MessageContext
SOAPHeaderBlock headerBlock = header.addHeaderBlock(HEADER_NAME, HEADER_NS);


Now you can add whatever you want to the headerBlock, it is just an ordinary 
Axiom OMElement, e.g.
headerBlock.setText("my value");

See javadocs: 
http://ws.apache.org/commons/axiom/apidocs/org/apache/axiom/soap/SOAPHeaderBlock.html


Regards,
Detelin

On Thu, Aug 14, 2008 at 3:48 PM, Franklin, Allen <[EMAIL PROTECTED]> wrote:















I don't have a services.xml, and I don't have the manageTransportSession
parameter in my axis2.xml.

But I am just running an axis2 client and my client seems to run
ok without them.

 

I am stuck trying to figure out how to manipulate the SOAP
header in my client-side handler.

The semantics for manipulating the SOAP header has changed
between axis1 and axis2.

I am having trouble finding documentation and sample code that
manipulates the

SOAP header obtained from a MessageContext.

 





From: Martin Gainty
[mailto:[EMAIL PROTECTED] 

Sent: Wednesday, August 13, 2008 8:43 PM

To: axis-user@ws.apache.org

Subject: RE: How to add a SOAP header in an axis2 custom client-side
handler?





 

didn't see your config params

axis2.xml

?



services.xml

  



Martin 

__ 

Disclaimer and confidentiality note 

Everything in this e-mail and any attachments relates to the official business
of Sender. This transmission is of a confidential nature and Sender does not
endorse distribution to any party other than intended recipient. Sender does
not necessarily endorse content contained within this transmission. 











Subject: How to add a SOAP header in an
axis2 custom client-side handler?

Date: Wed, 13 Aug 2008 18:26:36 -0400

From: [EMAIL PROTECTED]

To: axis-user@ws.apache.org



I am trying to figure out how to add a SOAP header in my
client-side handler.

I have the following axis1 code, but need an axis2 equivalent:

 

  
/***

* Processes the header of a request
message.  This method will add the 

* session header to the outgoing request.

* 

* @param context the message context
associated with the request

   
**/

   private void invokeRequest( MessageContext context
) throws AxisFault

   { 

  Message msg =
context.getRequestMessage();

  if (msg == null)

 throw new
AxisFault( "Message not in context." );

   


  SOAPEnvelope env =
msg.getSOAPEnvelope();

 

  SessionHeaderType sessionHeader =
WebServiceClientHelper.getThreadSessionHeader( );

 

  SOAPHeaderElement header = new
SOAPHeaderElement(HEADER_NS,


  HEADER_NAME,

  
sessionHeader);

  env.addHeader(header);

   }

 

The SessionHeaderType class was generated from a wsdl and
contains session credentials.

 

Any pointers to appropriate documentation on how to manipulate headers,
or sample code, would be appreciated.



 







Your
PC, mobile phone, and online services work together like never before. See how
Windows® fits your life









_
Got Game? Win Prizes in the Windows Live Hotmail Mobile Summer Games Trivia 
Contest
http://www.gowindowslive.com/summergames?ocid=TXT_TAGHM

Re: How to add a SOAP header in an axis2 custom client-side handler?

2008-08-14 Thread Detelin Yordanov
Hi,
 Should be as simple as:

import org.apache.axiom.soap.*;

SOAPHeader header = context.getEnvelope().getHeader(); //context is Axis2
MessageContext
SOAPHeaderBlock headerBlock = header.addHeaderBlock(HEADER_NAME, HEADER_NS);

Now you can add whatever you want to the headerBlock, it is just an ordinary
Axiom OMElement, e.g.
headerBlock.setText("my value");

See javadocs:
http://ws.apache.org/commons/axiom/apidocs/org/apache/axiom/soap/SOAPHeaderBlock.html

Regards,
Detelin

On Thu, Aug 14, 2008 at 3:48 PM, Franklin, Allen <[EMAIL PROTECTED]
> wrote:

>  I don't have a services.xml, and I don't have the manageTransportSession 
> parameter
> in my axis2.xml.
>
> But I am just running an axis2 client and my client seems to run ok without
> them.
>
>
>
> I am stuck trying to figure out how to manipulate the SOAP header in my
> client-side handler.
>
> The semantics for manipulating the SOAP header has changed between axis1
> and axis2.
>
> I am having trouble finding documentation and sample code that manipulates
> the
>
> SOAP header obtained from a MessageContext.
>
>
>
> *From:* Martin Gainty [mailto:[EMAIL PROTECTED]
> *Sent:* Wednesday, August 13, 2008 8:43 PM
> *To:* axis-user@ws.apache.org
> *Subject:* RE: How to add a SOAP header in an axis2 custom client-side
> handler?
>
>
>
> didn't see your config params
> axis2.xml
> ?
>
> services.xml
>   
>
> Martin
> __
> Disclaimer and confidentiality note
> Everything in this e-mail and any attachments relates to the official
> business of Sender. This transmission is of a confidential nature and Sender
> does not endorse distribution to any party other than intended recipient.
> Sender does not necessarily endorse content contained within this
> transmission.
>
>  --
>
> Subject: How to add a SOAP header in an axis2 custom client-side handler?
> Date: Wed, 13 Aug 2008 18:26:36 -0400
> From: [EMAIL PROTECTED]
> To: axis-user@ws.apache.org
>
> I am trying to figure out how to add a SOAP header in my client-side
> handler.
>
> I have the following axis1 code, but need an axis2 equivalent:
>
>
>
>/***
>
> * Processes the header of a request message.  This method will add the
>
> * session header to the outgoing request.
>
> *
>
> * @param context the message context associated with the request
>
> **/
>
>private void invokeRequest( MessageContext context ) throws AxisFault
>
>{
>
>   Message msg = context.getRequestMessage();
>
>   if (msg == null)
>
>  throw new AxisFault( "Message not in context." );
>
>
>
>   SOAPEnvelope env = msg.getSOAPEnvelope();
>
>
>
>   SessionHeaderType sessionHeader =
> WebServiceClientHelper.getThreadSessionHeader( );
>
>
>
>   SOAPHeaderElement header = new SOAPHeaderElement(HEADER_NS,
>
>HEADER_NAME,
>
>sessionHeader);
>
>   env.addHeader(header);
>
>}
>
>
>
> The SessionHeaderType class was generated from a wsdl and contains session
> credentials.
>
>
>
> Any pointers to appropriate documentation on how to manipulate headers, or
> sample code, would be appreciated.
>
>
>  --
>
> Your PC, mobile phone, and online services work together like never before.
> See how Windows(R) fits your 
> life<http://clk.atdmt.com/MRT/go/108587394/direct/01/>
>


RE: How to add a SOAP header in an axis2 custom client-side handler?

2008-08-14 Thread Franklin, Allen
I don't have a services.xml, and I don't have the manageTransportSession
parameter in my axis2.xml.

But I am just running an axis2 client and my client seems to run ok
without them.

 

I am stuck trying to figure out how to manipulate the SOAP header in my
client-side handler.

The semantics for manipulating the SOAP header has changed between axis1
and axis2.

I am having trouble finding documentation and sample code that
manipulates the

SOAP header obtained from a MessageContext.

 

From: Martin Gainty [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, August 13, 2008 8:43 PM
To: axis-user@ws.apache.org
Subject: RE: How to add a SOAP header in an axis2 custom client-side
handler?

 

didn't see your config params
axis2.xml
?

services.xml
  

Martin 
__ 
Disclaimer and confidentiality note 
Everything in this e-mail and any attachments relates to the official
business of Sender. This transmission is of a confidential nature and
Sender does not endorse distribution to any party other than intended
recipient. Sender does not necessarily endorse content contained within
this transmission. 





Subject: How to add a SOAP header in an axis2 custom client-side
handler?
Date: Wed, 13 Aug 2008 18:26:36 -0400
From: [EMAIL PROTECTED]
To: axis-user@ws.apache.org

I am trying to figure out how to add a SOAP header in my client-side
handler.

I have the following axis1 code, but need an axis2 equivalent:

 

 
/***

* Processes the header of a request message.  This method will add
the 

* session header to the outgoing request.

* 

* @param context the message context associated with the request

 
**/

   private void invokeRequest( MessageContext context ) throws AxisFault

   { 

  Message msg = context.getRequestMessage();

  if (msg == null)

 throw new AxisFault( "Message not in context." );



  SOAPEnvelope env = msg.getSOAPEnvelope();

 

  SessionHeaderType sessionHeader =
WebServiceClientHelper.getThreadSessionHeader( );

 

  SOAPHeaderElement header = new SOAPHeaderElement(HEADER_NS,

   HEADER_NAME,

   sessionHeader);

  env.addHeader(header);

   }

 

The SessionHeaderType class was generated from a wsdl and contains
session credentials.

 

Any pointers to appropriate documentation on how to manipulate headers,
or sample code, would be appreciated.

 



Your PC, mobile phone, and online services work together like never
before. See how Windows(r) fits your life
<http://clk.atdmt.com/MRT/go/108587394/direct/01/> 



RE: How to add a SOAP header in an axis2 custom client-side handler?

2008-08-13 Thread Martin Gainty

didn't see your config params
axis2.xml
?

services.xml
  

Martin 
__ 
Disclaimer and confidentiality note 
Everything in this e-mail and any attachments relates to the official business 
of Sender. This transmission is of a confidential nature and Sender does not 
endorse distribution to any party other than intended recipient. Sender does 
not necessarily endorse content contained within this transmission. 


Subject: How to add a SOAP header in an axis2 custom client-side handler?
Date: Wed, 13 Aug 2008 18:26:36 -0400
From: [EMAIL PROTECTED]
To: axis-user@ws.apache.org
















I am trying to figure out how to add a SOAP header in my
client-side handler.

I have the following axis1 code, but need an axis2 equivalent:

 

   /***

* Processes the header of a request message.  This method
will add the 

* session header to the outgoing request.

* 

* @param context the message context associated with the
request

**/

   private void invokeRequest( MessageContext context ) throws
AxisFault

   { 

  Message msg = context.getRequestMessage();

  if (msg == null)

 throw new AxisFault( "Message not in
context." );



  SOAPEnvelope env = msg.getSOAPEnvelope();

 

  SessionHeaderType sessionHeader =
WebServiceClientHelper.getThreadSessionHeader( );

 

  SOAPHeaderElement header = new
SOAPHeaderElement(HEADER_NS,

   HEADER_NAME,

  
sessionHeader);

  env.addHeader(header);

   }

 

The SessionHeaderType class was generated from a wsdl and
contains session credentials.

 

Any pointers to appropriate documentation on how to manipulate
headers, or sample code, would be appreciated.







_
Your PC, mobile phone, and online services work together like never before.
http://clk.atdmt.com/MRT/go/108587394/direct/01/

How to add a SOAP header in an axis2 custom client-side handler?

2008-08-13 Thread Franklin, Allen
I am trying to figure out how to add a SOAP header in my client-side
handler.

I have the following axis1 code, but need an axis2 equivalent:

 

 
/***

* Processes the header of a request message.  This method will add
the 

* session header to the outgoing request.

* 

* @param context the message context associated with the request

 
**/

   private void invokeRequest( MessageContext context ) throws AxisFault

   { 

  Message msg = context.getRequestMessage();

  if (msg == null)

 throw new AxisFault( "Message not in context." );



  SOAPEnvelope env = msg.getSOAPEnvelope();

 

  SessionHeaderType sessionHeader =
WebServiceClientHelper.getThreadSessionHeader( );

 

  SOAPHeaderElement header = new SOAPHeaderElement(HEADER_NS,

   HEADER_NAME,

   sessionHeader);

  env.addHeader(header);

   }

 

The SessionHeaderType class was generated from a wsdl and contains
session credentials.

 

Any pointers to appropriate documentation on how to manipulate headers,
or sample code, would be appreciated.



Re: Example of setting client side handler?

2005-05-09 Thread Tom Ziemer
Hi Vjeran,
I'm sorry but I cannot really help you. I *think* it should work, though 
you might have to create new calls in your threads before invoking the 
service. Couldn't you just write some test cases to figure out, whether 
or not you get the same call instance?

Sorry - I know that wasn't very helpful,
Regards,
Tom
Vjeran Marcinko wrote:
Hi Tom.
I hope you could answer this since I'm so tired of searching the web for
answer (I've been doing it for days now), although I find it very strange
because I need very common stuff, and strangely nobody gave me suitable
answer...
Client stubs in general are singletons, meaning, I don't instantiate new one
during each call, but all simultaneous client threads can use it
concurrently. Meaning, client stubs are thread-safe, and all client see is
just stub's service interface.
Meaning, following piece of code (stub instantiation) is usually executed
during *container startup* :
FooServiceLocator fooServiceLocator = new FooServiceLocator();
FooPort fooPort = fooServiceLocator.getFooPort(...url...);
...and later, all threads just access this single instance "fooPort"
concurrently whenever they need to perform remote action in a form:
fooPort.doSomeAction();
But, since every simultaneous call to this action can contain different
attachments/usernames/passwords, I would need something like:
fooPort.doSomeAction(attachments, username, password);
But, since it would be changing of service interface, which is not possible,
there has to be some concurrent way to achieve this (usually it's some
ThreadLocal way when one needs to pass context values not described by
method signature).
My question is - since all these values (attachments, username...) can be
set on Call instance, if I fetch this Call by :
Call call = ((Stub)fooPort).getCall();
call.setAttachments(attachments)
before I call :
fooPort.doSomeAction();
is this gonna be OK ? If concurrent thread fetches the same Call instance
that it's all no good.
-Vjeran
- Original Message - 
From: "Tom Ziemer" <[EMAIL PROTECTED]>
To: 
Sent: Monday, May 09, 2005 3:02 PM
Subject: Re: Example of setting client side handler?


Hi,
I'm not sure I understand you correctly - do you want to access the the
call using an ant-generated stub? If that's the case, you can try this:
FooServiceLocator fooServiceLocator = new FooServiceLocator();
FooServiceSoapBindingStub fooServiceStub = null;
try
{
fooServiceStub = (FooServiceSoapBindingStub)
fooServiceLocator.getFooService();
// getting the call:
Call call = fooServiceStub._getCall();
// username
fooServiceStub.setUserName("Dunno");
...
}
...
Hope this helps,
Regards,
Tom





Re: Example of setting client side handler?

2005-05-09 Thread Vjeran Marcinko
Hi Tom.

I hope you could answer this since I'm so tired of searching the web for
answer (I've been doing it for days now), although I find it very strange
because I need very common stuff, and strangely nobody gave me suitable
answer...

Client stubs in general are singletons, meaning, I don't instantiate new one
during each call, but all simultaneous client threads can use it
concurrently. Meaning, client stubs are thread-safe, and all client see is
just stub's service interface.

Meaning, following piece of code (stub instantiation) is usually executed
during *container startup* :
FooServiceLocator fooServiceLocator = new FooServiceLocator();
FooPort fooPort = fooServiceLocator.getFooPort(...url...);

...and later, all threads just access this single instance "fooPort"
concurrently whenever they need to perform remote action in a form:
fooPort.doSomeAction();

But, since every simultaneous call to this action can contain different
attachments/usernames/passwords, I would need something like:
fooPort.doSomeAction(attachments, username, password);

But, since it would be changing of service interface, which is not possible,
there has to be some concurrent way to achieve this (usually it's some
ThreadLocal way when one needs to pass context values not described by
method signature).

My question is - since all these values (attachments, username...) can be
set on Call instance, if I fetch this Call by :
Call call = ((Stub)fooPort).getCall();
call.setAttachments(attachments)
before I call :
fooPort.doSomeAction();

is this gonna be OK ? If concurrent thread fetches the same Call instance
that it's all no good.

-Vjeran

- Original Message - 
From: "Tom Ziemer" <[EMAIL PROTECTED]>
To: 
Sent: Monday, May 09, 2005 3:02 PM
Subject: Re: Example of setting client side handler?


> Hi,
>
> I'm not sure I understand you correctly - do you want to access the the
> call using an ant-generated stub? If that's the case, you can try this:
>
> FooServiceLocator fooServiceLocator = new FooServiceLocator();
> FooServiceSoapBindingStub fooServiceStub = null;
> try
> {
> fooServiceStub = (FooServiceSoapBindingStub)
> fooServiceLocator.getFooService();
> // getting the call:
> Call call = fooServiceStub._getCall();
> // username
> fooServiceStub.setUserName("Dunno");
> ...
> }
> ...
>
> Hope this helps,
>
> Regards,
> Tom
>
>



-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.5 - Release Date: 4.5.2005



Re: Example of setting client side handler?

2005-05-09 Thread Tom Ziemer
Hi,
I'm not sure I understand you correctly - do you want to access the the 
call using an ant-generated stub? If that's the case, you can try this:

FooServiceLocator fooServiceLocator = new FooServiceLocator();
FooServiceSoapBindingStub fooServiceStub = null;
try
{
	fooServiceStub = (FooServiceSoapBindingStub) 
fooServiceLocator.getFooService();
	// getting the call:
	Call call = fooServiceStub._getCall();
	// username
	fooServiceStub.setUserName("Dunno");
...
}
...

Hope this helps,
Regards,
Tom

Vjeran Marcinko wrote:
Thanx Dan, though it doesn't help me.
I really need a way to set attachments, or sername and password, but *when
using generated classes from WSLD*. There are many examples around, but only
for low level usage with Call objects, but I don't see a way to fetch Call
instance at all when working with generated classes. Here's an example:
FooServiceLocator fooServiceLocator = new FooServiceLocator();
FooPort fooPort = fooServiceLocator.getFooPort(...url...);
fooPort.doSomeAction();
How can I get Call instance for this call above?
-Vjeran
- Original Message - 
From: "Dan O'Neill" <[EMAIL PROTECTED]>
To: 
Sent: Monday, May 09, 2005 1:20 PM
Subject: Re: Example of setting client side handler?

Is this question about using client side handlers or using them to add
attachments to outgoing soap messages? Well if its the former look
below, if its the latter, I cant remember the code for adding
attachments straight of the top of my head though there a few examples
on the web...
Client side handlers can only be invoked through code... or thats what
seems to be the consenus here...
In java first you have to create an object of your handler. So if your
request handler is called loghandler then:
loghandler log = new loghandler();
Then if your using Dynamic invocation its just
call.setclientHandlers(log,null)
Its similar for response handlers too.
Sorry if this has no bearing on your project... Just hope to point you
in the right direction
Dan
On 5/9/05, Vjeran Marcinko <[EMAIL PROTECTED]> wrote:
Hi.
I think that answer to my question - how to set attacments before calling
some action on WSLD2Java-gnerated stub, can lie in client handlers, but
unfortunately, documentation isn't still available :
http://ws.apache.org/axis/java/client-side-axis.html#ConfiguringClient-sideHandlers
So, can someone give me some example ?
-Vjeran
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.5 - Release Date: 4.5.2005





Re: Example of setting client side handler?

2005-05-09 Thread Vjeran Marcinko
Thanx Dan, though it doesn't help me.
I really need a way to set attachments, or sername and password, but *when
using generated classes from WSLD*. There are many examples around, but only
for low level usage with Call objects, but I don't see a way to fetch Call
instance at all when working with generated classes. Here's an example:

FooServiceLocator fooServiceLocator = new FooServiceLocator();
FooPort fooPort = fooServiceLocator.getFooPort(...url...);
fooPort.doSomeAction();

How can I get Call instance for this call above?

-Vjeran

- Original Message - 
From: "Dan O'Neill" <[EMAIL PROTECTED]>
To: 
Sent: Monday, May 09, 2005 1:20 PM
Subject: Re: Example of setting client side handler?


Is this question about using client side handlers or using them to add
attachments to outgoing soap messages? Well if its the former look
below, if its the latter, I cant remember the code for adding
attachments straight of the top of my head though there a few examples
on the web...

Client side handlers can only be invoked through code... or thats what
seems to be the consenus here...

In java first you have to create an object of your handler. So if your
request handler is called loghandler then:

loghandler log = new loghandler();

Then if your using Dynamic invocation its just
call.setclientHandlers(log,null)

Its similar for response handlers too.

Sorry if this has no bearing on your project... Just hope to point you
in the right direction

Dan


On 5/9/05, Vjeran Marcinko <[EMAIL PROTECTED]> wrote:
> Hi.
>
> I think that answer to my question - how to set attacments before calling
> some action on WSLD2Java-gnerated stub, can lie in client handlers, but
> unfortunately, documentation isn't still available :
>
http://ws.apache.org/axis/java/client-side-axis.html#ConfiguringClient-sideHandlers
>
> So, can someone give me some example ?
>
> -Vjeran
>
> --
> No virus found in this outgoing message.
> Checked by AVG Anti-Virus.
> Version: 7.0.308 / Virus Database: 266.11.5 - Release Date: 4.5.2005
>
>



-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.5 - Release Date: 4.5.2005



Re: Example of setting client side handler?

2005-05-09 Thread Dan O'Neill
Is this question about using client side handlers or using them to add
attachments to outgoing soap messages? Well if its the former look
below, if its the latter, I cant remember the code for adding
attachments straight of the top of my head though there a few examples
on the web...

Client side handlers can only be invoked through code... or thats what
seems to be the consenus here...

In java first you have to create an object of your handler. So if your
request handler is called loghandler then:

loghandler log = new loghandler();

Then if your using Dynamic invocation its just call.setclientHandlers(log,null)

Its similar for response handlers too.

Sorry if this has no bearing on your project... Just hope to point you
in the right direction

Dan


On 5/9/05, Vjeran Marcinko <[EMAIL PROTECTED]> wrote:
> Hi.
> 
> I think that answer to my question - how to set attacments before calling
> some action on WSLD2Java-gnerated stub, can lie in client handlers, but
> unfortunately, documentation isn't still available :
> http://ws.apache.org/axis/java/client-side-axis.html#ConfiguringClient-sideHandlers
> 
> So, can someone give me some example ?
> 
> -Vjeran
> 
> --
> No virus found in this outgoing message.
> Checked by AVG Anti-Virus.
> Version: 7.0.308 / Virus Database: 266.11.5 - Release Date: 4.5.2005
> 
>


Example of setting client side handler?

2005-05-09 Thread Vjeran Marcinko
Hi.

I think that answer to my question - how to set attacments before calling
some action on WSLD2Java-gnerated stub, can lie in client handlers, but
unfortunately, documentation isn't still available :
http://ws.apache.org/axis/java/client-side-axis.html#ConfiguringClient-sideHandlers

So, can someone give me some example ?

-Vjeran



-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.5 - Release Date: 4.5.2005