TimeInstant instant = TimeInstant.parse(expr); TimeInstant now = TimeInstant.now(); if (instant.getTimeInstant().equals(now.getTimeInstant())) { String fromExpr = expr.substring(0, sep); String toExpr = expr.substring(sep + 4); TimeInstant from = TimeInstant.parse(fromExpr); TimeInstant to = TimeInstant.parse(toExpr); timeFrame.setFrom(from); timeFrame.setTo(to);
TimeInstant instant = TimeInstant.parse(expr); TimeInstant now = TimeInstant.now(); if (instant.getTimeInstant().equals(now.getTimeInstant())) { String fromExpr = expr.substring(0, sep); String toExpr = expr.substring(sep + 4); TimeInstant from = TimeInstant.parse(fromExpr); TimeInstant to = TimeInstant.parse(toExpr); timeFrame.setFrom(from); timeFrame.setTo(to);