title: Convert Olson Time Zone ID to TimeZoneConstant in GWT (Client Side)
body: <p>We store our dates are stored in milliseconds since the epoch and the Olson time zone ID for the objects we want to display time related data about.</p>
  
  <p>How can I convert the Olson TZID to a TimeZoneConstant to create a TimeZone and use DateTimeFormat?</p>
  
  <pre><code>// values from database
  String tzid = "America/Vancouver";
  long date = 1310771967000L;
  
  
  final TimeZoneConstants tzc = GWT.create(TimeZoneConstants.class);
  String tzInfoJSON = MAGIC_FUNCTION(tzid, tzc);
  TimeZone tz = TimeZone.createTimeZone(TimeZoneInfo.buildTimeZoneData(tzInfoJSON));
  String toDisplay = DateTimeFormat.getFormat("y/M/d h:m:s a v").format(new Date(date), tz); 
  </code></pre>
  
  <p>Does that MAGIC_FUNCTION exist? Or is there another way to do this?</p>