CastEnumeratorTo()

System::CastEnumeratorTo(const System::SharedPtr<System::Collections::Generic::IEnumerator<From>>&) function

Performs a type cast of the enumerator by explicitly casting the type of each element over which the source enumerator iterates.

template<class From,class To> System::SharedPtr<System::Collections::Generic::IEnumerator<To>> System::CastEnumeratorTo(const System::SharedPtr<System::Collections::Generic::IEnumerator<From>> &enumerator)

Template parameters

ParameterDescription
FromType argument of enumerator to cast
ToType argument of resulting enumerator

Arguments

ParameterTypeDescription
enumeratorconst System::SharedPtr<System::Collections::Generic::IEnumerator<From>>&Enumerator to cast

See Also