IEnumerable.IsEmpty(...)
An extension method to look over a sequence of elements and work out whether it is empty or not.
bool IsEmpty<T>(this IEnumerable<T> source)
Parameters
source
: Extends theIEnumerable<T>
interface.
Exeptions
ArgumentNullException
ifsource
is null.
Example
var aSource = Array.Empty<string>();
bool isEmpty = aSource.IsEmpty(); // true
});