Join Slack
Powered by
Some tips on date operations in kotlin....differen...
# getting-started
d
drfidel
09/03/2018, 3:20 PM
Some tips on date operations in kotlin....difference between dates adding a number of days to a particular date
google
1
d
diesieben07
09/03/2018, 3:26 PM
Use Java 8's date / time libraries. They are awesome
diesieben07
09/03/2018, 3:27 PM
The two problems you mentioned:
val dur = Duration.between(date1, date2)
val later = myTime.add(3, DAYS)
etc.
diesieben07
09/03/2018, 3:27 PM
It's well documented and there are many examples
📖 2
👓 2
d
drfidel
09/03/2018, 4:28 PM
Thanks......i imported java.time* but add api not available
2
Views
Open in Slack
Previous
Next