Skip to content
This repository has been archived by the owner on Mar 20, 2018. It is now read-only.

Simplify GregorianCalendar methods #62

Closed
RogerRiggs opened this issue Aug 23, 2012 · 2 comments
Closed

Simplify GregorianCalendar methods #62

RogerRiggs opened this issue Aug 23, 2012 · 2 comments
Assignees
Labels

Comments

@RogerRiggs
Copy link
Contributor

Simplify the additional methods in java.util.GregorianCalendar and rely on the Theeten types with "from" methods to create ThreeTen instances. GregorianCalendar implements the DateTime interface which provides the necessary fields and types.

Remove:
LocalDate toLocalDate()
LocalDateTime toLocalDateTime()
LocalTime toLocalTime()
OffsetDate toOffsetDate()
OffsetDateTime toOffsetDateTime()
OffsetTime toOffsetTime()
ZonedDateTime toZonedDateTime()

@jodastephen
Copy link
Member

LocalDate.from(gregCal) is an acceptable alternative.

I would suggest keeping the toInstant() method on j.u.Date and Calendar however, as that is a useful conversion.

@ghost ghost assigned RogerRiggs Sep 5, 2012
@RogerRiggs
Copy link
Contributor Author

Changed the milestone; the integration of java.util.Calendar/date will be done after the integration into the JDK.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Development

No branches or pull requests

2 participants