com.personio.synthetics.model.config.Timeframe.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of datadog-synthetic-test-support Show documentation
Show all versions of datadog-synthetic-test-support Show documentation
Kotlin library for managing Datadog Synthetic test as code
package com.personio.synthetics.model.config
import java.time.DayOfWeek
import java.time.LocalTime
class Timeframe private constructor(val from: LocalTime, val to: LocalTime, vararg val days: DayOfWeek) {
companion object {
operator fun invoke(
from: LocalTime,
to: LocalTime,
vararg days: DayOfWeek,
): Timeframe {
require(from < to) {
"From time must be earlier than To time."
}
return Timeframe(from, to, *days)
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy