ILIAS
release_5-2 Revision v5.2.25-18-g3f80b828510
|
This class offers methods for timezone handling. More...
Public Member Functions | |
__sleep () | |
__wakeup () | |
getIdentifier () | |
get identifier More... | |
switchTZ () | |
Switch timezone to given timezone. More... | |
restoreTZ () | |
Restore default timezone. More... | |
validateTZ () | |
validate timezone More... | |
Static Public Member Functions | |
static | _getInstance ($a_tz='') |
get instance by timezone More... | |
static | _setDefaultTimeZone ($a_tz) |
set default timezone More... | |
static | _restoreDefaultTimeZone () |
restore default timezone to server timezone More... | |
static | _getDefaultTimeZone () |
Calculate and set default time zone. More... | |
static | initDefaultTimeZone (ilIniFile $ini) |
Initialize default timezone from system settings. More... | |
Data Fields | |
const | UTC = 'UTC' |
Static Public Attributes | |
static | $instances = array() |
static | $valid_tz = array() |
Static Protected Member Functions | |
static | _switchTimeZone ($a_timezone) |
Switch tz. More... | |
Protected Attributes | |
$log | |
$timezone = "UTC" | |
Static Protected Attributes | |
static | $default_timezone = '' |
static | $current_timezone = '' |
static | $server_timezone = '' |
Private Member Functions | |
__construct ($a_timezone) | |
Create new timezone object If no timezone is given, the default server timezone is chosen. More... | |
This class offers methods for timezone handling.
ilTimeZone::_getDefault
tries to "guess" the server timezone in the following manner: 1) PHP >= 5.2.0 use date_default_timezone_get
2) Read ini option date.timezone if available 3) Read environment PHP_TZ 4) Read environment TZ 5) Use date('T')
6) Use UTC
Definition at line 43 of file class.ilTimeZone.php.
|
private |
Create new timezone object If no timezone is given, the default server timezone is chosen.
private
string | valid timezone |
Definition at line 65 of file class.ilTimeZone.php.
References $ilLog, and timezone.
ilTimeZone::__sleep | ( | ) |
ilTimeZone::__wakeup | ( | ) |
|
static |
Calculate and set default time zone.
public
Definition at line 289 of file class.ilTimeZone.php.
Referenced by ilSoapInstallationInfoXMLWriter\__buildClient(), ilObjCalendarSettingsGUI\initFormSettings(), and ilCalendarSettings\read().
|
static |
get instance by timezone
public
string | valid php timezone |
ilTimeZoneException |
Definition at line 123 of file class.ilTimeZone.php.
References $ilLog.
Referenced by ilDate\__construct(), ilDateTime\__construct(), ilCalendarRecurrenceCalculator\applyBYMONTHDAYRules(), ilDateTime\get(), ilICalParser\getTZ(), ilICalParser\parse(), ilDateTime\switchTimeZone(), and ilUserImportParser\verifyPref().
|
static |
restore default timezone to server timezone
public
Definition at line 276 of file class.ilTimeZone.php.
Referenced by ilCalendarRecurrenceCalculator\calculateDateList().
|
static |
set default timezone
public
Definition at line 257 of file class.ilTimeZone.php.
Referenced by ilCalendarRecurrenceCalculator\adjustTimeZones().
|
staticprotected |
Switch tz.
public
ilTimeZoneException |
Definition at line 218 of file class.ilTimeZone.php.
References $ilLog.
ilTimeZone::getIdentifier | ( | ) |
|
static |
Initialize default timezone from system settings.
Definition at line 327 of file class.ilTimeZone.php.
References $tz, and ilIniFile\readVariable().
Referenced by ilInitialisation\initIliasIniFile().
ilTimeZone::restoreTZ | ( | ) |
Restore default timezone.
public
Definition at line 180 of file class.ilTimeZone.php.
Referenced by validateTZ().
ilTimeZone::switchTZ | ( | ) |
Switch timezone to given timezone.
public
Definition at line 160 of file class.ilTimeZone.php.
References timezone.
Referenced by ilICalParser\switchTZ(), and validateTZ().
ilTimeZone::validateTZ | ( | ) |
validate timezone
public
Definition at line 201 of file class.ilTimeZone.php.
References restoreTZ(), and switchTZ().
|
staticprotected |
Definition at line 51 of file class.ilTimeZone.php.
|
staticprotected |
Definition at line 50 of file class.ilTimeZone.php.
|
static |
Definition at line 47 of file class.ilTimeZone.php.
|
protected |
Definition at line 54 of file class.ilTimeZone.php.
|
staticprotected |
Definition at line 52 of file class.ilTimeZone.php.
|
protected |
Definition at line 55 of file class.ilTimeZone.php.
Referenced by getIdentifier().
|
static |
Definition at line 48 of file class.ilTimeZone.php.
const ilTimeZone::UTC = 'UTC' |
Definition at line 45 of file class.ilTimeZone.php.
Referenced by ilDate\__construct(), ilCalendarCategory\add(), ilCalendarRecurrenceCalculator\adjustTimeZones(), ilExportFileInfo\create(), ilCalendarExport\createVEVENT(), ilCalendarUserSettings\getExportTimeZone(), ilECSTimePlace\getUTBegin(), ilECSTimePlace\getUTEnd(), ilBookingEntry\lookupBookingsForObject(), ilObjectCustomUserFieldHistory\lookupEntriesByObjectId(), ilContainerXmlParser\parseTiming(), ilObjectCustomUserFieldHistory\read(), ilExportFileInfo\read(), ilDateList\removeByDAY(), ilConsultationHourCron\run(), ilObjectCustomUserFieldHistory\save(), ilCalendarEntry\save(), ilECSTimePlace\setBegin(), ilECSTimePlace\setEnd(), ilCalendarRecurrenceExclusion\toICal(), ilCalendarCategory\update(), ilCalendarEntry\update(), and ilContainerXmlWriter\writeCourseItemInformation().