43

The Java 8 way of dealing with time seems to have improved so much that I start to think about replacing jodatime in some cases. But what I am missing is an equivalent to the Interval class.

I haven't dug too deep into Java 8 yet, so I might have missed something there. Does anyone have ideas on how intervals could be best dealt with?

nansen
  • 2,912
  • 1
  • 20
  • 33

1 Answers1

35

No way, the Joda class Interval does not exist in JSR-310. The concepts of Duration, Period etc. denotes temporal amounts without being bound to fixed points in time while an interval has a fixed start and fixed end on the timeline.

By the way, this question is not new and a duplicate. On the other SO-link you can also find a similar answer direct from JodaTime-project-leader.

Community
  • 1
  • 1
Meno Hochschild
  • 42,708
  • 7
  • 104
  • 126
  • 1
    Seems I keep sticking with joda. It's not such a bad thing anyway. Thanks for the answer. – nansen Apr 05 '14 at 22:20