code: private Duration getDuration(String value)
     {
        Duration result = null;
  
        if (value != null && value.length() != 0)
        {
           double seconds = getLong(value);
           double hours = seconds / (60 * 60);
           double days = hours / 8;
  
           if (days < 1)
           {
              result = Duration.getInstance(hours, TimeUnit.HOURS);
           }
           else
           {
              double durationDays = hours / 8;
              result = Duration.getInstance(durationDays, TimeUnit.DAYS);
           }
        }
  
        return (result);
     }
docs: Converts the string representation of a Planner duration into
  an MPXJ Duration instance.
  
  Planner represents durations as a number of seconds in its
  file format, however it displays durations as days and hours,
  and seems to assume that a working day is 8 hours.
  
  @param value string representation of a duration
  @return Duration instance