1 package org
.eclipse
.linuxtools
.tmf
.core
.ctfadaptor
;
3 import java
.text
.DateFormat
;
4 import java
.text
.SimpleDateFormat
;
7 import org
.eclipse
.linuxtools
.tmf
.core
.event
.ITmfTimestamp
;
8 import org
.eclipse
.linuxtools
.tmf
.core
.event
.TmfTimestamp
;
10 public class CtfTmfTimestamp
extends TmfTimestamp
implements ITmfTimestamp
{
12 final private CtfTmfTrace fTrace
;
14 public CtfTmfTimestamp(long timestamp
, CtfTmfTrace trace
) {
23 * @see java.lang.Object#toString()
26 public String
toString() {
27 final long timestamp
= fValue
;
28 final Date d
= new Date(timestamp
/ 1000000);
29 final DateFormat df
= new SimpleDateFormat("yyyy-MM-dd HH:mm:ss."); //$NON-NLS-1$
30 final long nanos
= (timestamp
% 1000000000);
31 StringBuilder output
= new StringBuilder();
32 output
.append(df
.format(d
));
33 output
.append(String
.format("%09d", nanos
)); //$NON-NLS-1$
34 return output
.toString();
This page took 0.031667 seconds and 6 git commands to generate.