Logo GenPRES

Dto Module

Holds the Dto of a height at a date and converts a height at a date to and from the Dto. Returns a validation error for a height outside the bounds or a date after today.

Types

Type Description

Dto

Functions and values

Function or value Description

dto ()

Full Usage: dto ()

Parameters:
    () : unit

Returns: Dto
() : unit
Returns: Dto

fromDto today dto

Full Usage: fromDto today dto

Parameters:
Returns: Result<HeightAtDate, ValidationErrors>

Validates a Dto as a height: a height within the bounds, and a date on or before today when the Dto has a date. A Dto without a date gives an undated height.

today : DateTime
dto : Dto
Returns: Result<HeightAtDate, ValidationErrors>

toDto w

Full Usage: toDto w

Parameters:
Returns: Dto
w : HeightAtDate
Returns: Dto

Type something to start searching.