public Cache() { this.LogThreshold = Kean.Error.Level.Message; this.AllThreshold = Kean.Error.Level.Critical; this.cache = new Collection.Wrap.ListQueue<Error.IError>(this.cacheList); this.Writers = new Kean.Collection.List<Writer.Abstract>(); }
public Long(string[] photoPaths) { this.buffer = new Collection.Synchronized.Queue <Raster.Image>(); this.PhotoPaths = photoPaths; this.Wrap = (this.Count <= 1000); // If the number of photos is larger than some arbitrary value, playback should not loop. this.loader = Parallel.RepeatThread.Start("PhotoLoader", this.Wrap ? (Action)this.WrappingLoader : this.Loader); }
WriteBuffer() { this.queue = new Collection.Synchronized.Queue<System.Collections.Generic.IEnumerable<char>>(); this.timer = new System.Timers.Timer(); this.timer.Interval = 500; this.timer.Elapsed += (sender, e) => this.Flush(); this.timer.Enabled = true; this.timer.Start(); }
public override void Close() { if (this.loader.NotNull()) { this.loader.Stop(); this.loader.Abort(); this.loader.Dispose(); this.loader = null; } this.Clear(); this.buffer = null; }