/// <summary> /// 追加 /// </summary> public override void Add() { Debug.WriteLine("=>>>> MemoryPerformanceChartTask::Add()"); //------------------------ // 値を取得し、履歴に登録 //------------------------ ArrayList _ValueList = new ArrayList(); for (int i = 0; i < Items.Count; i++) { PerformanceCounterObject _PerformanceCounterObject = Items[i].Counter; PerformanceHistory <float> _PerformanceHistory = Items[i].History; float value = this.TotalVisibleMemorySize - _PerformanceCounterObject.NextValue(); Debug.WriteLine("メモリ使用量:{0}", value); _PerformanceHistory.Add(value); _ValueList.Add(value); } this.ChartAreas[0].AxisY.Minimum = 0; // 縦軸の最小値を0にする this.ChartAreas[0].AxisY.Maximum = this.TotalVisibleMemorySize; this.ChartAreas[0].AxisY.Interval = 1000; // ログ出力 PrintLog(_ValueList); Debug.WriteLine("<<<<= MemoryPerformanceChartTask::Add()"); }
/// <summary> /// 追加 /// </summary> public override void Add() { Debug.WriteLine("m_PerformanceList.Count = " + Items.Count.ToString()); Process[] _Process = Process.GetProcessesByName(m_InstanceName); Debug.WriteLine("_Process.Length = " + _Process.Length.ToString()); if (!Running) { return; } //------------------------ // 値を取得し、履歴に登録 //------------------------ ArrayList _ValueList = new ArrayList(); for (int i = 0; i < Items.Count; i++) { PerformanceCounterObject _PerformanceCounterObject = Items.GetItem(i).Counter; PerformanceHistory <float> _PerformanceHistory = Items.GetItem(i).History; float value = _PerformanceCounterObject.NextValue(); _PerformanceHistory.Add(value); _ValueList.Add(value); } // ログ出力 PrintLog(_ValueList); }
/// <summary> /// 追加 /// </summary> public override void Add() { if (!Running) { return; } //------------------------ // 値を取得し、履歴に登録 //------------------------ ArrayList _ValueList = new ArrayList(); float _MaxValue = 10.0F; for (int i = 0; i < Items.Count; i++) { PerformanceCounterObject _PerformanceCounterObject = Items[i].Counter; PerformanceHistory <float> _PerformanceHistory = Items[i].History; float value = _PerformanceCounterObject.NextValue(); _PerformanceHistory.Add(value); _ValueList.Add(value); if (_PerformanceHistory.Max > _MaxValue) { _MaxValue = _PerformanceHistory.Max; } } this.ChartAreas[0].AxisY.Maximum = _MaxValue; this.ChartAreas[0].AxisY.Interval = (int)(_MaxValue / 10); // ログ出力 PrintLog(_ValueList); }
public MemoryPerformanceChartTask(PerformanceCounterObject pPerformanceCounterObject, int pCapacity) : base(pPerformanceCounterObject, pCapacity) { }
public ProcessPerformanceChartTask(PerformanceCounterObject pPerformanceCounterObject, int pCapacity) : base(pPerformanceCounterObject, pCapacity) { }
public NetworkPerformanceChartTask(PerformanceCounterObject pPerformanceCounterObject, int pCapacity) : base(pPerformanceCounterObject, pCapacity) { }
public LogicalDiskPerformanceChartTask(PerformanceCounterObject pPerformanceCounterObject, int pCapacity) : base(pPerformanceCounterObject, pCapacity) { }