Cmdlet.Invoke Method

Definition

Overloads

Invoke()

Invoke this cmdlet object returning a collection of results.

Invoke<T>()

Returns a strongly-typed enumerator for the results of this cmdlet.

Invoke()

Invoke this cmdlet object returning a collection of results.

public:
 System::Collections::IEnumerable ^ Invoke();
public System.Collections.IEnumerable Invoke ();
member this.Invoke : unit -> System.Collections.IEnumerable
Public Function Invoke () As IEnumerable

Returns

IEnumerable

The results that were produced by this class

Invoke<T>()

Returns a strongly-typed enumerator for the results of this cmdlet.

public:
generic <typename T>
 System::Collections::Generic::IEnumerable<T> ^ Invoke();
public System.Collections.Generic.IEnumerable<T> Invoke<T> ();
member this.Invoke : unit -> seq<'T>
Public Function Invoke(Of T) () As IEnumerable(Of T)

Type Parameters

T

The type returned by the enumerator

Returns

IEnumerable<T>

An instance of the appropriate enumerator

Exceptions

Thrown when the object returned by the cmdlet cannot be converted to the target type

Applies to