Swiss Army Knife
General utility tools for Scada Minds
Static Public Member Functions | List of all members
EnumerableProducingExtensions Class Reference

Various extensions to succinctly produce IEnumerables out of single items. More...

Static Public Member Functions

static IEnumerable< T > Yield< T > (this T item)
 Wraps this object instance into an IEnumerable; consisting of a single item. More...
 
static async IAsyncEnumerable< T > YieldAsync< T > (this T item)
 Wraps this object instance into an IAsyncEnumerable; consisting of a single item. More...
 

Detailed Description

Various extensions to succinctly produce IEnumerables out of single items.

Member Function Documentation

◆ Yield< T >()

static IEnumerable<T> Yield< T > ( this T  item)
inlinestatic

Wraps this object instance into an IEnumerable; consisting of a single item.

Template Parameters
TType of the object.
Parameters
itemThe instance that will be wrapped.
Returns
An IEnumerable consisting of a single item.

◆ YieldAsync< T >()

static async IAsyncEnumerable<T> YieldAsync< T > ( this T  item)
inlinestatic

Wraps this object instance into an IAsyncEnumerable; consisting of a single item.

Template Parameters
TType of the object.
Parameters
itemThe instance that will be wrapped.
Returns
An IAsyncEnumerable consisting of a single item.

The documentation for this class was generated from the following file: