using iWareCommon.Common.Dao; using iWareDataCore.ORM; using iWareDataCore.RBAC.Entity; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace iWareDataCore.RBAC.Dao { public class ContentDao : CommonDao { private static object Lock = new object(); private ContentDao() { } private static ContentDao Instance = null; /// /// 获取单例的方法 /// /// 菜单服务的单例实体 public static ContentDao GetInstance() { if (Instance == null) { lock (Lock) { if (Instance == null) { Instance = new ContentDao(); } } } return Instance; } protected override string GetColumnName(string name) { return ContentEntity.GetColumnName(name); } protected override string GetTableName() { return ContentEntity.GetTableName(); } protected override ContentEntity ToEntity(RBACContent s) { return new ContentEntity(s); } protected override RBACContent ToOrm(ContentEntity t) { return t.ToOrm(); } protected override List GetColumnNames() { return ContentEntity.GetColumnMap().Keys.ToList(); } } }