UniqueList<E> constructor
Constructs a new UniqueList.
If strict
is true
, a DuplicateValueError will be thrown when a value
is added to the list that already exists in the list.
If nullable
is true
, the list may contain multiple instances of null
,
otherwise, null
will be treated like any other value and only
one instance of null
may be contained in the list.
Implementation
UniqueList({
bool strict = false,
bool nullable = true,
bool growable = true,
}) : nullable = false,
strict = false,
super(<E>[], growable: growable);