本文整理汇总了C#中IDataReader.ColumnValue方法的典型用法代码示例。如果您正苦于以下问题:C# IDataReader.ColumnValue方法的具体用法?C# IDataReader.ColumnValue怎么用?C# IDataReader.ColumnValue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IDataReader
的用法示例。
在下文中一共展示了IDataReader.ColumnValue方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetFromReader
private static ISynonym GetFromReader(ref int columnIndex, IDataReader reader)
{
var id = reader.ColumnValue(columnIndex++, default(long));
var source = reader.ColumnValue(columnIndex++, String.Empty);
var result = reader.ColumnValue(columnIndex++, String.Empty);
var created = reader.ColumnValue(columnIndex++, DateTime.MaxValue);
var thing = new Data.DO.Synonym
{
ID = id,
Source = source,
Result = result,
Created = created
};
return thing;
}
示例2: GetFromReader
private static IFeedback GetFromReader(ref int columnIndex, IDataReader reader)
{
var id = reader.ColumnValue(columnIndex++, default(long));
var contact = reader.ColumnValue(columnIndex++, String.Empty);
var name = reader.ColumnValue(columnIndex++, String.Empty);
var body = reader.ColumnValue(columnIndex++, String.Empty);
var created = reader.ColumnValue(columnIndex++, DateTime.MaxValue);
var thing = new Data.DO.Feedback
{
ID = id,
Contact = contact,
Name = name,
Body = body,
Created = created
};
return thing;
}
示例3: GetFromReader
private static ITranslation GetFromReader(ref int columnIndex, IDataReader reader)
{
var id = reader.ColumnValue(columnIndex++, default(long));
var unknowns = reader.ColumnValue(columnIndex++, String.Empty).Split('|');
var rejected = reader.ColumnValue(columnIndex++, String.Empty).Split('|');
var results = DecodeTranslationResults(reader.ColumnValue(columnIndex++, String.Empty));
var source = reader.ColumnValue(columnIndex++, String.Empty);
var created = reader.ColumnValue(columnIndex++, DateTime.MaxValue);
var thing = new Data.DO.Translation
{
ID = id,
Unknowns = unknowns,
Rejected = rejected,
Results = results,
Source = source,
Created = created
};
return thing;
}
示例4: GetFromReader
private static String GetFromReader(ref int columnIndex, IDataReader reader)
{
var word = reader.ColumnValue(columnIndex++, String.Empty);
return word;
}