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

Unified Diff: runtime/bin/file.dart

Issue 10443008: Implement File.lastModified. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Return ms from C Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/bin/file.cc ('k') | runtime/bin/file_impl.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/file.dart
diff --git a/runtime/bin/file.dart b/runtime/bin/file.dart
index 248e4b4595d77ee21ee10b8e3bfbde53efb70718..f55bc302ad7e58cb5144a83e7acc2df0227c70bb 100644
--- a/runtime/bin/file.dart
+++ b/runtime/bin/file.dart
@@ -92,6 +92,19 @@ interface File default _File {
int lengthSync();
/**
+ * Get the last-modified time of the file. Returns a
+ * [:Future<Date>:] that completes with a [Date] object for the
+ * modification date.
+ */
+ Future<Date> lastModified();
+
+ /**
+ * Get the last-modified time of the file. Throws an exception
+ * if the file does not exist.
+ */
+ Date lastModifiedSync();
+
+ /**
* Open the file for random access operations. Returns a
* [:Future<RandomAccessFile>:] that completes with the opened
* random access file. RandomAccessFiles must be closed using the
« no previous file with comments | « runtime/bin/file.cc ('k') | runtime/bin/file_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698