value_objects library Null safety

Classes

EmailAddress
EmailAddress value object holds information about the user's email address.
Name
Name value object is a generic object that should be used to hold instances of names A use case would be firstName, or lastName or userName
PhoneNumber
ValueObject<T>

Extensions

AssistantExt
AssistantExt offers an extension to get string names of the Assistant
GenderEx
GenderEx extends Gender enum to get the values as strings
LoginProviderEx
LoginProviderEx extends LoginProvider enum to get the values as strings
SupplierAccountTypeEx
SupplierAccountTypeEx extends SupplierAccountType enum to get the values as strings
SupplierPartnerTypeEx
SupplierPartnerTypeEx extends SupplierPartnerType enum to get the values as strings

Constants

UNKNOWN → const String
'UNKNOWN'
UNKNOWNEMAIL → const String
'unknown@bewell.co.ke'

Functions

validateEmailAddress(String input) Either<ValueObjectFailure<String>, String>
validateEmailAddress checks for the validity of the provided input
validatePhoneNumber(String input) Either<ValueObjectFailure<String>, String>

Enums

Assistant
Assistant is the user assistant
Gender
Gender
LoginProvider
LoginProvider represents valid login methods
SupplierAccountType
SupplierAccountType valid supplier account types
SupplierPartnerType
SupplierPartnerType valid supplier partner types