Returns the date obtained by adding this duration to now. @return the computed date
()
| 150 | * @return the computed date |
| 151 | */ |
| 152 | @Override |
| 153 | public Date getNow() { |
| 154 | final Calendar cal = Calendar.getInstance(); |
| 155 | |
| 156 | cal.add(Calendar.DAY_OF_YEAR, TimeDuration.this.getDays()); |
| 157 | cal.add(Calendar.HOUR_OF_DAY, TimeDuration.this.getHours()); |
| 158 | cal.add(Calendar.MINUTE, TimeDuration.this.getMinutes()); |
| 159 | cal.add(Calendar.SECOND, TimeDuration.this.getSeconds()); |
| 160 | cal.add(Calendar.MILLISECOND, TimeDuration.this.getMillis()); |
| 161 | |
| 162 | return cal.getTime(); |
| 163 | } |
| 164 | }; |
| 165 | } |
| 166 | } |
nothing calls this directly
no test coverage detected