functions property

Map<String, num Function([dynamic value])> functions
final

The functions related to the Random number generator

Implementation

static final functions = {
  'random': ([value]) {
    final sr = Random.secure();
    num result;

    if (value is num) {
      result = sr.nextInt(value.toInt());
    } else {
      result = sr.nextDouble();
    }

    return result;
  },
};