/// <summary> /// Converts this instance of <see cref="SendingApplicationDto"/> to an instance of <see cref="SendingApplication"/>. /// </summary> /// <param name="dto"><see cref="SendingApplicationDto"/> to convert.</param> public static SendingApplication ToEntity(this SendingApplicationDto dto) { if (dto == null) { return(null); } var entity = new SendingApplication(); entity.SendingApplicationId = dto.SendingApplicationId; entity.SendingApplicationName = dto.SendingApplicationName; entity.SendingApplicationIcon = dto.SendingApplicationIcon; dto.OnEntity(entity); return(entity); }
/// <summary> /// Converts this instance of <see cref="SendingApplication"/> to an instance of <see cref="SendingApplicationDto"/>. /// </summary> /// <param name="entity"><see cref="SendingApplication"/> to convert.</param> public static SendingApplicationDto ToDto(this SendingApplication entity) { if (entity == null) { return(null); } var dto = new SendingApplicationDto(); dto.SendingApplicationId = entity.SendingApplicationId; dto.SendingApplicationName = entity.SendingApplicationName; dto.SendingApplicationIcon = entity.SendingApplicationIcon; entity.OnDto(dto); return(dto); }
/// <summary> /// Invoked when <see cref="ToEntity"/> operation is about to return. /// </summary> /// <param name="dto"><see cref="SendingApplicationDto"/> converted from <see cref="SendingApplication"/>.</param> /// <param name="entity"><see cref="SendingApplication"/> converted from <see cref="SendingApplicationDto"/>.</param> static partial void OnEntity(this SendingApplicationDto dto, SendingApplication entity);
/// <summary> /// Invoked when <see cref="ToDto"/> operation is about to return. /// </summary> /// <param name="dto"><see cref="SendingApplicationDto"/> converted from <see cref="SendingApplication"/>.</param> /// <param name="entity"><see cref="SendingApplication"/> converted from <see cref="SendingApplicationDto"/>.</param> static partial void OnDto(this SendingApplication entity, SendingApplicationDto dto);
/// <summary> /// Invoked when <see cref="ToEntity"/> operation is about to return. /// </summary> /// <param name="dto"><see cref="SendingApplicationDto"/> converted from <see cref="SendingApplication"/>.</param> /// <param name="entity"><see cref="SendingApplication"/> converted from <see cref="SendingApplicationDto"/>.</param> partial static void OnEntity(this SendingApplicationDto dto, SendingApplication entity);
/// <summary> /// Converts this instance of <see cref="SendingApplicationDto"/> to an instance of <see cref="SendingApplication"/>. /// </summary> /// <param name="dto"><see cref="SendingApplicationDto"/> to convert.</param> public static SendingApplication ToEntity(this SendingApplicationDto dto) { if (dto == null) return null; var entity = new SendingApplication(); entity.SendingApplicationId = dto.SendingApplicationId; entity.SendingApplicationName = dto.SendingApplicationName; entity.SendingApplicationIcon = dto.SendingApplicationIcon; dto.OnEntity(entity); return entity; }
static partial void OnDto(this SendingApplication entity, SendingApplicationDto dto) { dto.NotificationTypes = (List <NotificationTypeDto>)entity.NotificationTypes.ToDtos(); dto.Subscribers = (List <SubscriberDto>)entity.Subscribers.ToDtos(); }