Teki
Rules

Future or Present

Require a date or time in the future or equal to now.

Use futureOrPresent() on temporal fields to allow dates from now onward.

Teki schema = Teki.fromRules(
    temporal("startsAt").required().futureOrPresent()
);

Available on

  • temporal(...)

Annotation equivalent

import dev.ditsche.teki.annotation.FutureOrPresent;

public class EventRequest {
    @FutureOrPresent
    private ZonedDateTime startsAt;
}

On this page