public PerformanceCountersGroup CreateNewGroup(string groupName, bool bEnabled, TreeView parentTreeView, PerformanceCountersGroupsType groupType = PerformanceCountersGroupsType.Custom, PerformanceCountersGroup.PerformanceCounterType[] counterTypes = null, int targetProcessID = 0) { Debug.Assert(!(groupType == PerformanceCountersGroupsType.Custom && counterTypes != null), "Pre-defined PerformanceCounterTypes cannot be used with a custom PerformanceCountersGroupsType"); PerformanceCountersGroup newGroup = new PerformanceCountersGroup(groupName, bEnabled, parentTreeView, groupType, counterTypes, targetProcessID); _performanceCountersGroups.Add(newGroup); return(newGroup); }
public bool HandleLogEvent(Int64 eventTimeMS, string groupName, string counterName, string counterUnitTag, float value) { PerformanceCountersGroup perfGroup = null; foreach (var g in _performanceCountersGroups) { if (g._groupName == groupName) { perfGroup = g; break; } } if (perfGroup == null) { TreeView parentTreeView = FASTBuildMonitorControl._StaticWindow.graphsSelectionTreeView; perfGroup = CreateNewGroup(groupName, true, parentTreeView); } return(perfGroup.HandleLogEvent(eventTimeMS, counterName, counterUnitTag, value)); }
public PerformanceCountersGroup CreateNewGroup(string groupName, bool bEnabled, TreeView parentTreeView, PerformanceCountersGroupsType groupType = PerformanceCountersGroupsType.Custom, PerformanceCountersGroup.PerformanceCounterType[] counterTypes = null, int targetProcessID = 0) { Debug.Assert(!(groupType == PerformanceCountersGroupsType.Custom && counterTypes != null), "Pre-defined PerformanceCounterTypes cannot be used with a custom PerformanceCountersGroupsType"); PerformanceCountersGroup newGroup = new PerformanceCountersGroup(groupName, bEnabled, parentTreeView, groupType, counterTypes, targetProcessID); _performanceCountersGroups.Add(newGroup); return newGroup; }