Domanda

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?

È stato utile?

Soluzione

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.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top