Пример #1
0
 internal Session(Database Database, IO.Session IO)
 {
     this.ItemCache   = new Dictionary <String, Cache.Item>();
     this.OptimiseAML = true;
     this.Database    = Database;
     this.IO          = IO;
     this.BuildCaches();
 }
Пример #2
0
        public Session Login(String Username, String Password)
        {
            lock (this.SessionCacheLock)
            {
                if (!this.SessionCache.ContainsKey(Username))
                {
                    IO.Session iosession = this.IO.Login(Username, Password);
                    this.SessionCache[Username] = new Session(this, iosession);
                }

                return(this.SessionCache[Username]);
            }
        }