import java.time.LocalDate
import java.time.LocalDateTime
import java.time.LocalTime
import java.time.temporal.ChronoUnit
import java.time.temporal.Temporal

class Gigasecond(val dt: Temporal) {
    val date: LocalDateTime =
            if (dt is LocalDate){
                LocalDateTime.of(dt, LocalTime.MIDNIGHT).plus(1000000000, ChronoUnit.SECONDS)
            }
            else (LocalDateTime.from(dt).plus(1000000000, ChronoUnit.SECONDS))

    override fun equals(other: Any?): Boolean {
        return (this.date == other)
    }
}