common/utils/record_utils library

Extensions

RecordExtension on (L?, R?)
Extension method that allows folding over a pair of values. The fold method takes two functions as arguments: left and right. If the first value of the pair is null, the right function is called with the second value. Otherwise, the left function is called with the first value. The result of the function call is returned.

Functions

left<L, R>(L? left) → (L?, R?)
Creates a pair with the first value set to the provided left value and the second value set to null.
Creates a pair with the first value set to null and the second value set to the provided right value.