# Class: com.pnfsoftware.jeb.util.format.TimeFormatter

Utility methods to format timestamps and time deltas.

## Constructor: TimeFormatter


## Static Method: formatDuration
- parameter: `durationMs`, type: `long`
- return type: `java.lang.String`

Description: Format a time duration as a human\-readable string. The reported duration uses `s, m, h, d` for seconds, minutes, hours, and days. 

 To display milliseconds, use [#formatExecutionTime(long)](#formatExecutionTime(long)).
parameter: durationMs: duration in milliseconds; it may be negative
return: the formatted duration

## Static Method: formatExecutionTime
- parameter: `exectimeMs`, type: `long`
- return type: `java.lang.String`

Description: Format an execution time as a human\-readable string. The reported duration uses `ms, s, m, h, d` for milliseconds, seconds, minutes, hours, and days.
parameter: exectimeMs: execution time in milliseconds; it may be negative
return: the formatted execution time

## Static Method: formatTimestamp
- parameter: `unixTimestampMs`, type: `long`
- return type: `java.lang.String`

Description: Format an epoch timestamp as a UTC string using the following format: 

```

 YYYY/MM/DD-hh:mm:ss
 
```
parameter: unixTimestampMs: Unix epoch timestamp in milliseconds
return: the formatted UTC timestamp

## Static Method: formatTimestamp
- parameter: `unixTimestampMs`, type: `long`
- parameter: `timezone`, type: `java.lang.String`
- return type: `java.lang.String`

Description: Format an epoch timestamp as using the following format: 

```

 YYYY/MM/DD-hh:mm:ss
 
```
parameter: unixTimestampMs: Unix epoch timestamp in milliseconds
parameter: timezone: time zone identifier accepted by [TimeZone#getTimeZone(String)](TimeZone#getTimeZone(String))
return: the formatted timestamp in the requested time zone

## Static Method: formatTimestampDelta
- parameter: `deltaMs`, type: `long`
- return type: `java.lang.String`

Description: 
deprecated: use [#formatDuration(long)](#formatDuration(long)) instead

## Static Method: formatTimestampLocal
- parameter: `unixTimestampMs`, type: `long`
- return type: `java.lang.String`

Description: Format an epoch timestamp as a local, system specific date\-and\-time string.
parameter: unixTimestampMs: Unix epoch timestamp in milliseconds
return: the formatted local timestamp

