예제 #1
0
        public static TProjection ProjectedAs <TProjection>(this object item) where TProjection : class
        {
            var adapter = TypeAdapterFactory.CreateAdapter();

            return(adapter.Adapt <TProjection>(item));
        }
예제 #2
0
        public static List <TProjection> ProjectedAsCollection <TProjection>(this IEnumerable items) where TProjection : class
        {
            var adapter = TypeAdapterFactory.CreateAdapter();

            return(adapter.Adapt <List <TProjection> >(items));
        }