Esempio n. 1
0
        public void FieldTypeWithNoValue()
        {
            var row = new RowHeader
            {
                HasRows = true,
                Names   = new List <string> {
                    "cola", "colb"
                },
                Types = new List <int> {
                    (int)FieldType.String, (int)FieldType.Object
                }
            };

            Assert.AreEqual(row.GetType(0), typeof(string));
            Assert.AreEqual(row.GetType(1), typeof(object));
        }
Esempio n. 2
0
 /// <inheritdoc />
 public Type GetFieldType(int i)
 {
     if (null == _currentRowHeader)
     {
         throw new InvalidOperationException();
     }
     return(_currentRowHeader.GetType(i));
 }
Esempio n. 3
0
        public void FieldTypeObjectWithNoValue()
        {
            var r = new RowHeader {
                HasRows = true,
                Names   = new List <string> {
                    "cola"
                },
                Types = new List <int> {
                    (int)FieldType.Object
                }
            };

            Assert.AreEqual(r.GetType(0), typeof(object));
        }