comparison Source/Mapping/SimpleSourceListMapper.cs @ 0:f990fcb411a9

Копия текущей версии из github
author cin
date Thu, 27 Mar 2014 21:46:09 +0400
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:f990fcb411a9
1 using System;
2
3 using BLToolkit.Reflection;
4
5 namespace BLToolkit.Mapping
6 {
7 public class SimpleSourceListMapper : IMapDataSourceList
8 {
9 [CLSCompliant(false)]
10 public SimpleSourceListMapper(IMapDataSource mapper)
11 {
12 _mapper = mapper;
13 }
14
15 private readonly IMapDataSource _mapper;
16
17 #region IMapDataSourceList Members
18
19 public virtual void InitMapping(InitContext initContext)
20 {
21 }
22
23 public bool SetNextDataSource(InitContext initContext)
24 {
25 initContext.DataSource = _mapper;
26 return _mapper.Count > 0;
27 }
28
29 public virtual void EndMapping(InitContext initContext)
30 {
31 }
32
33 #endregion
34 }
35 }