Google Web toolkit

Loading...

Flash Player 9 (or above) is needed to view presentations.
We have detected that you do not have it on your computer. To install it, go here.

0 comments

Post a comment

    Post a comment
    Embed Video
    Edit your comment Cancel

    4 Favorites

    Google Web toolkit - Presentation Transcript

    1. Building Ajax Applications with the Google Web Toolkit Vivek Prahlad
    2. Agenda
        • What is the Google Web Toolkit?
        • Features
        • Architectural issues with AJAX applications
          • And how the GWT handles them
        • Experience report:
          • What went well?
          • Gotchas
        • Lots of demos
    3. What is the GWT?
        • A UI framework for building Ajax apps in Java
          • Best suited for one page Ajax apps
          • Can be embedded into existing apps as well
          • Open Source (Apache 2 license)
        • Component based programming model
          • Similar to, but simpler than Swing / SWT
          • Control application appearance via CSS
        • Simple RPC framework
    4. Source: Adaptive Path How are Ajax apps different?
    5. Source: Adaptive Path
    6. Source: Adaptive Path
    7. Demo: Hello World
    8. Developing applications
        • Client side code: Java + GWT UI library
          • Restriction: subset of the JDK – java.lang, java.util
          • Compiled to javascript. Morfik, Script# are similar
        • Server side code: GWT RPC + usual suspects
          • Spring & Hibernate
          • Can send domain layer classes over the wire
          • Need to implement IsSerializable
          • Compiled to bytecode as usual
    9. Features
        • Component based framework
        • Browser support: IE6+, Firefox, Mozilla, Safari, Opera
          • No Konqueror support
        • Internationalization
        • Debugging
        • Browser history management
        • Integrate with javascript libraries via JSNI
        • JUnit integration
    10. Demo: More Examples
    11. Architectural Issues?
        • Back button support?
          • Handled by the browser
        • Session state?
          • All on the client, not a server issue
        • UI event handling?
          • All on the client, no round trip
        • Deployment?
          • Compiled Javascript code, java on server side
    12. Answers to a few Ajax headaches
        • History?
          • Handled by the History class
        • Cross browser support?
          • Abstract DOM class
        • RPC?
          • Java based RPC mechanism
    13. Building Widgets
        • Build new widgets from existing ones
        • Style with CSS
          • No, your app doesn't have to look like Gmail!
          • Layout with panels
    14. Testing
        • Sahi ( http://sahi.co.in ) for functional testing
        • Unit testing via the GWTTestCase
          • Same restrictions as with UI code
          • MVC is your friend
          • Use GWTTestcase for the view
          • Test the Model and Controller as usual
    15. What went well?
        • Truly cross-browser
        • App needed 2 lines of custom javascript
          • For disabling text selection
        • Great component model
          • Easy to build custom components from scratch
        • Java to Javascript compiler works like a charm
        • No memory leaks
        • Break up large apps with modules & IFrames
    16. Gotchas
        • RPC mechanism works only with GWT clients
        • Some widgets use HTML tables internally
          • CSS for layout faster, but more challenging
        • Table widget support weak
          • No MVC separation
    17. Gotchas
        • Need to be careful about client side state
          • Ajax apps usually long lived – memory leaks can kill you
        • Some widgets need a lot of custom HTML
          • Tree widget biggest offender
        • Need to replace hibernated objects before serializing
          • Replace PersistentSet, PersistentList with HashSet, ArrayList
    18. Resources
        • http://code.google.com/webtoolkit
        • http://groups.google.com/Google-Web-Toolkit
        • http://www.adaptivepath.com/publications/essays/archives/000385.php
    19. Questions?

    + gnunifygnunify, 3 years ago

    custom

    1905 views, 4 favs, 1 embeds more stats

    AJAX, at its best using the Google Web Toolkit

    More info about this document

    © All Rights Reserved

    Go to text version

    • Total Views 1905
      • 1904 on SlideShare
      • 1 from embeds
    • Comments 0
    • Favorites 4
    • Downloads 0
    Most viewed embeds
    • 1 views on http://www.blogger.com

    more

    All embeds
    • 1 views on http://www.blogger.com

    less

    Flagged as inappropriate Flag as inappropriate
    Flag as inappropriate

    Select your reason for flagging this presentation as inappropriate. If needed, use the feedback form to let us know more details.

    Cancel
    File a copyright complaint
    Having problems? Go to our helpdesk?

    Categories