Code example for DatatypeFactory

Methods: newDuration

0
      start = parseDate(expression.get(0));
      if (isDuration(expression.get(1))) {
        period = parsePeriod(expression.get(1));
      } else { 
        end = parseDate(expression.get(1));
        period = datatypeFactory.newDuration(end.getTime()-start.getTime());
      } 
    } 
    if (start == null && end == null) {
      start = ClockUtil.getCurrentTime();
    } 
 
  } 
 
  public Date getDateAfter() {
    if (isRepeat) {
      return getDateAfterRepeat(ClockUtil.getCurrentTime()); 
    } 
    //TODO: is this correct? 
    if (end != null) {
Contextual code suggestions in your IDE  Get Codota for Java