UuidValue constructor Null safety
UuidValue() Constructor for creating a uuid value.
Takes in a string representation of a uuid
to wrap.
Optioanlly, you can disable the validation check in the constructor
by setting validate
to true
.
Implementation
UuidValue(this.uuid, [bool validate = true]) {
if (validate) {
Uuid.isValidUUID(uuid);
}
}