Пример #1
0
 /// <summary>
 /// Returns the value of <paramref name="maybeCollection"/> if exists orlse an empty collection
 /// </summary>
 /// <typeparam name="T"></typeparam>
 /// <param name="maybeCollection"></param>
 /// <returns></returns>
 public static IEnumerable <T> FromMaybe <T>(this Maybe <IEnumerable <T> > maybeCollection)
 {
     return(maybeCollection.HasValue ? maybeCollection.Value : Enumerable.Empty <T>());
 }