Java Google Web Toolkit-GWT

15
Google Web Toolkit By Kaushik Sahoo Mindfire Solutions Date: Oct 30, 2013

description

All About GWT - A set of tools for building AJAX apps in the Java language.

Transcript of Java Google Web Toolkit-GWT

Page 1: Java Google Web Toolkit-GWT

Google Web ToolkitBy

Kaushik Sahoo

Mindfire SolutionsDate: Oct 30, 2013

Page 2: Java Google Web Toolkit-GWT

What is GWT?

A set of tools for building AJAX apps in the Java language

Write, run, test, and debug in Java

Is it a compiler?

Page 3: Java Google Web Toolkit-GWT

Why? Handwritten Scripts vs GWT

Poor Usability

• history, bookmarks

Poor Tool Support• Limited IDE support

• Debugging too often boils down to window.alert()

• Profilers? Findbugs?

Page 4: Java Google Web Toolkit-GWT

Why? Handwritten Scripts vs GWT

Hard to test

• JUnit support for GWT

Quality Risks

• New categories of runtime-only bugs (e.g. spelling bugs)

1047: x.compnent = getValue("x");

• Poor JS reuse model encourages "from scratch" or copy/paste

Page 5: Java Google Web Toolkit-GWT

Why? Handwritten Scripts vs GWT

Hard for large teams to work on the same code base

Auto Complete Browser Compatibility

Remember our Dear friend IE !!!

Page 6: Java Google Web Toolkit-GWT

All these points start to matter a lot for big projects

What is the Solution?

Can Java be used for client-side scripting?More or less, the impossible…

Page 7: Java Google Web Toolkit-GWT

Unless you translate Java into JavaScript

Page 8: Java Google Web Toolkit-GWT

GWT Features

HTML 5 support Mobile Web support Cross-browser? An abstract DOM class History class - Demo RPC Widgets JSNI Presentation - CSS

Page 9: Java Google Web Toolkit-GWT

Widgets and Panels

Demos at Showcase

Page 10: Java Google Web Toolkit-GWT

RPC

GWT supports various ways to communicate with the server JSON, XML etc.

But a pure Java RPC interface would be awesome. Isn't it?

Page 11: Java Google Web Toolkit-GWT
Page 12: Java Google Web Toolkit-GWT

JSNI

JavaScript Native Interfacepublic static native void alert(String msg) /*-{$wnd.alert(msg);

}-*/;

Page 13: Java Google Web Toolkit-GWT

Things to know...

Technology second, users first.

It isn't Java vs Javascript or Java vs everything else.

Download exactly what you need.

GWT Team slogan: the bling is on the inside

Hosted mode

Page 14: Java Google Web Toolkit-GWT

Question and Answer

Page 15: Java Google Web Toolkit-GWT

Thank you