本文整理汇总了C#中IDataReader.ReadDateTimeOrNull方法的典型用法代码示例。如果您正苦于以下问题:C# IDataReader.ReadDateTimeOrNull方法的具体用法?C# IDataReader.ReadDateTimeOrNull怎么用?C# IDataReader.ReadDateTimeOrNull使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IDataReader
的用法示例。
在下文中一共展示了IDataReader.ReadDateTimeOrNull方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: DocumentVersion
public DocumentVersion(IDataReader reader)
: this()
{
VersionId = reader.GetInt64(0);
DocumentId = reader.GetInt64(1);
MessageId = reader.ReadInt64OrNull(2);
Filename = reader.GetString(3);
SourceChannelId = reader.GetInt64(4);
TargetChannelId = reader.GetInt64(5);
From = new SourceAddress(reader.GetString(6));
To = new SourceAddressCollection(reader.GetString(7));
StreamName = reader.GetString(8);
Crc32 = reader.GetString(9);
Size = reader.GetInt32(10);
DateReceived = reader.ReadDateTimeOrNull(11);
DateSent = reader.ReadDateTimeOrNull(12);
DateCreated = reader.ReadDateTimeOrNull(13);
DateModified = reader.ReadDateTimeOrNull(14);
}
示例2: Person
public Person(IDataReader reader)
: this()
{
PersonId = reader.GetInt64(0);
if (!reader.IsDBNull(1))
PersonKey = reader.GetString(1);
if (!reader.IsDBNull(2))
RedirectPersonId = reader.ReadInt64OrNull(2);
if (!reader.IsDBNull(3))
SourceChannelId = reader.GetInt64(3);
if (!reader.IsDBNull(4))
Firstname = reader.GetString(4);
if (!reader.IsDBNull(5))
Lastname = reader.GetString(5);
if (!reader.IsDBNull(6))
DateOfBirth = reader.ReadDateTimeOrNull(6);
if (!reader.IsDBNull(7))
Locale = reader.GetString(7);
if (!reader.IsDBNull(8))
Gender = reader.GetString(8);
if (!reader.IsDBNull(9))
Timezone = reader.GetString(9);
if (!reader.IsDBNull(10))
DateCreated = reader.ReadDateTime(10);
}
示例3: UserStatus
public UserStatus(IDataReader reader)
: this()
{
StatusId = reader.GetInt64(0);
StatusKey = reader.GetString(1);
ParentKey = reader.GetString(2);
ProfileId = reader.GetInt64(3);
SourceChannelId = reader.GetInt64(4);
TargetChannelId = reader.GetString(5);
ChannelStatusKey = reader.GetString(6);
From = new SourceAddress(reader.GetString(7));
To = new SourceAddress(reader.GetString(8));
Status = reader.GetString(9);
InReplyTo = reader.GetString(10);
StatusType = reader.GetInt32(11);
SearchKeyword = reader.GetString(12);
IsRead = reader.ReadBoolean(13);
SortDate = reader.ReadDateTime(14);
DateRead = reader.ReadDateTimeOrNull(15);
DateCreated = reader.ReadDateTime(16);
}
示例4: Document
public Document(IDataReader reader)
: this()
{
DocumentId = reader.GetInt64(0);
if (!reader.IsDBNull(1))
Filename = reader.GetString(1);
if (!reader.IsDBNull(2))
SourceChannelId = reader.GetInt64(2);
if (!reader.IsDBNull(3))
TargetChannelId = reader.GetInt64(3);
if (!reader.IsDBNull(4))
ContentType = (ContentType) Enum.Parse(typeof (ContentType), reader.GetString(4));
if (!reader.IsDBNull(5))
ContentId = reader.GetString(5);
if (!reader.IsDBNull(6))
DocumentKey = reader.GetString(6);
if (!reader.IsDBNull(7))
StreamName = reader.GetString(7);
if (!reader.IsDBNull(8))
Crc32 = reader.GetString(8);
if (!reader.IsDBNull(9))
Size = reader.GetInt32(9);
if (!reader.IsDBNull(10))
IsRead = reader.ReadBoolean(10);
if (!reader.IsDBNull(11))
DocumentFolder = reader.GetInt32(11);
if (!reader.IsDBNull(12))
Labels = reader.GetString(12);
if (!reader.IsDBNull(13))
DateReceived = reader.ReadDateTimeOrNull(13);
if (!reader.IsDBNull(14))
DateSent = reader.ReadDateTimeOrNull(14);
if (!reader.IsDBNull(15))
DateCreated = reader.ReadDateTimeOrNull(15);
if (!reader.IsDBNull(16))
DateModified = reader.ReadDateTimeOrNull(16);
}
示例5: Message
public Message(IDataReader reader)
: this()
{
MessageId = reader.GetInt64(0);
if (!reader.IsDBNull(1))
MessageKey = reader.GetString(1);
if (!reader.IsDBNull(2))
MessageNumber = reader.GetString(2);
if (!reader.IsDBNull(3))
MessageIdentifier = reader.GetString(3);
if (!reader.IsDBNull(4))
InReplyTo = reader.GetString(4);
if (!reader.IsDBNull(5))
SourceFolder = reader.GetString(5);
if (!reader.IsDBNull(6))
Size = reader.GetInt64(6);
if (!reader.IsDBNull(7))
ConversationIdentifier = reader.GetString(7);
if (!reader.IsDBNull(8))
SourceChannelId = reader.GetInt64(8);
if (!reader.IsDBNull(9))
TargetChannelId = reader.GetInt64(9);
if (!reader.IsDBNull(10))
MessageFolder = reader.GetInt32(10);
if (!reader.IsDBNull(11))
From = new SourceAddress(reader.GetString(11));
if (!reader.IsDBNull(12))
ReturnTo = new SourceAddress(reader.GetString(12));
if (!reader.IsDBNull(13))
To = new SourceAddressCollection(reader.GetString(13));
if (!reader.IsDBNull(14))
CC = new SourceAddressCollection(reader.GetString(14));
if (!reader.IsDBNull(15))
BCC = new SourceAddressCollection(reader.GetString(15));
if (!reader.IsDBNull(16))
Context = reader.GetString(16);
if (!reader.IsDBNull(17))
BodyTextStreamName = reader.ReadGuidOrNull(17);
if (!reader.IsDBNull(18))
BodyHtmlStreamName = reader.ReadGuidOrNull(18);
if (!reader.IsDBNull(19))
Labels = reader.GetString(19);
if (!reader.IsDBNull(20))
SendLabels = reader.GetString(20);
if (!reader.IsDBNull(21))
IsRead = reader.ReadBoolean(21);
if (!reader.IsDBNull(22))
IsStarred = reader.ReadBoolean(22);
if (!reader.IsDBNull(23))
{
var str = reader.GetString(23);
if (!String.IsNullOrEmpty(str))
TargetMessageState = (EntityStates)Enum.Parse(typeof(EntityStates), str);
}
if (!reader.IsDBNull(24))
DateRead = reader.ReadDateTimeOrNull(24);
if (!reader.IsDBNull(25))
DateAction = reader.ReadDateTimeOrNull(25);
if (!reader.IsDBNull(26))
DateReply = reader.ReadDateTimeOrNull(26);
if (!reader.IsDBNull(27))
DateReceived = reader.ReadDateTimeOrNull(27);
if (!reader.IsDBNull(28))
DateSent = reader.ReadDateTimeOrNull(28);
}