JAVA TIME get seconds code example
Example: java get current time in seconds
LocalDateTime date = LocalDateTime.now();
int seconds = date.toLocalTime().toSecondOfDay();
LocalDateTime date = LocalDateTime.now();
int seconds = date.toLocalTime().toSecondOfDay();