Created
October 27, 2011 20:57
-
-
Save abarnas/1320844 to your computer and use it in GitHub Desktop.
Monitor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace MonitisTop | |
{ | |
/// <summary> | |
/// Base monitor class | |
/// </summary> | |
public class Monitor | |
{ | |
protected Agent agent; | |
protected string id; | |
protected string name; | |
protected int maxMetricWidth; | |
protected List<Metric> metrics; | |
protected List<MonitorDefinition> monitorsDefinitions; | |
public string Id { get { return id; } set { id = value; } } | |
public string Name { get { return name; } set { name = value; } } | |
public int MaxMetricWidth { get { return maxMetricWidth; } set { maxMetricWidth = value; } } | |
public List<Metric> Metrics { get { return metrics; } set { metrics = value; } } | |
public Monitor(Agent _agent) | |
{ | |
agent = _agent; | |
maxMetricWidth = 0; | |
metrics = new List<Metric>(); | |
monitorsDefinitions = new List<MonitorDefinition>(); | |
} | |
// Abstract function to retrieve the metrics for a monitor | |
public virtual void GetMetrics(string apiKey, HttpClient client) {} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment