GlideDateTime - getUserTimeZone()

Gets the time zone for the current user session.

This method is equivalent to gs.getSession().getTimeZone().

Table 1. Parameters
Name Type Description
None
Table 2. Returns
Type Description
TimeZone TimeZone object for the current user.

var gdt = new GlideDateTime("2011-08-31 08:00:00");
gs.print(gdt.getUserTimeZone());

Output:

sun.util.calendar.ZoneInfo[id="America/Los_Angeles",offset=-28800000,dstSavings=3600000,useDaylight=true,transitions=185,
lastRule=java.util.SimpleTimeZone[id=America/Los_Angeles,offset=-28800000,dstSavings=3600000,useDaylight=true,startYear=0,startMode=3,
startMonth=2,startDay=8,startDayOfWeek=1,startTime=7200000,startTimeMode=0,endMode=3,endMonth=10,endDay=1,endDayOfWeek=1,
endTime=7200000,endTimeMode=0]]