code: private String formatDuration(Object value)
     {
        String result = null;
        if (value instanceof Duration)
        {
           Duration duration = (Duration) value;
           result = m_formats.getDurationDecimalFormat().format(duration.getDuration()) + formatTimeUnit(duration.getUnits());
        }
        return result;
     }
docs: This method is called to format a duration.
  
  @param value duration value
  @return formatted duration value