예제 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DeadmanCheck" /> class.
 /// </summary>
 /// <param name="type">type.</param>
 /// <param name="timeSince">string duration before deadman triggers..</param>
 /// <param name="staleTime">string duration for time that a series is considered stale and should not trigger deadman..</param>
 /// <param name="reportZero">If only zero values reported since time, trigger an alert.</param>
 /// <param name="level">level.</param>
 public DeadmanCheck(TypeEnum?type = default(TypeEnum?), string timeSince = default(string), string staleTime = default(string), bool?reportZero = default(bool?), CheckStatusLevel level = default(CheckStatusLevel), string name = default(string), string orgID = default(string), DashboardQuery query = default(DashboardQuery), TaskStatusType?status = default(TaskStatusType?), string every = default(string), string offset = default(string), List <CheckBaseTags> tags = default(List <CheckBaseTags>), string description = default(string), string statusMessageTemplate = default(string), List <Label> labels = default(List <Label>), CheckBaseLinks links = default(CheckBaseLinks)) : base(name, orgID, query, status, every, offset, tags, description, statusMessageTemplate, labels, links)
 {
     this.Type       = type;
     this.TimeSince  = timeSince;
     this.StaleTime  = staleTime;
     this.ReportZero = reportZero;
     this.Level      = level;
 }
예제 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Check" /> class.
 /// </summary>
 public Check(string name = default(string), string orgID = default(string), DashboardQuery query = default(DashboardQuery), TaskStatusType?status = default(TaskStatusType?), string every = default(string), string offset = default(string), List <CheckBaseTags> tags = default(List <CheckBaseTags>), string description = default(string), string statusMessageTemplate = default(string), List <Label> labels = default(List <Label>), CheckBaseLinks links = default(CheckBaseLinks)) : base(name, orgID, query, status, every, offset, tags, description, statusMessageTemplate, labels, links)
 {
 }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="CheckBase" /> class.
 /// </summary>
 /// <param name="name">name (required).</param>
 /// <param name="orgID">The ID of the organization that owns this check. (required).</param>
 /// <param name="query">query (required).</param>
 /// <param name="status">status.</param>
 /// <param name="every">Check repetition interval..</param>
 /// <param name="offset">Duration to delay after the schedule, before executing check..</param>
 /// <param name="tags">List of tags to write to each status..</param>
 /// <param name="description">An optional description of the check..</param>
 /// <param name="statusMessageTemplate">The template used to generate and write a status message..</param>
 /// <param name="labels">labels.</param>
 /// <param name="links">links.</param>
 public CheckBase(string name = default(string), string orgID = default(string), DashboardQuery query = default(DashboardQuery), TaskStatusType?status = default(TaskStatusType?), string every = default(string), string offset = default(string), List <CheckBaseTags> tags = default(List <CheckBaseTags>), string description = default(string), string statusMessageTemplate = default(string), List <Label> labels = default(List <Label>), CheckBaseLinks links = default(CheckBaseLinks)) : base()
 {
     // to ensure "name" is required (not null)
     if (name == null)
     {
         throw new InvalidDataException("name is a required property for CheckBase and cannot be null");
     }
     else
     {
         this.Name = name;
     }
     // to ensure "orgID" is required (not null)
     if (orgID == null)
     {
         throw new InvalidDataException("orgID is a required property for CheckBase and cannot be null");
     }
     else
     {
         this.OrgID = orgID;
     }
     // to ensure "query" is required (not null)
     if (query == null)
     {
         throw new InvalidDataException("query is a required property for CheckBase and cannot be null");
     }
     else
     {
         this.Query = query;
     }
     this.Status                = status;
     this.Every                 = every;
     this.Offset                = offset;
     this.Tags                  = tags;
     this.Description           = description;
     this.StatusMessageTemplate = statusMessageTemplate;
     this.Labels                = labels;
     this.Links                 = links;
 }