addSearchCode method
Adds a searchCode
to the searchCodes array.
Returns true
if the searchCode
was added to the array. If the array
is full, the searchCode
is not added, and false
is returned.
Implementation
bool addSearchCode(String searchCode) {
if (_searchCodes.length < 10) {
_searchCodes.add(searchCode);
return true;
}
return false;
}