using iWareCommon.Common.Dao;
|
using iWareDataCore.BASE.Entity;
|
using iWareDataCore.ORM;
|
using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
using System.Threading.Tasks;
|
|
namespace iWareDataCore.BASE.Dao
|
{
|
public class PlaceDao : CommonDao<PlaceEntity, BASEPlace>
|
{
|
private static object Lock = new object();
|
|
private PlaceDao() { }
|
|
private static PlaceDao Instance = null;
|
|
/// <summary>
|
/// 获取单例的方法
|
/// </summary>
|
/// <returns>角色服务的单例实体</returns>
|
public static PlaceDao GetInstance()
|
{
|
|
if (Instance == null)
|
{
|
lock (Lock)
|
{
|
if (Instance == null)
|
{
|
Instance = new PlaceDao();
|
}
|
}
|
}
|
return Instance;
|
}
|
|
|
protected override string GetColumnName(string name)
|
{
|
return PlaceEntity.GetColumnName(name);
|
}
|
|
protected override string GetTableName()
|
{
|
return PlaceEntity.GetTableName();
|
}
|
|
protected override PlaceEntity ToEntity(BASEPlace s)
|
{
|
return new PlaceEntity(s);
|
}
|
|
protected override BASEPlace ToOrm(PlaceEntity t)
|
{
|
return t.ToOrm();
|
}
|
|
protected override List<string> GetColumnNames()
|
{
|
return PlaceEntity.GetColumnMap().Keys.ToList();
|
}
|
}
|
}
|