Expose entity Date fields in an Android SDK for Java 7 and below

41 views Asked by At

We plan to release an Android SDK for various customers. The SDK will expose entities with Date alike (or DateTime) fields. However, there is an issue between Java 7 and Java 8, the latter got new classes and a drastic change in how it deals with Dates.

What would be the best way (or type) for exposing Date fields?

Should we use ThreeTenABP library for that and use its types or there is a better solution?

1

There are 1 answers

0
Steve On BEST ANSWER

Yes, you should use this backport

You can also take a look to Joda time but it seems deprecated since ThreeTenABP cames out