/// <summary> /// 默认构造函数 /// </summary> public RsspMonitorControl() { InitializeComponent(); this.splitContainer2.Dock = DockStyle.Fill; this.treeViewNetwork.Dock = DockStyle.Fill; this.listViewConnectionLog.Dock = DockStyle.Fill; this.treeViewDataSummary.Dock = DockStyle.Fill; this.txtDataDetailed.Dock = DockStyle.Fill; this.listViewLog.Dock = DockStyle.Fill; this.splitContainer4.IsSplitterFixed = true; if (cbxCurrentNodeID.Items.Count > 0) { cbxCurrentNodeID.SelectedIndex = 0; } _filterControl = new FilterControl() { Dock = DockStyle.Fill }; groupBoxFilter.Controls.Add(_filterControl); this.splitContainer3.Panel2.Controls.Add(_cacheCountCtrl); // 打开缓存池。 _productCache.ThreadName = "RsspMonitorControl缓冲池线程"; _productCache.ProductCreated += OnCacheProductCreated; _productCache.Open(); }
private void CreateProductCache(uint timeout, uint warningThreshold) { _productCache = new ProductCache <Tuple <bool, DataCached> >(timeout) { WarningThreshold = warningThreshold }; _productCache.ThreadName = "GenericMonitorControl 缓冲池线程"; _productCache.ProductCreated += OnCacheProductCreated; _productCache.Open(); }
/// <summary> /// 构造函数。 /// </summary> public CommStreamStorage(ushort logExpiredDays = 10) { this.LogExpiredDays = logExpiredDays; // 初始化缓存池。 _logCache.ProductCreated += OnProductCreated; _logCache.Open(); // 订阅菜单项消息 GlobalMessageBus.SubscribeCommLogRollover(OnRolloverCommLog); GlobalMessageBus.SubscribeCommLogCreated(OnCommStreamCreated); }
private void CreateProductCache() { // 打开“RDT事件缓存池”。 _productCacheReceive.ThreadName = string.Format("{0}接收队列线程", this.Name); _productCacheReceive.ProductCreated += OnIncomingUserDataProductCreated; _productCacheReceive.Open(); // 打开发送缓存池。 _productCacheSending.ThreadName = string.Format("{0}发送队列线程", this.Name); _productCacheSending.ProductCreated += OnOutgoingUserDataProductCreated; _productCacheSending.Open(); }