comparison UnitTests/Fluent/MockDataBase/MockReaderResultData.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 using System.Collections.Generic;
3 using System.Linq;
4
5 namespace BLToolkit.Fluent.Test.MockDataBase
6 {
7 public class MockReaderResultData
8 {
9 public MockReaderResultData()
10 {
11 Names = new List<string>();
12 Types = new List<Type>();
13 Values = new List<object[]>();
14 }
15
16 public List<string> Names { get; private set; }
17
18 public List<Type> Types { get; private set; }
19
20 public List<object[]> Values { get; private set; }
21
22 public void SetNames(string[] fields)
23 {
24 Names.Clear();
25 Names.AddRange(fields);
26 Types = Types.Take(Math.Min(Types.Count, Names.Count)).ToList();
27 for (int i = Types.Count; i < Names.Count; i++)
28 {
29 Types.Add(null);
30 }
31 }
32 }
33 }