Beispiel #1
0
        public ViewQueryBase GetViewQuery(string className)
        {
            Type queryPluginType = PagePluginFactory.GetQueryPluginType(className);

            if (queryPluginType != null)
            {
                return(Activator.CreateInstance(queryPluginType, new object[] { this._context, this._user }) as ViewQueryBase);
            }
            return(Activator.CreateInstance(UnityObjectFactory.GetViewQueryType(className), new object[] { this._context, this._user }) as ViewQueryBase);
        }
Beispiel #2
0
        protected void Application_Start(object sender, EventArgs e)
        {
            // Log4Net 日志配置文件处理办法 读取数据库中的配置写入根目录
            //if (File.Exists(Server.MapPath("~/log4net.xml")))
            //{
            //    using (Stream configStream = new StreamReader(Server.MapPath("~/log4net.xml")).BaseStream)
            //    {
            //        log4net.Config.XmlConfigurator.Configure(configStream);
            //    }
            //}

            //初始化对象容器
            UnityObjectFactory ObjectFactory = new UnityObjectFactory();

            EntityCache cache = EntityCache.New();

            //ScheduleTimerManager stm = ScheduleTimerManager.CreateInstance();
            //stm.Start();

            //额外的一些处理,跟在原UploadControl的内部处理之后
            UploadControl.OnProcessRequest = new Action <HttpContext>(p => AttachHandler.ProcessRequest(p));
        }
Beispiel #3
0
 public static IEntitySchema Get(Type entityType)
 {
     return(UnityObjectFactory.GetEntitySchema(entityType));
 }
Beispiel #4
0
 public static IEntitySchema Get(string entityName)
 {
     return(UnityObjectFactory.GetEntitySchema(entityName));
 }
Beispiel #5
0
 public static IEntitySchema Get(long entityId)
 {
     return(UnityObjectFactory.GetEntitySchema(entityId));
 }