I have implemented an interface. There I am passing timestamp as parameter to a function. DFor geting the current time, I have used Instant.now().toString().
Instant.now().toString()