151 If utcOffset is positive, the local timezone is west of Greenwich." |
151 If utcOffset is positive, the local timezone is west of Greenwich." |
152 |
152 |
153 ^ utcOffset ? 0 |
153 ^ utcOffset ? 0 |
154 ! |
154 ! |
155 |
155 |
156 utcOffset:seconds |
156 utcOffset:secondsOrTimeDuration |
157 "set the difference between UTC (Greenwich Mean Time) and the local time in seconds. |
157 "set the difference between UTC (Greenwich Mean Time) and the local time in seconds. |
158 If daylight saving time applies to ourself, take that into account. |
158 If daylight saving time applies to ourself, take that into account. |
159 |
159 |
160 Add utcOffset to convert from local time to UTC time. |
160 Add utcOffset to convert from local time to UTC time. |
161 Subtract utcOffset to convert from UTC time to local time. |
161 Subtract utcOffset to convert from UTC time to local time. |
162 |
162 |
163 If utcOffset is negative, the local timezone is east of Greenwich. |
163 If utcOffset is negative, the local timezone is east of Greenwich. |
164 If utcOffset is positive, the local timezone is west of Greenwich." |
164 If utcOffset is positive, the local timezone is west of Greenwich." |
165 |
165 |
166 utcOffset := seconds asInteger. |
166 utcOffset := secondsOrTimeDuration asInteger. |
167 |
167 |
168 "Modified: / 20-11-2014 / 13:05:48 / sr" |
168 "Modified: / 20-11-2014 / 13:05:48 / sr" |
|
169 "Modified (format): / 26-05-2019 / 12:09:21 / Claus Gittinger" |
169 ! ! |
170 ! ! |
170 |
171 |
171 !TZTimestamp methodsFor:'converting'! |
172 !TZTimestamp methodsFor:'converting'! |
172 |
173 |
173 asLocalTimestamp |
174 asLocalTimestamp |