View Javadoc
1   package xuml.tools.model.compiler.runtime.query;
2   
3   import java.util.Date;
4   
5   import scala.concurrent.duration.Duration;
6   import xuml.tools.model.compiler.runtime.Entity;
7   
8   public class DateConstant<T extends Entity<T>> extends DateExpression<T> {
9   
10      private final Date value;
11  
12      public DateConstant(Date value) {
13          this.value = value;
14      }
15  
16      public DateConstant(Duration duration) {
17          this(new Date(duration.toMillis()));
18      }
19  
20      public Date getValue() {
21          return value;
22      }
23  
24  }