def DateTime.valid

bend-kit-time@0.3.0.0 · time.bend:267

import bend-kit-time@0.3.0.0/time.bend as Time
import Base

267def DateTime.valid(t: DateTime) -> Bool:
268  match t:
269    case DateTime{d, h, mi, s, n}:
270      Bool.and(Date.valid(d), Bool.and(U32.is_le(h, 23),
271        Bool.and(U32.is_le(mi, 59), Bool.and(U32.is_le(s, 59), U32.is_lt(n, 1000000000)))))

Uses (6)

Used by (1)