A Scala current date and time example
Briefly

A simple way to get the current minute in Scala is to use java.util.Calendar class like val now = Calendar.getInstance() and then extract currentMinute using now.get(Calendar.MINUTE).
Another way to get the current time in Scala is by using Java's SimpleDateFormat class. The current time is obtained using val now = Calendar.getInstance().getTime() in Scala.
Read at alvinalexander.com
[
|
]