public static EntityContact ReadFromDTO(EntityContact target, EntityContactDTO source)
 {
     ContactDetailTX.ReadFromDTO(target.ContactDetail, source.ContactDetail);
     ContactTypeTX.ReadFromDTO(target.ContactType, source.ContactType);
     EntityTX.ReadFromDTO(target.Entity, source.Entity);
     target.ContactId     = source.ContactId;
     target.EntityId      = source.EntityId;
     target.ContactTypeId = source.ContactTypeId;
     target.ModifiedDate  = source.ModifiedDate;
     return(target);
 }
 public static EntityContactDTO WriteToDTO(EntityContact source)
 {
     return(new EntityContactDTO
     {
         ContactDetail = ContactDetailTX.WriteToDTO(source.ContactDetail),
         ContactType = ContactTypeTX.WriteToDTO(source.ContactType),
         Entity = EntityTX.WriteToDTO(source.Entity),
         ContactId = source.ContactId,
         EntityId = source.EntityId,
         ContactTypeId = source.ContactTypeId,
         ModifiedDate = source.ModifiedDate,
     });
 }