Class Reference
IRIS for UNIX 2019.2
InterSystems: The power behind what matters   
Documentation  Search
  [%SYS] >  [SYS] >  [Monitor] >  [Health] >  [Period]
Private  Storage   

persistent class SYS.Monitor.Health.Period extends %Persistent, %XML.Adaptor

Defines time Periods for evaluation of Health Monitor Sensors. Default is 63 weekly periods, nine Periods for each day of the week.

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
6 8 8


Summary

Properties
Day Description EndTime Month Recurrence
StartTime

Methods
%AddToSaveSet %AddToSyncSet %BMEBuilt %CheckConstraints
%CheckConstraintsForExtent %ClassIsLatestVersion %ClassName %ComposeOid
%ConstructClone %Delete %DeleteExtent %DeleteId
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Exists
%ExistsId %Extends %GUID %GUIDSet
%GetLock %GetParameter %GetSwizzleObject %Id
%InsertBatch %IsA %IsModified %IsNull
%KillExtent %KillExtentData %LoadFromMemory %LockExtent
%LockId %New %NormalizeObject %ObjectIsNull
%ObjectModified %Oid %OnBeforeAddToSync %OnDetermineClass
%Open %OpenId %OriginalNamespace %PackageName
%PhysicalAddress %PurgeIndices %Reload %RemoveFromSaveSet
%ResolveConcurrencyConflict %RollBack %Save %SaveDirect
%SaveIndices %SerializeObject %SetModified %SortBegin
%SortEnd %SyncObjectIn %SyncTransport %UnlockExtent
%UnlockId %ValidateIndices %ValidateObject Create
Delete Modify TodayPeriodsClose TodayPeriodsExecute
TodayPeriodsFetch Validate XMLDTD XMLExport
XMLExportToStream XMLExportToString XMLNew XMLSchema
XMLSchemaNamespace XMLSchemaType


Properties

• property Day as %Integer [ InitialExpression = 0,Required ];
Day. 1-7 for weekly, 1-31 or 99 for others
• property Description as %String(MAXLEN=250);
Recurrance: every day at (start/end), every week on day (default) every month on day of month or "last day of month" every 3 months (quarterly) on day of month or "last day of month" every year on month and day of month or "last day of month" Description of the interval
• property EndTime as %Integer [ InitialExpression = -1,Required ];
End time
• property Month as %String [ InitialExpression = 0,Required ];
Month - Quarterly or yearly
• property Recurrence as %Integer [ InitialExpression = 1,Required ];
Recurrence - weekly-1, monthly-2, quarterly-3, yearly-4
• property StartTime as %Integer [ InitialExpression = -1,Required ];
Start time

Methods

• classmethod Create(Rec As %Integer, Start As %String, End As %String, Day As %Integer, Desc As %String = "", Month As %Integer = 0) as %Status
Create a Period. Start and End time is 24-hour time format. Recurrence - weekly-1, monthly-2, quarterly-3, yearly-4 Day = day of week (1-7) for weekly recurrence, day of month (1-31 or 99 for "end of month") for all other recurrence.
• classmethod Delete(PeriodId As %String) as %Status
Delete a Period
• classmethod Modify(Period As %Integer, Start As %String = "", End As %String = "", Day As %Integer = 0, Rec As %Integer = 0, Desc As %String = "", Month As %Integer = 0) as %Status
Modify a Period.
• classmethod TodayPeriodsClose(ByRef qHandle As %Binary) as %Status
• classmethod TodayPeriodsExecute(ByRef qHandle As %Binary) as %Status
• classmethod TodayPeriodsFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status
• classmethod Validate(Start As %String, End As %String, Rec As %Integer, Day As %Integer, Month As %Integer, ByRef startsecs As %Integer, ByRef endsecs As %Integer) as %Status

Queries

• query MPeriods(day As %Integer)
SQL Query :
SELECT StartTime,EndTime,%ID FROM Period WHERE (Recurrence = 2) AND (Day = :day) ORDER BY StartTime
Get all periods for day - Monthly recurrence
• query PeriodDescriptions()
SQL Query :
SELECT %ID,Description FROM Period ORDER BY Recurrence,Month,Day,StartTime
Get period descriptions, order by Recurrence
• query PeriodDescriptionsDay(day As %Integer)
SQL Query :
SELECT %ID,Description FROM Period WHERE (Day = :day) ORDER BY Day,StartTime
Get period descriptions by Day
• query PeriodDescriptionsID()
SQL Query :
SELECT %ID,Description FROM Period ORDER BY %ID
Get period descriptions, order by ID
• query QPeriods(day As %Integer, month As %Integer)
SQL Query :
SELECT StartTime,EndTime,%ID FROM Period WHERE (Recurrence = 3) AND ((Day = :day)AND(Month = :month)) ORDER BY StartTime
Get all periods for day - quarterly recurrence
• query TodayPeriods()
Selects Start As %Integer, End As %Integer, ID As %String, Description As %String
• query WPeriods(day As %Integer)
SQL Query :
SELECT StartTime,EndTime,%ID FROM Period WHERE (Recurrence = 1) AND (Day = :day) ORDER BY StartTime
Get all periods for day - weekly recurrence
• query YPeriods(day As %Integer, month As %Integer)
SQL Query :
SELECT StartTime,EndTime,%ID FROM Period WHERE (Recurrence = 4) AND ((Day = :day)AND(Month = :month)) ORDER BY StartTime
Get all periods for day - yearly recurrence


Copyright (c) 2019 by InterSystems Corporation. Cambridge, Massachusetts, U.S.A. All rights reserved. Confidential property of InterSystems Corporation.