docs: @Override
    public String format(Object value)
    {
      if(value == null) {
        return "";
      }
  
      double duration = 0;
      if(value instanceof Integer) {
        duration = (Integer)value;
      }
      else if(value instanceof Long) {
        duration = (Long)value;
      }
      else {
        throw new IllegalArgumentException(String.format("Invalid argument type |%s|.", value.getClass()));
      }
  
      if(duration == 0) {
        return format(0, Units.MILLISECONDS);
      }
      Units units = Units.MILLISECONDS;
      for(Units u : Units.values()) {
        if(duration < u.value) {
          break;
        }
        units = u;
      }
      return format(duration / units.value, units);
    }