You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
1.2 KiB
45 lines
1.2 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Entities.SQLuedoDB;
|
|
using Model.Business;
|
|
using Model.DTO;
|
|
|
|
namespace Model.Mappers
|
|
{
|
|
public static class BlackListMapper
|
|
{
|
|
public static BlackListDTO FromModelToDTO(BlackList model)
|
|
{
|
|
return new BlackListDTO(model.Email, model.ExpirationDate);
|
|
}
|
|
|
|
public static BlackListDTO FromEntityToDTO(BlackListEntity ent)
|
|
{
|
|
return new BlackListDTO(ent.Email, ent.ExpirationDate);
|
|
}
|
|
|
|
public static BlackList FromDTOToModel(BlackListDTO dto)
|
|
{
|
|
return new BlackList(dto.Email, dto.ExpirationDate);
|
|
}
|
|
|
|
public static BlackList FromEntityToModel(BlackListEntity ent)
|
|
{
|
|
return new BlackList(ent.Email, ent.ExpirationDate);
|
|
}
|
|
|
|
public static BlackListEntity FromDTOToEntity(BlackListDTO dto)
|
|
{
|
|
return new BlackListEntity(dto.Email, dto.ExpirationDate);
|
|
}
|
|
|
|
public static BlackListEntity FromModelToEntity(BlackList model)
|
|
{
|
|
return new BlackListEntity(model.Email, model.ExpirationDate);
|
|
}
|
|
}
|
|
}
|