using iWareCommon.Common.Dao;
|
using iWareLog.LOG.Entity;
|
using iWareLog.ORM;
|
using System.Collections.Generic;
|
using System.Linq;
|
|
namespace iWareLog.LOG.Dao
|
{
|
public class ReceiveMsgLogDao : CommonDao<ReceiveMsgLogEntity, LOGReceiveMsgLog>
|
{
|
private static object Lock = new object();
|
|
private ReceiveMsgLogDao() { }
|
|
private static ReceiveMsgLogDao Instance = null;
|
|
/// <summary>
|
/// 获取单例的方法
|
/// </summary>
|
/// <returns>log服务的单例实体</returns>
|
public static ReceiveMsgLogDao GetInstance()
|
{
|
|
if (Instance == null)
|
{
|
lock (Lock)
|
{
|
if (Instance == null)
|
{
|
Instance = new ReceiveMsgLogDao();
|
}
|
}
|
}
|
return Instance;
|
}
|
|
|
protected override string GetColumnName(string name)
|
{
|
return ReceiveMsgLogEntity.GetColumnName(name);
|
}
|
|
protected override string GetTableName()
|
{
|
return ReceiveMsgLogEntity.GetTableName();
|
}
|
|
protected override ReceiveMsgLogEntity ToEntity(LOGReceiveMsgLog receive)
|
{
|
return new ReceiveMsgLogEntity(receive);
|
}
|
|
protected override LOGReceiveMsgLog ToOrm(ReceiveMsgLogEntity receive)
|
{
|
return receive.ToOrm();
|
}
|
|
protected override List<string> GetColumnNames()
|
{
|
return ReceiveMsgLogEntity.GetColumnMap().Keys.ToList();
|
}
|
|
}
|
}
|