本文整理汇总了C#中IDataReader.GetSafeDateTime方法的典型用法代码示例。如果您正苦于以下问题:C# IDataReader.GetSafeDateTime方法的具体用法?C# IDataReader.GetSafeDateTime怎么用?C# IDataReader.GetSafeDateTime使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IDataReader
的用法示例。
在下文中一共展示了IDataReader.GetSafeDateTime方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: mapFaq
private static FAQ mapFaq(IDataReader reader)
{
FAQ p = new FAQ();
int startingIndex = 0; //startingOrdinal
p.Id = reader.GetSafeInt32(startingIndex++);
p.SortOrder = reader.GetSafeInt32(startingIndex++);
p.Question = reader.GetSafeString(startingIndex++);
p.Answer = reader.GetSafeString(startingIndex++);
p.Category = reader.GetSafeInt32(startingIndex++);
p.DateAdded = reader.GetSafeDateTime(startingIndex++);
p.DateModified = reader.GetSafeDateTime(startingIndex++);
p.LanguageCode = reader.GetSafeString(startingIndex++);
p.userId = reader.GetSafeString(startingIndex++);
return p;
}
示例2: MapSiteLink
private SiteLink MapSiteLink(IDataReader reader)
{
SiteLink s = new SiteLink();
int startingIndex = 0;
s.Id = reader.GetSafeInt32(startingIndex++);
s.Url = reader.GetSafeString(startingIndex++);
s.Type = reader.GetSafeInt32(startingIndex++);
s.Group = reader.GetSafeInt16(startingIndex++);
s.OwnerId = reader.GetSafeInt32(startingIndex++);
s.OwnerType = reader.GetSafeInt32(startingIndex++);
s.DateAdded = reader.GetSafeDateTime(startingIndex++);
s.DateModified = reader.GetSafeDateTime(startingIndex++);
s.LanguageCode = reader.GetSafeString(startingIndex++);
return s;
}
示例3: MapCourse
private static Course MapCourse(IDataReader reader)
{
Course item = new Course();
int startingIndex = 0;
item.Id = reader.GetSafeInt32(startingIndex++);
item.CourseName = reader.GetSafeString(startingIndex++);
item.Length = reader.GetSafeString(startingIndex++);
item.Description = reader.GetSafeString(startingIndex++);
item.Start = reader.GetSafeDateTime(startingIndex++);
item.End = reader.GetSafeDateTime(startingIndex++);
item.CourseLength = reader.GetSafeInt32(startingIndex++);
item.LearningObjectives = reader.GetSafeString(startingIndex++);
item.ExpectedOutcome = reader.GetSafeString(startingIndex++);
item.EvaluationCriteria = reader.GetSafeString(startingIndex++);
item.Format = reader.GetSafeInt32(startingIndex++);
return item;
}
示例4: MapBlog
private static Blog MapBlog(IDataReader reader)
{
Blog p = new Blog();
////bool isBlogPostData = false;
//if (reader.FieldCount == 12)
//{
// p = new Blog();
//}
//else
//{
// p = new Blog();
// isBlogPostData = true;
//}
int startingIndex = 0;
p.ID = reader.GetSafeInt32(startingIndex++);
p.Title = reader.GetSafeString(startingIndex++);
p.Content = reader.GetSafeString(startingIndex++);
p.LiveDate = reader.GetSafeDateTime(startingIndex++);
p.Status = reader.GetSafeInt32(startingIndex++);
p.MetaData = reader.GetSafeString(startingIndex++);
p.PathName = reader.GetSafeString(startingIndex++);
string UserID = reader.GetSafeString(startingIndex++);
p.DateAdded = reader.GetSafeDateTime(startingIndex++);
p.DateModified = reader.GetSafeDateTime(startingIndex++);
p.LanguageCode = reader.GetSafeString(startingIndex++);
p.CountOfComments = reader.GetSafeInt32(startingIndex++);
//p.Preview = reader.GetSafeString(startingIndex++);
//here instead of Blog use the new Domain Object
p.FirstName = reader.GetSafeString(startingIndex++);
p.LastName = reader.GetSafeString(startingIndex++);
p.Preview = reader.GetSafeString(startingIndex++);
//DO NOT INCLUDE HERE p.CountOfComments = reader.GetSafeInt32(startingIndex++);
//in here read out the extra properties
return p;
}
示例5: MapPageMetaTag
private PageMetaTag MapPageMetaTag(IDataReader reader)
{
PageMetaTag p = new PageMetaTag();
int startingIndex = 0; //startingOrdinal
p.Id = reader.GetSafeInt32(startingIndex++);
p.MetaTagId = reader.GetSafeInt32(startingIndex++);
p.Value = reader.GetSafeString(startingIndex++);
p.OwnerId = reader.GetSafeInt32(startingIndex++);
p.OwnerType = reader.GetSafeInt32(startingIndex++);
p.DateAdded = reader.GetSafeDateTime(startingIndex++);
p.DateModified = reader.GetSafeDateTime(startingIndex++);
p.LanguageCode = reader.GetSafeString(startingIndex++);
return p;
}
示例6: MapQuickQuestion
private static QuickQuestion MapQuickQuestion(IDataReader reader)
{
QuickQuestion qq = new QuickQuestion();
int startingIndex = 0;
qq.Id = reader.GetSafeInt32(startingIndex++);
qq.Question = reader.GetSafeString(startingIndex++);
qq.Status = reader.GetSafeInt32(startingIndex++);
qq.DateAdded = reader.GetSafeDateTime(startingIndex++);
qq.DateModified = reader.GetSafeDateTime(startingIndex++);
qq.LanguageCode = reader.GetSafeString(startingIndex++);
qq.CommentCount = reader.GetSafeInt32(startingIndex++);
qq.BeenConverted = reader.GetSafeBool(startingIndex++);
qq.ForumThreadId = reader.GetSafeInt32(startingIndex++);
return qq;
}
示例7: MapWikiPage
private static WikiPage MapWikiPage(IDataReader reader)
{
WikiPage wiki = new WikiPage();
int startingIndex = 0;
wiki.Id = reader.GetSafeInt32(startingIndex++);
wiki.Title = reader.GetSafeString(startingIndex++);
wiki.URL = reader.GetSafeString(startingIndex++);
wiki.PublishDate = reader.GetSafeDateTime(startingIndex++);
wiki.Language = reader.GetSafeInt32(startingIndex++);
wiki.ParentId = reader.GetSafeInt32(startingIndex++);
return wiki;
}
示例8: MapMetaTag
private void MapMetaTag(IDataReader reader, MetaTag m)
{
int startingIndex = 0;
m.Id = reader.GetSafeInt32(startingIndex++);
m.Name = reader.GetSafeString(startingIndex++);
m.Description = reader.GetSafeString(startingIndex++);
m.Example = reader.GetSafeString(startingIndex++);
m.Template = reader.GetSafeString(startingIndex++);
m.DateAdded = reader.GetSafeDateTime(startingIndex++);
m.DateModified = reader.GetSafeDateTime(startingIndex++);
m.LanguageCode = reader.GetSafeString(startingIndex++);
}
示例9: PaymentMap
private Payment PaymentMap(IDataReader reader)
{
Payment p = new Payment();
int startingIndex = 0;
p.Id = reader.GetSafeInt32(startingIndex++);
p.DateAdded = reader.GetSafeDateTime(startingIndex++);
p.DateModified = reader.GetSafeDateTime(startingIndex++);
p.LoanAmount = reader.GetSafeInt32(startingIndex++);
p.LoanTerm = reader.GetSafeInt32(startingIndex++);
p.LoanApr = reader.GetDouble(startingIndex++);
p.PurchasePrice = reader.GetSafeInt32(startingIndex++);
p.CarMake = reader.GetSafeInt32(startingIndex++);
p.CarModel = reader.GetSafeInt32(startingIndex++);
p.CarYear = reader.GetSafeInt32(startingIndex++);
p.CarCondition = reader.GetSafeInt32(startingIndex++);
return p;
}
示例10: MapEvent
private static Event MapEvent(IDataReader reader)
{
Event e = new Event();
int startingIndex = 0; //startingOrdinal
e.Id = reader.GetSafeInt32(startingIndex++);
e.Title = reader.GetSafeString(startingIndex++);
e.Description = reader.GetSafeString(startingIndex++);
e.EventTime = reader.GetSafeDateTime(startingIndex++);
e.VenueName = reader.GetSafeString(startingIndex++);
e.Url = reader.GetSafeUri(startingIndex++);
e.Type = reader.GetSafeString(startingIndex++);
e.Tags = reader.GetSafeString(startingIndex++);
e.DateAdded = reader.GetSafeDateTime(startingIndex++);
e.DateModified = reader.GetSafeDateTime(startingIndex++);
e.LanguageCode = reader.GetSafeString(startingIndex++);
return e;
}
示例11: MapComment
private static UserComment MapComment(IDataReader reader)
{
UserComment c = new UserComment();
int startingIndex = 0;
c.Id = reader.GetSafeInt32(startingIndex++);
c.Comment = reader.GetSafeString(startingIndex++);
c.CommentDate = reader.GetSafeDateTime(startingIndex++);
c.IsFlagged = reader.GetSafeBool(startingIndex++);
c.IsVisible = reader.GetSafeBool(startingIndex++);
c.ParentId = reader.GetSafeInt32(startingIndex++, null);
c.OwnerId = reader.GetSafeInt32(startingIndex++);
c.OwnerType = reader.GetSafeEnum<CommentOwnerType>(startingIndex++);
c.Deleted = reader.GetSafeBool(startingIndex++);
c.DeletedDate = reader.GetSafeDateTime(startingIndex++);
c.LanguageCode = reader.GetSafeString(startingIndex++);
c.UpdateDate = reader.GetSafeDateTime(startingIndex++);
c.Title = reader.GetSafeString(startingIndex++);
c.Profile.Handle = reader.GetSafeString(startingIndex++);
c.Profile.Avatar = reader.GetSafeString(startingIndex++);
return c;
}
示例12: MapPlanFeature
private static PlanFeature MapPlanFeature(IDataReader reader)
{
PlanFeature pf = new PlanFeature();
PriorityLevel pl = new PriorityLevel();
int startingIndex = 0;
pf.Id = reader.GetSafeInt32(startingIndex++);
pf.Title = reader.GetSafeString(startingIndex++);
pf.Description = reader.GetSafeString(startingIndex++);
pf.Category = reader.GetSafeInt32(startingIndex++);
pf.PlanId = reader.GetSafeInt32(startingIndex++);
pf.DateAdded = reader.GetSafeDateTime(startingIndex++);
pf.DateModified = reader.GetSafeDateTime(startingIndex++);
pf.LanguageCode = reader.GetSafeString(startingIndex++);
pl.Name = reader.GetSafeString(startingIndex++);
pl.Id = reader.GetSafeInt32(startingIndex++);
pf.SortOrder = pl;
return pf;
}
示例13: MapPlan
private static Plan MapPlan(IDataReader reader)
{
Plan p = new Plan();
PlanType pt = new PlanType();
int startingIndex = 0;
p.Id = reader.GetSafeInt32(startingIndex++);
p.Name = reader.GetSafeString(startingIndex++);
p.Description = reader.GetSafeString(startingIndex++);
p.Cost = reader.GetSafeInt32(startingIndex++);
p.GoLiveDate = reader.GetSafeDateTime(startingIndex++);
p.DateAdded = reader.GetSafeDateTime(startingIndex++);
p.DateModified = reader.GetSafeDateTime(startingIndex++);
p.LanguageCode = reader.GetSafeString(startingIndex++);
p.Tag = reader.GetSafeString(startingIndex++);
int secondIndex = 9;
pt.Name = reader.GetSafeString(secondIndex++);
pt.Id = reader.GetSafeInt32(secondIndex++);
p.Type = pt;
return p;
}
示例14: OfficeHourMap
private OfficeHour OfficeHourMap(IDataReader reader)
{
OfficeHour item = new OfficeHour();
int startingIndex = 0;
item.Id = reader.GetSafeInt32(startingIndex++);
item.InstructorId = reader.GetSafeInt32(startingIndex++);
item.Date = reader.GetSafeDateTime(startingIndex++);
item.StartTime = reader.GetSafeInt32(startingIndex++);
item.EndTime = reader.GetSafeInt32(startingIndex++);
item.TimeZone = reader.GetSafeInt32(startingIndex++);
item.Topic = reader.GetSafeString(startingIndex++);
item.Instructions = reader.GetSafeString(startingIndex++);
item.SectionId = reader.GetSafeInt32(startingIndex++);
return item;
}
示例15: MapAnalytics
private AnalyticEvent MapAnalytics(IDataReader reader)
{
AnalyticEvent p = new AnalyticEvent();
int startingIndex = 0; //startingOrdinal
p.Id = reader.GetSafeInt32(startingIndex++);
p.UserId = reader.GetSafeString(startingIndex++);
p.Category = reader.GetSafeInt32(startingIndex++);
p.Action = reader.GetSafeInt32(startingIndex++);
p.Value = reader.GetSafeString(startingIndex++);
p.Data = reader.GetSafeString(startingIndex++);
p.DateAdded = reader.GetSafeDateTime(startingIndex++);
p.DateModified = reader.GetSafeDateTime(startingIndex++);
p.LanguageCode = reader.GetSafeString(startingIndex++);
p.PageUrl = reader.GetSafeString(startingIndex++);
p.PageType = reader.GetSafeInt32(startingIndex++);
return p;
}