CollectionHelperConvertTSource, TDestination Method |
Namespace:
Xcalibur.Helpers
Assembly:
Xcalibur.Helpers (in Xcalibur.Helpers.dll) Version: 1.0.1.0 (1.0.1.0)
Syntax public static IEnumerable<TDestination> Convert<TSource, TDestination>(
this IEnumerable<TSource> source
)
where TDestination : new()
<ExtensionAttribute>
Public Shared Function Convert(Of TSource, TDestination As New) (
source As IEnumerable(Of TSource)
) As IEnumerable(Of TDestination)
public:
[ExtensionAttribute]
generic<typename TSource, typename TDestination>
where TDestination : gcnew()
static IEnumerable<TDestination>^ Convert(
IEnumerable<TSource>^ source
)
[<ExtensionAttribute>]
static member Convert :
source : IEnumerable<'TSource> -> IEnumerable<'TDestination> when 'TDestination : new()
Parameters
- source
- Type: System.Collections.GenericIEnumerableTSource
The source list of type TSource.
Type Parameters
- TSource
- The type of the source.
- TDestination
- The type of the destination.
Return Value
Type:
IEnumerableTDestinationUsage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
IEnumerableTSource. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also