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.

32 lines
1.0 KiB

using EFlib;
using Model;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace EFManager
{
public static class ManagerTranslate
{
// Champion
public static EFChampion toEF(this Champion Champ) => new EFChampion { Name = Champ.Name, Bio = Champ.Bio, Icon = Champ.Icon };
public static Champion toModel(this EFChampion EFChamp) => new Champion(EFChamp.Name);
// Skin
public static EFSkin toEF(this Skin Skin) => new EFSkin { Name = Skin.Name, Description = Skin.Description, Icon = Skin.Icon, Price = Skin.Price };
public static Skin toModel(this EFSkin EFSkin) => new Skin(EFSkin.Name, EFSkin.Champion.toModel());
// Skill
// Rune
// LargeImage
public static EFLargeImage toEF(this LargeImage LargeImage) => new EFLargeImage { Id = Guid.NewGuid(), Base64 = LargeImage.Base64 };
public static LargeImage toModel(this EFLargeImage EFlargeImage) => new LargeImage(EFlargeImage.Base64);
}
}