2.1 Documentation

12 views
Skip to first unread message

Bayard Randel

unread,
Aug 15, 2010, 9:58:59 PM8/15/10
to Google Web Toolkit
Hi there,

Is there any preliminary documentation around the new features in 2.1,
particularly the MVP implementation? I'm going to be starting a large
GWT project shortly, but am somewhat hesitant to get started knowing
that official support for MVP is forthcoming.

Many thanks

Christian Goudreau

unread,
Aug 17, 2010, 9:31:10 AM8/17/10
to google-we...@googlegroups.com
Then, you can consider using Gwt-Platform, even Gwt MVP support won't be as complete as what we offer inside Gwt-Platform. Moreover, we don't want to replace what will be offered inside GWT, we want to gives you the best of it. Some of the feature bundled inside of the framework: MVP with history support and CodeSplitting, command pattern, auto generation tools for boiler plate code (in code review) and more !

You can find more informations:

Cheers,


--
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-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.




--
Christian Goudreau

Thomas Broyer

unread,
Aug 17, 2010, 11:40:45 AM8/17/10
to Google Web Toolkit
See https://wave.google.com/wave/waveref/googlewave.com/w+eva-sERfA

There are other waves that could interest you, about Cell widgets,
Validation, RequestFactory, etc.
See https://wave.google.com/wave/waveref/googlewave.com/w+A-PZdxsLN as
a starting point
And the JavaDoc is here: http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/index.html

marius.andreiana

unread,
Aug 17, 2010, 2:53:59 PM8/17/10
to Google Web Toolkit
Adding to Thomas' notes:
MVP articles here http://code.google.com/webtoolkit/articles.html
(concepts, not really 2.1 implementation)


On Aug 17, 6:40 pm, Thomas Broyer <t.bro...@gmail.com> wrote:
> On 16 août, 03:58, Bayard Randel <k...@bestpractice.org.nz> wrote:
>
> > Hi there,
>
> > Is there any preliminary documentation around the new features in 2.1,
> > particularly the MVP implementation? I'm going to be starting a large
> > GWT project shortly, but am somewhat hesitant to get started knowing
> > that official support for MVP is forthcoming.
>
> Seehttps://wave.google.com/wave/waveref/googlewave.com/w+eva-sERfA

David Chandler

unread,
Aug 18, 2010, 9:08:35 AM8/18/10
to Google Web Toolkit
The design waves Thomas referenced (thank you, Thomas) are shared with
members of the google-web-toolkit-contributors group, which is the
best place to participate in ongoing development of the MVP features
in 2.1.

Expect documentation on 2.1 MVP to begin appearing with 2.1M4 and full
docs to be available with the 2.1 release.

/dmc
David Chandler
Google Web Toolkit Team

On Aug 17, 11:40 am, Thomas Broyer <t.bro...@gmail.com> wrote:
> On 16 août, 03:58, Bayard Randel <k...@bestpractice.org.nz> wrote:
>
> > Hi there,
>
> > Is there any preliminary documentation around the new features in 2.1,
> > particularly the MVP implementation? I'm going to be starting a large
> > GWT project shortly, but am somewhat hesitant to get started knowing
> > that official support for MVP is forthcoming.
>
> Seehttps://wave.google.com/wave/waveref/googlewave.com/w+eva-sERfA

Aldo

unread,
Sep 29, 2010, 3:11:14 PM9/29/10
to Google Web Toolkit
My only question is: when will GWT 2.1 M4 be available? And when will
it be released (the GA)? It seems like the due dates are always being
updated and we all we can do is wait until we get it. I'm about to
start an enterprise project and I chose GWT 2.1 because of the
promises, but apparently it was a poor choice. I knew I'd start it
around October but now until when I'll have to wait to get the final
release?

Thanks

On Aug 18, 10:08 am, David Chandler <drfibona...@google.com> wrote:
> The design waves Thomas referenced (thank you, Thomas) are shared with
> members of the google-web-toolkit-contributors group, which is the
> best place to participate in ongoing development of the MVP features
> in2.1.
>
> Expect documentation on2.1MVP to begin appearing with2.1M4and full

Daniel Kurka

unread,
Sep 29, 2010, 6:18:28 PM9/29/10
to google-we...@googlegroups.com
I just started to take a look on GWT 2.1m3 and MVP and made a small blog post about it.

Maybe this will help?

Thomas Broyer

unread,
Sep 29, 2010, 8:05:42 PM9/29/10
to Google Web Toolkit


On 30 sep, 00:18, Daniel Kurka <kurka.dan...@googlemail.com> wrote:
> I just started to take a look on GWT 2.1m3 and MVP and made a small blog
> post about it.
>
> Maybe this will help?
>
> http://blog.daniel-kurka.de/2010/09/testdriving-gwt-mvp-from-gwt-21-m...

Could you please switch your blog to english? I was able to figure out
what "Vorschau" means only because I've recently commented on other
Blogger blogs.

Looking forward to read the next blog post!

(note that your SimpleDisplay won't be needed in 2.1m4 as SimplePanel
implements AcceptsOneWidget –the new name for Activity.Display–; also,
views generally will be widgets themselves, rather than contain
widgets, again this is made a bit easier in 2.1m4 as Widget implements
IsWidget, returning itself, so you don't have to write the asWidget
method if your view is a Widget)

Daniel Kurka

unread,
Sep 30, 2010, 2:14:27 AM9/30/10
to google-we...@googlegroups.com
I'm sorry about the blog not being in english :)

Thanks for the hint on SimplePanel. I`m gonna keep this in mind once m4 arrives.

2010/9/30 Thomas Broyer <t.br...@gmail.com>

--

Ashton Thomas

unread,
Sep 30, 2010, 9:22:36 AM9/30/10
to Google Web Toolkit
I am putting together documentation for my own project and will have
another copy that is the same but intended to post to everyone. Below
are some details on what I will be putting together over the next
month. If anyone is interested in helping compile a good starting
point that will be ready about the time of GWT 2.1 release, please
feel free to contact me.

I will be giving a GWT seminar in late November at Carnegie Mellon to
hopefully gauge the GWT interest and promote GWT-based development on
CMU campus. I am keeping track of the changes going on with 2.1
development but may have some gaps here and there. I am fairly new to
this type of development so if someone wanted to help out and fill in
the gaps and make corrections where I go wrong that would be great


Desktop Apps in the Browser w/GWT 2.1
Google-Web-Toolkit

*Tuesday, November 30th (tentative)

The power of AJAX Technologies when the Front-end complexity is
abstracted

Application Architecture Best Practices & Implementations

- Model-View-Presenter (MVP)
o Implementation using “Activities”, etc
- EventBus & The Command Pattern
- Dependency Injection (in client code) & The Factory Pattern
- Data Synchronization using “RequestFactory”
- History Management (Keeping the “Back” button)
- Decoupling UI’s
- DTO’s, Domains, & Databases
- Foundation:
o Java
o Spring
o Guice / Gin
o Maven


Outline: To-Do

“Zero to Enterprise in 60 Minutes with GWT” (60 minutes may actually
be 25 hours...)

GWT is a compiler so you can build your app anyway you want and just
have it compiled into a front-end/client application. However, this
seminar is going to outline a few best practices as to how to
structure and architect you application to take full advantage of GWT
and provide very complex/large applications

-Setting up your dev environment / getting started
-High Lever Stuff
-Lower level Implementation stuff
-Appendix stuff that details out of scope topics and links/resources/
etc


On Sep 30, 2:14 am, Daniel Kurka <kurka.dan...@googlemail.com> wrote:
> I'm sorry about the blog not being in english :)
>
> Thanks for the hint on SimplePanel. I`m gonna keep this in mind once m4
> arrives.
>
> 2010/9/30 Thomas Broyer <t.bro...@gmail.com>
>
>
>
>
>
> > On 30 sep, 00:18, Daniel Kurka <kurka.dan...@googlemail.com> wrote:
> > > I just started to take a look on GWT 2.1m3 and MVP and made a small blog
> > > post about it.
>
> > > Maybe this will help?
>
> > >http://blog.daniel-kurka.de/2010/09/testdriving-gwt-mvp-from-gwt-21-m...
>
> > Could you please switch your blog to english? I was able to figure out
> > what "Vorschau" means only because I've recently commented on other
> > Blogger blogs.
>
> > Looking forward to read the next blog post!
>
> > (note that your SimpleDisplay won't be needed in 2.1m4 as SimplePanel
> > implements AcceptsOneWidget –the new name for Activity.Display–; also,
> > views generally will be widgets themselves, rather than contain
> > widgets, again this is made a bit easier in 2.1m4 as Widget implements
> > IsWidget, returning itself, so you don't have to write the asWidget
> > method if your view is a Widget)
>
> > --
> > 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-we...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-tool...@googlegroups.com<google-web-toolkit%2Bunsubs cr...@googlegroups.com>
> > .

Duong BaTien

unread,
Sep 30, 2010, 10:03:18 AM9/30/10
to google-we...@googlegroups.com
Hi Ashton:

This sounds useful to many. Please give a URL of your updated progress.

Duong BaTien
DBGROUPS and BudhNet

Jeff Larsen

unread,
Sep 30, 2010, 10:23:07 AM9/30/10
to Google Web Toolkit
What is the reason for IsWidget only returning the widget and not
having all of the public methods available to widget?

One thing I've done for a new project I'm starting on is writing an
interface that exposes every public method on every class, mirroring
the gwt class hierarchy. That way I could pass an IsButton back to my
presenter and have access to all public methods on button instead of
having to expose HasClickHandlers, HasFocusHandlers, HasText.... as
separate methods or a really ugly generic.

As an added benefit, if I use providers from Gin, I can inject
providers for those widgets and then create them on demand inside my
presenter should I need to.

Thomas Broyer

unread,
Oct 1, 2010, 6:36:04 AM10/1/10
to Google Web Toolkit


On Sep 30, 4:23 pm, Jeff Larsen <larse...@gmail.com> wrote:
> What is the reason for IsWidget only returning the widget and not
> having all of the public methods available to widget?

The IsWidget is only there so you can mock the view without any
dependency on Widget. In your unit tests you can then check whether
the IsWidget is null or is the object you're expecting, but you don't
really care what it does (this is left to the view interfaces, which
will likely extend IsWidget).

The typical ussage is:

interface MyView extends IsWidget {
interface Delegate {
onFoo();
}

void setDelegate(Delegate delegate);
}

class MyActivity implements Activity, MyView.Delegate {
@Inject MyView view;

public void start(AcceptsOneWidget panel, EventBus eventBus) {
view.setDelegate(this);
doAsyncStartup(new WhateverCallback() {
public void onSuccess() {
if (view == null) {
// we've been cancelled!
return;
}
...
panel.setWidget(view);
}
});
}

public void onCancel() {
view.setDelegate(null);
view = null; // serves as a flag to know if we're still active
}

public void onStop() {
// same as in onCancel, possibly more
}

public String mayStop() { ... }
}

With doAsyncStartup generally being a GWT-RPC, RequestFactory or
RequestBuilder call, and WhateverCallback the appropriate callback
interface (AsyncCallback, Receiver or RequestCallback)

(if you annotate the View interface with @ImplementedBy, you don't
even need to explicitly configure anything in GIN)

Jeff Larsen

unread,
Oct 1, 2010, 10:33:08 AM10/1/10
to Google Web Toolkit
From what I'm reading in your post is that the recommended way of
doing MVP is to pass the presenter to the view. This isn't how MVP is
done with the other MVP frameworks(mvp4g, gwtp), and even if the new
Activity mechanism is the go forward strategy for GWT proper, I would
really like to see is something to fix all the boilerplate if you're
trying to pass your view to the Activity.

I have a presenter a view and an interface which that view implements,
lets call it a display.
Now lets say I need to add a click handler, focus handler, enable,
disable and change the text of the one particular button. In my
interface and view I have to expose 5 different methods.

HasText getButtonText();

HasClickHandlers getButtonHasClickHandlers();

HasAllFocusHandlers getButtonHasAllFocusHandlers();

void setButtonEnabled(boolean isEnabled);

boolean isButtonEnabled();

then in my view

public HasText getButtonText(){
return button;
}
public HasClickHandlers getButtonHasCLickHandlers(){

return button;
}
public HasAllFocusHandlers getButtonFocusHandlers(){

return button;
}
public void setButtonEnabled(boolean enable){
button.setEnabled(enable);
}

public void isButtonEnabled(){
return button;
}

This sucks. It is verbose, long and destroys productivity as every
time some requirement gets changed or added I have to now go make more
methods in the display. You can imagine how this would explode into
some really long and unweildy interfaces for complex forms where each
field can be enabled/disabled based upon business logic.


Obviously this is smaller and more concise.

display

IsButton getButton();

view

public IsButton getButton(){
return button;
}

where IsButton is an interface that exposes all the public methods
available on Button. Now as requirements change I already have access
to every method I would if I was doing development inside the view
itself.

This is for one button on one form. It would be so much easier if
Button implemented an interface IButton and then instead of having to
write 5 methods on button then write all the boiler plate. Maybe the
answer isn't having IsWidget expose all public methods on Widget, but
perhaps another interface, call it IWidget or WidgetInterface, then
each UI component would follow the same convention. If it would stand
a reasonable chance of being accepted, I would be happy to code a
patch for this aswell.

For my current project, I've already extended the entire GWT widget
heirarchy to do exactly this. I'm already seeing big gains in my
productivity, but I would prefer to have these changes integrated into
GWT proper as I think that would make GWT a lot easier to use.

Thomas Broyer

unread,
Oct 1, 2010, 11:07:21 AM10/1/10
to Google Web Toolkit


On Oct 1, 4:33 pm, Jeff Larsen <larse...@gmail.com> wrote:
> From what I'm reading in your post is that the recommended way of
> doing MVP is to pass the presenter to the view. This isn't how MVP is
> done with the other MVP frameworks(mvp4g, gwtp),

Note that GWT-P recently added the notion of "UI handlers"
http://arcbees.wordpress.com/2010/09/03/reversing-the-mvp-pattern-and-using-uihandler/

As for the rest, I for one don't miss IButton and the like interfaces.
YMMV.

Tommy Lui

unread,
Oct 1, 2010, 2:50:00 PM10/1/10
to Google Web Toolkit
Why is Chris Ramsdale (Google's Developer Relations team to develop
and advocate GWT best practices) in the middle of writing a book about
GWT 2.1 when there's no documentation available online except for
Thomas blogs and a few Waves.

http://www.manning.com/bambury/

I hope I'm not the only one angry about this? I'd love to hear other
peoples thoughts.

Personally I feel he should be advocating some documentation for
developers instead of hording it for his own book, after all he's on
the GWT team.

As a member of the GWT community, I think if there's enough
information for Chris to write a 500 page book, why have we seen no
official documentation on the GWT website about GWT 2.1 for developers
like me.

The book is due to be release in early 2011, so I'm sure its GWT 2.1
not GWT 2.0

Please help me understand

Chris Ramsdale

unread,
Oct 6, 2010, 8:01:02 PM10/6/10
to google-we...@googlegroups.com
Aldo, we're still on track for a release in the Oct. timeframe. Is there some other aspect that makes it a poor choice?

--
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-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.

Flemming Boller

unread,
Oct 7, 2010, 2:30:00 AM10/7/10
to google-we...@googlegroups.com
Hi  Aldo


Why is it so important for you to start a project with the "GA - release" ?


Normally enterprise projects are have quite a big development time, so the
GA release could properly be avaiable before you enter the first testphase.

We are currently running with 2.1M3 in production, and have found 0 errrors
that can be "blaimed" to the GWT. We are also a rather big enterprise project. 

I think the quality is very good and the bikeshed examples are good "learning places".

What can you take from me?   We have good experience with 2.1M3...I think google code quality is very good even though they call i M3.

Is it good enough for you?   That is of course for you to decide.


Hope you can use my input.


Regards
Fleming


Goby

unread,
Oct 12, 2010, 12:38:45 AM10/12/10
to Google Web Toolkit

Gal Dolber

unread,
Oct 12, 2010, 1:13:59 PM10/12/10
to google-we...@googlegroups.com
Thanks a lot!

--
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-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.




--
Guit: Elegant, beautiful, modular and *production ready* gwt applications.

http://code.google.com/p/guit/




Reply all
Reply to author
Forward
0 new messages