Martin,

For really simple example you can see here:

http://itsp.typepad.com/voip/2009/07/gwt-implementing-rpc-command-pattern-on-server.html

At the end, you will need to add some more code, but you can see how
the pattern works (it helped me!)

Herme



On Jul 5, 10:16 am, martinhansen <martin.hanse...@googlemail.com>
wrote:
> Hello David,
>
> I've read your source code and your example. It is very interesting.
> But although it's short and simple, I still don't understand it.
> Especially "GIN" and "GUICE" confuses me a lot. Can I use your example
> without these technologies?
>
> Does anyone know a really simple example? The example in Ray's sheet
> is interesting and simple, but incomplete. Where does the actual
> action take place in his example, let's say, querying some contact
> details from a remote data base? I think this important part is
> missing.
> The ContactService defines a method called "execute", but where is
> this method implemented? Is it implemented automatically by some
> mechanism? If yes, how is it done? Is "execute" the only method in the
> interface I ever need, e.g. some kind of place holder?
>
> Any help would be greatly appreciated.
>
> On 5 Jul., 08:17, David Peterson <da...@randombits.org> wrote:
>
>
>
> > Hi Nathan,
>
> > On Jul 5, 2:15 am, Nathan Wells <nwwe...@gmail.com> wrote:
>
> > > I updated my project to only use the two interfaces as suggested by
> > > David. Instead of using actionhandlers and registering them, I created
> > > an annotation for the IRemoteProcedureCall implementations that
> > > contains the canonical class name of the IProcedure that is to be run
> > > on the server.
>
> > As you say, one of the downsides of linking the handler to the
> > concrete implementation is that there may be issues with the GWT
> > compiler. That said, in general it seems to mostly ignore attributes,
> > so it may not be an issue.
>
> > The other downside for me is that it ties the action interface to a
> > specific implementation. This makes it more difficult to write mocks
> > for tests, etc. Having them configured purely on the server-side means
> > you can replace them with whatever you like on in test scenarios. Or,
> > if you want to provide alternate implementations (eg. JDO vs
> > Hibernate), you can have both in your app and just switch between them
> > by changing your DI configuration.
>
> > The downside of my method is that you may forget to actually implement
> > the handler. Of course, this will generally show up pretty quickly
> > when you try to actually use it. And I guess it's still quite easy to
> > forget to supply the annotation anyway...
>
> > David

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to