On Thu, Sep 1, 2011 at 12:13 PM, Marc Puts
<[email protected]> wrote:
>

> I think you might be trying to do it backwards?! If you're trying to add
> two parameters to your own callSync function, you can do something like
> this:
>
> qx.Class.define("qxwebapp.rpc.Rpc",
> {
>   extend : qx.io.remote.Rpc,
>   members :
>   {
>     callSync: function(methodName) {
>       this.setUsername('john');
>       this.setPassword('password');
>       this.base(arguments, methodName);
>    }
>   }
> });
>
>

I am trying to have my function not take the args, but rather add them
to the superclass method

I want all my rpc calls to automatically have name and password pased,
so i don't have to do it on every line where I do a rpc.  Since
realizing argumetns is a javascript thing, I have been able to find
what I need.  Thanks.

>
qx.Class.define("qxwebapp.rpc.Rpc",
{
  extend : qx.io.remote.Rpc,
  members :
  {
    uname : null,
    passwd: null,
    callAsync: function(handler, methodName){
        [].push.apply(arguments,['john','password']);
        return arguments.callee.base.apply(this, arguments);
   },
    callSync: function(methodName){
        [].push.apply(arguments,['john','password']);
        return arguments.callee.base.apply(this, arguments);
   }

  }
});

------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to