Skip to content

Instantly share code, notes, and snippets.

@mehmetalierol
Created September 9, 2018 15:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mehmetalierol/22d41cd4758ac287e709b172aa883d11 to your computer and use it in GitHub Desktop.
Save mehmetalierol/22d41cd4758ac287e709b172aa883d11 to your computer and use it in GitHub Desktop.
using Company.Application.Common.Dto;
namespace Company.Application.Dto
{
/// <summary>
/// Veritabanımızda bulunan diller üzerinde CRUD (Create, Read, Update, Delete) işlemler için language entity mizi kullanacağız.
/// Bu Dto ise veritabanı ile etkileşimin son anına kadar verileri saklama ve proje içerisinde kullanma görevlerini icra edecek.
/// Entity lerimiz ve dto larımız arasında veri transferini ise AutoMapper yardımı ile yapacağız.
/// Aşağıdaki propertylerin adları language entity içindeki propertyle ile aynı olmalı, yoksa mapper içerisinde profiller oluştururken özel kurallar yazmamız gerekir.
/// İsimler aynı olursa AutoMapper otomatik olarak hangi property nin Dto daki hangi propertye eşit olduğunu anlayacak ve atamaları yapacak.
/// </summary>
public class LanguageDto : DtoBase
{
/// <summary>
/// Dilin adı
/// </summary>
public string Name { get; set; }
/// <summary>
/// Dilin culture kodu (Örnek: TR-tr, EN-us ... vs)
/// </summary>
public string Culture { get; set; }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment