Extending WAModelProxy to handle the proxying of methods with 2 or more arguments..

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Extending WAModelProxy to handle the proxying of methods with 2 or more arguments..

Rick Flower
I ran into a short coming of the existing WAModelProxy code, specifically against :

WAModelProxy>>doesNotUnderstand: aMessage
        ^ aMessage selector isUnary
                ifTrue: [self performRead: aMessage selector]
                ifFalse:
                        [(aMessage selector isKeyword and: [aMessage arguments size = 1])
                                ifTrue: [self performWrite: aMessage selector allButLast with: aMessage argument]
                                ifFalse: [super doesNotUnderstand: aMessage]]

In this case, I'm not completely following what the "allButLast" and the rest of the methods
in the above "IfTrue:" block are doing as they appear to be doing byte code sorts of stuff..
Anyone care to steer me in the right direction such that this method can handle methods that
look something like :

MyClass>>UpdateMyArrayAt: myIndex with: myValue

Many thanks in advance!

-- Rick
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside