hex function

LivrRule hex(
  1. List<Object?> args,
  2. RuleContext context
)

hex: the value must be hexadecimal digits 0-9, a-f or A-F, without a 0x prefix. The output is the value as a string.

Implementation

LivrRule hex(List<Object?> args, RuleContext context) {
  if (args.isNotEmpty) {
    throw const LivrSchemaException('Rule [hex] takes no arguments');
  }
  return _hex;
}