Index: runtime/observatory/lib/utils.dart |
diff --git a/runtime/observatory/lib/utils.dart b/runtime/observatory/lib/utils.dart |
index c696529c750b20bfcc1e09bf1d15131c2ab5018b..cfc447c7c5cffd5f935ce5f19a9fb0ff04b24fa2 100644 |
--- a/runtime/observatory/lib/utils.dart |
+++ b/runtime/observatory/lib/utils.dart |
@@ -135,6 +135,13 @@ class Utils { |
return '${seconds}s'; |
} |
+ static String formatDateTime(DateTime now) { |
+ return '${now.year}-${now.month}-${now.day} ' |
+ '${now.hour.toString().padLeft(2)}:' |
+ '${now.minute.toString().padLeft(2)}:' |
+ '${now.second.toString().padLeft(2)}'; |
+ } |
+ |
static String formatSeconds(double x) { |
return x.toStringAsFixed(2); |
} |