[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Soap add_method

jmazzi

2/22/2007 8:25:00 PM

Is there a way to set default arguments for soap methods?

i.e.

proxy.add_method('value1','value2'='something')



I need to pass a long a username and password with each soap call.
please let me know, thanks!

--
Posted via http://www.ruby-....

2 Answers

jmazzi

2/22/2007 8:28:00 PM

0

Justin Mazzi wrote:
> Is there a way to set default arguments for soap methods?
>
> i.e.
>
> proxy.add_method('value1','value2'='something')
>
>
>
> I need to pass a long a username and password with each soap call.
> please let me know, thanks!

I would also like to add, this is not Basic auth(http auth). This is
simple passing a variable called username and password with each call.

--
Posted via http://www.ruby-....

Chris Carter

2/22/2007 10:18:00 PM

0

On 2/22/07, Justin Mazzi <jmazzi@gmail.com> wrote:
> Is there a way to set default arguments for soap methods?
>
> i.e.
>
> proxy.add_method('value1','value2'='something')
>
>
>
> I need to pass a long a username and password with each soap call.
> please let me know, thanks!
>
> --
> Posted via http://www.ruby-....
>
>
Hi Justin, I don't know exactly how SOAP4R handles this, but you could
add the method normally, and writte a wrapper to call the method with
the attributes:
class << soap_object
def really_cool_method(*args)
self.cool_method(:value1 => "blah, args)
end
end

--
Chris Carter
concentrationstudios.com
brynmawrcs.com