getUserType method
Get the user-defined type information for a specific type.
Returns the UserType information for the given type
based on the
registered user types in userTypes.
Implementation
UserType getUserType(TypeInfo type) {
return userTypes.firstWhere((x) => x.name == type.name);
}