aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/web/client/FormatterUtil.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2013-02-17 13:24:07 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2013-02-17 13:24:07 +1300
commit9f80fe9b90d9ddb1132c139072cfe3bac5a42491 (patch)
treefd8234a8cc7d7b5a7174dad6fe4c27c4017c0182 /src/org/traccar/web/client/FormatterUtil.java
parent29b57a52c6a66075261d7e6d4797fa1bcc7c8cb8 (diff)
downloadtrackermap-web-9f80fe9b90d9ddb1132c139072cfe3bac5a42491.tar.gz
trackermap-web-9f80fe9b90d9ddb1132c139072cfe3bac5a42491.tar.bz2
trackermap-web-9f80fe9b90d9ddb1132c139072cfe3bac5a42491.zip
Added settings controller
Diffstat (limited to 'src/org/traccar/web/client/FormatterUtil.java')
-rw-r--r--src/org/traccar/web/client/FormatterUtil.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/org/traccar/web/client/FormatterUtil.java b/src/org/traccar/web/client/FormatterUtil.java
new file mode 100644
index 00000000..f5c7d3e1
--- /dev/null
+++ b/src/org/traccar/web/client/FormatterUtil.java
@@ -0,0 +1,17 @@
+package org.traccar.web.client;
+
+import java.util.Date;
+
+import com.google.gwt.i18n.client.DateTimeFormat;
+
+public class FormatterUtil {
+
+ public DateTimeFormat getTimeFormat() {
+ return DateTimeFormat.getFormat("yyyy-MM-dd HH:mm:ss");
+ }
+
+ public String formatTime(Date time) {
+ return getTimeFormat().format(time);
+ }
+
+}