UserName constructor

UserName(
  1. String value
)

Implementation

UserName(String value) : super(value.trim()) {
  if (!_regExp.hasMatch(val)) {
    throw FormatException('Does not match validation RegExp: `$val`');
  }
}