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.
38 lines
974 B
38 lines
974 B
using Dto;
|
|
using Entities;
|
|
using Model;
|
|
|
|
namespace Shared.Mapper;
|
|
|
|
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);
|
|
}
|
|
} |