Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Side by Side Diff: lib/i18n/date_format.dart

Issue 10538061: Reapply "Remove deprecated classes and functions in Date." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « lib/compiler/implementation/scanner/source_list.dart ('k') | runtime/lib/date.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 /** 5 /**
6 * DateFormat is for formatting and parsing dates in a locale-sensitive 6 * DateFormat is for formatting and parsing dates in a locale-sensitive
7 * manner. 7 * manner.
8 * It allows the user to choose from a set of standard date time formats as well 8 * It allows the user to choose from a set of standard date time formats as well
9 * as specify a customized pattern under certain locales. Date elements that 9 * as specify a customized pattern under certain locales. Date elements that
10 * vary across locales include month name, week name, field order, etc. 10 * vary across locales include month name, week name, field order, etc.
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 * format. 223 * format.
224 */ 224 */
225 String parse(String inputString) { 225 String parse(String inputString) {
226 return inputString; 226 return inputString;
227 } 227 }
228 228
229 /** 229 /**
230 * Format the given [date] object according to preset pattern and current 230 * Format the given [date] object according to preset pattern and current
231 * locale and return a formated string for the given date. 231 * locale and return a formated string for the given date.
232 */ 232 */
233 String format(Date date, [TimeZone timeZone]) { 233 String format(Date date) {
234 // TODO(efortuna): optional TimeZone argument? TimeZone is deprecated... 234 // TODO(efortuna): readd optional TimeZone argument (or similar)?
235 return date.toString(); 235 return date.toString();
236 } 236 }
237 237
238 /** 238 /**
239 * Returns a date string indicating how long ago (3 hours, 2 minutes) 239 * Returns a date string indicating how long ago (3 hours, 2 minutes)
240 * something has happened or how long in the future something will happen 240 * something has happened or how long in the future something will happen
241 * given a [reference] Date relative to the current time. 241 * given a [reference] Date relative to the current time.
242 */ 242 */
243 String formatDuration(Date reference) { 243 String formatDuration(Date reference) {
244 return ''; 244 return '';
245 } 245 }
246 246
247 /** 247 /**
248 * Formats a string indicating how long ago (negative [duration]) or how far 248 * Formats a string indicating how long ago (negative [duration]) or how far
249 * in the future (positive [duration]) some time is with respect to a 249 * in the future (positive [duration]) some time is with respect to a
250 * reference [date]. 250 * reference [date].
251 */ 251 */
252 String formatDurationFrom(Duration duration, Date date) { 252 String formatDurationFrom(Duration duration, Date date) {
253 return ''; 253 return '';
254 } 254 }
255 } 255 }
OLDNEW
« no previous file with comments | « lib/compiler/implementation/scanner/source_list.dart ('k') | runtime/lib/date.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698