Udostępnij za pośrednictwem


LanguagePrimitives.GetEnumerator(Object) Method

Definition

Retrieves the IEnumerator of obj or null if the language does not consider obj as capable of returning an IEnumerator.

public:
 static System::Collections::IEnumerator ^ GetEnumerator(System::Object ^ obj);
public static System.Collections.IEnumerator GetEnumerator (object obj);
static member GetEnumerator : obj -> System.Collections.IEnumerator
Public Shared Function GetEnumerator (obj As Object) As IEnumerator

Parameters

obj
Object

IEnumerable or IEnumerable-like object

Returns

Exceptions

When the act of getting the enumerator throws an exception.

Applies to