示例#1
0
 public static School Map(this ResumeSchoolEntity entity)
 {
     return(new School
     {
         Id = entity.id,
         City = entity.city,
         Country = entity.country,
         Degree = entity.degree,
         Description = entity.description,
         Institution = entity.institution,
         Major = entity.major,
         CompletionDate = ((IHavePartialCompletionDateEntity)entity).Map(),
     });
 }
示例#2
0
        private static ResumeSchoolEntity Map(this ISchool school, Guid resumeId)
        {
            var entity = new ResumeSchoolEntity
            {
                id          = school.Id,
                resumeId    = resumeId,
                city        = school.City,
                country     = school.Country,
                degree      = school.Degree,
                description = school.Description,
                institution = school.Institution,
                major       = school.Major,
            };

            school.CompletionDate.MapTo(entity);
            return(entity);
        }