Skip to content

Commit 117d18d

Browse files
authored
Remove timezone interface from the proposal for shipping Preview 2 (#55)
* remove timezone interface from the proposal We believe there is value in providing timezone support in this package, but for the sake of shipping Preview 2, we are out of time to implement these methods and test a a cross platform implementation of these in two separate engines. We intend for this interface to return to the wasi:clocks package and be made in a post-Preview 2 patch version 0.2.n. Re-introducing this interface may be done with a revert of this commit once we have shipped Preview 2 and figured out the process for shipping patch versions. * generate markdown
1 parent b1169d7 commit 117d18d

File tree

3 files changed

+0
-115
lines changed

3 files changed

+0
-115
lines changed

imports.md

Lines changed: 0 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
<li>interface <a href="#wasi:io_poll"><code>wasi:io/poll</code></a></li>
66
<li>interface <a href="#wasi:clocks_monotonic_clock"><code>wasi:clocks/monotonic-clock</code></a></li>
77
<li>interface <a href="#wasi:clocks_wall_clock"><code>wasi:clocks/wall-clock</code></a></li>
8-
<li>interface <a href="#wasi:clocks_timezone"><code>wasi:clocks/timezone</code></a></li>
98
</ul>
109
</li>
1110
</ul>
@@ -161,68 +160,3 @@ also known as <a href="https://en.wikipedia.org/wiki/Unix_time">Unix Time</a>.</
161160
<ul>
162161
<li><a name="resolution.0"></a> <a href="#datetime"><a href="#datetime"><code>datetime</code></a></a></li>
163162
</ul>
164-
<h2><a name="wasi:clocks_timezone">Import interface wasi:clocks/timezone</a></h2>
165-
<hr />
166-
<h3>Types</h3>
167-
<h4><a name="datetime"><code>type datetime</code></a></h4>
168-
<p><a href="#datetime"><a href="#datetime"><code>datetime</code></a></a></p>
169-
<p>
170-
#### <a name="timezone_display">`record timezone-display`</a>
171-
<p>Information useful for displaying the timezone of a specific <a href="#datetime"><code>datetime</code></a>.</p>
172-
<p>This information may vary within a single <code>timezone</code> to reflect daylight
173-
saving time adjustments.</p>
174-
<h5>Record Fields</h5>
175-
<ul>
176-
<li>
177-
<p><a name="timezone_display.utc_offset"><a href="#utc_offset"><code>utc-offset</code></a></a>: <code>s32</code></p>
178-
<p>The number of seconds difference between UTC time and the local
179-
time of the timezone.
180-
<p>The returned value will always be less than 86400 which is the
181-
number of seconds in a day (24<em>60</em>60).</p>
182-
<p>In implementations that do not expose an actual time zone, this
183-
should return 0.</p>
184-
</li>
185-
<li>
186-
<p><a name="timezone_display.name"><code>name</code></a>: <code>string</code></p>
187-
<p>The abbreviated name of the timezone to display to a user. The name
188-
`UTC` indicates Coordinated Universal Time. Otherwise, this should
189-
reference local standards for the name of the time zone.
190-
<p>In implementations that do not expose an actual time zone, this
191-
should be the string <code>UTC</code>.</p>
192-
<p>In time zones that do not have an applicable name, a formatted
193-
representation of the UTC offset may be returned, such as <code>-04:00</code>.</p>
194-
</li>
195-
<li>
196-
<p><a name="timezone_display.in_daylight_saving_time"><code>in-daylight-saving-time</code></a>: <code>bool</code></p>
197-
<p>Whether daylight saving time is active.
198-
<p>In implementations that do not expose an actual time zone, this
199-
should return false.</p>
200-
</li>
201-
</ul>
202-
<hr />
203-
<h3>Functions</h3>
204-
<h4><a name="display"><code>display: func</code></a></h4>
205-
<p>Return information needed to display the given <a href="#datetime"><code>datetime</code></a>. This includes
206-
the UTC offset, the time zone name, and a flag indicating whether
207-
daylight saving time is active.</p>
208-
<p>If the timezone cannot be determined for the given <a href="#datetime"><code>datetime</code></a>, return a
209-
<a href="#timezone_display"><code>timezone-display</code></a> for <code>UTC</code> with a <a href="#utc_offset"><code>utc-offset</code></a> of 0 and no daylight
210-
saving time.</p>
211-
<h5>Params</h5>
212-
<ul>
213-
<li><a name="display.when"><code>when</code></a>: <a href="#datetime"><a href="#datetime"><code>datetime</code></a></a></li>
214-
</ul>
215-
<h5>Return values</h5>
216-
<ul>
217-
<li><a name="display.0"></a> <a href="#timezone_display"><a href="#timezone_display"><code>timezone-display</code></a></a></li>
218-
</ul>
219-
<h4><a name="utc_offset"><code>utc-offset: func</code></a></h4>
220-
<p>The same as <a href="#display"><code>display</code></a>, but only return the UTC offset.</p>
221-
<h5>Params</h5>
222-
<ul>
223-
<li><a name="utc_offset.when"><code>when</code></a>: <a href="#datetime"><a href="#datetime"><code>datetime</code></a></a></li>
224-
</ul>
225-
<h5>Return values</h5>
226-
<ul>
227-
<li><a name="utc_offset.0"></a> <code>s32</code></li>
228-
</ul>

wit/timezone.wit

Lines changed: 0 additions & 48 deletions
This file was deleted.

wit/world.wit

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,4 @@ package wasi:clocks;
33
world imports {
44
import monotonic-clock;
55
import wall-clock;
6-
import timezone;
76
}

0 commit comments

Comments
 (0)