Example usage for com.google.gwt.i18n.client TimeZone getShortName

List of usage examples for com.google.gwt.i18n.client TimeZone getShortName

Introduction

In this page you can find the example usage for com.google.gwt.i18n.client TimeZone getShortName.

Prototype

public String getShortName(Date date) 

Source Link

Usage

From source file:com.vaadin.client.DateTimeService.java

License:Apache License

private String formatTimeZone(Date date, String formatStr, TimeZone timeZone) {
    // if 'z' is found outside quotes and timeZone is used
    if (getIndexOf(formatStr, 'z') != -1 && timeZone != null) {
        return replaceTimeZone(formatStr, timeZone.getShortName(date));
    }/*from   ww  w  . j  ava  2  s  .c o m*/
    return formatStr;
}