DZone
Java Zone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
  • Refcardz
  • Trend Reports
  • Webinars
  • Zones
  • |
    • Agile
    • AI
    • Big Data
    • Cloud
    • Database
    • DevOps
    • Integration
    • IoT
    • Java
    • Microservices
    • Open Source
    • Performance
    • Security
    • Web Dev
DZone > Java Zone > GWT i18n Overview

GWT i18n Overview

Mohammed Amine Tazi user avatar by
Mohammed Amine Tazi
·
Sep. 16, 10 · Java Zone · Interview
Like (0)
Save
Tweet
5.81K Views

Join the DZone community and get the full member experience.

Join For Free

Google Web Toolkit is an out of the box set of APIs that allows developing Ajax applications easily using Java technology.

There is a need in certain applications to allow the user chooses the languages he prefers to see contents with, so as he can understand what the project is all about and can be therefore a potential customer.

GWT provides great support for internationalization (i18n), and this is true by providing specific classes to use :

  • Constants : Used when externalizing static constants to different languages.
  • ConstantsWithLookup : Used when externalizing static  constants to different languages like Constants interface, but adding the ability to load dynamically a value of a property at runtime.
  • Messages : Used when externalizing static constants with parameters to different languages.
  • Dictionary : Corresponds to a dictionary included to the host page at first page loading.
  • Localizable : specializes a class behaviour depending on the used locale.
  • DateTimeFormat & NumberFormat : utility classes provided to format dates and numbers at the client side.
  • CurrencyCodeMapConstants : currency dictionary to use directly in your application.

Moreover, GWT provides a command line tool called “i18Creator” to generate language properties file or interfaces automatically because doing this by hand could be a daunting task. “i18Sync” is another tool provided by GWT that takes in input language properties files and generates automatically interfaces as output.

Good luck with GWT i18n.

From http://www.misterj2ee.com/2010/09/gwt-i18n-overview/

application Google Web Toolkit Interface (computing) Dictionary (software) Property (programming) Host (Unix) Google (verb) Locale (computer hardware)

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • Deployment of Low-Latency Solutions in the Cloud
  • OpenTelemetry in Action: Identifying Database Dependencies
  • Why I'm Choosing Pulumi Over Terraform
  • Debugging Deadlocks and Race Conditions

Comments

Java Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • MVB Program
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends:

DZone.com is powered by 

AnswerHub logo