VideoOS.Platform.Proxy.AlarmClient.IAlarmClient Interface Reference

The alarm client is used to handle alarm specific actions. The client can be used to both add and get alarms. Updates of already existing alarms can be done primarily updating the alarm management field such as alarm state and and owner. The alarm history can also be received which is the collection of all the changes made to a specific alarm. More...

Public Member Functions

void Acknowledge (Guid id)
 Acknowledges a specific alarm. Acknowledge alarms wil get the state set to In Progress (state = 4) and the owner will be set to the user calling.
 
void AcknowledgeMultipleAlarms (Guid objectId)
 Acknowledges multiple alarms. The method will acknowledge all alarms which is created by a specific object. The object is defined by the Alarm.EventHeader.Source.FQID.ObjectId. The acknowledge alarms wil get the state set to In Progress (state = 4) and the owner will be set to the user calling.
 
void Add (VideoOS.Platform.Data.Alarm alarm)
 Add an alarm to the Event Server. No filtering and manipulation is done on the way to the database and the alarm structure is preserved in the database. This means that adding the alarm and getting it afterwards using the Alarm.Eventheader.ID will result in an alarm containing the same data fields.
 
void AddAsEvent (VideoOS.Platform.Data.Alarm alarm)
 Add alarm as event (deprecated)
 
void AddEvent (VideoOS.Platform.Data.BaseEvent baseEvent)
 Add an event to the Event Server. The event is checked and filtered in the Event Server against the user defined alarm definitions. Alarms are created based on the baseEvent data on every matching alarm definition. The match criteria is the BaseEvent.EventHeader.Message which match the alarm definition event message and the BaseEvent.EventHeader.Source.FQID.ObjectId which matches the source. The alarms created gets the alarm definition details added as data and the alarm is given a unique id.
 
void AttachSnapshot (Guid id, VideoOS.Platform.Data.Snapshot snapshot)
 Attach a snapshot to a specific alarm.
 
void CloseClient ()
 Closes the alarm client.
 
VideoOS.Platform.Data.Alarm Get (Guid id)
 Gets a specific alarm based on the input id.
 
AlarmHistory[] GetAlarmHistory (Guid id)
 Gets the alarm history. This methods returns a collection alarm history objects which contains information on the changes made to the alarm. The alarm history reflects the alarm updates made Check VideoOS.Platform.Proxy.Alarm.AlarmHistory for details.
 
AlarmLine[] GetAlarmLines (int from, int maxCount, AlarmFilter filter)
 Gets alarm lines based on alarm filter. The lines received is a subset of the full set of alarm lines that satisfies the filter conditions. The subset is received based on the "from" and "maxCount" input parameters. An example: Get the newest 100 alarm lines where the alarm state is In Progress (state = 4). The alarm lines should be returned in descending time order. Help on constructing the alarm filter matching this, see the Alarm filter documentation. The "from" parameter should be set to 0 meaning the start of the resulting matching set and the "maxCount" parameter is set to 100.
 
string[] GetAlarmMessages ()
 Gets all the different alarm messages received up to this point in time. The alarm message is the Alarm.EventHeader.Message field in the alarm.
 
AlarmUpdate[] GetAlarmUpdateHistory (Guid id)
 Gets the alarm update history. This method returns a collection of alarm update history objects which contains the information on the changes made to the alarm. The alarm update history reflects the alarm updates Check VideoOS.Platform.Proxy.Alarm.AlarmUpdate for details.
 
VideoOS.Platform.Data.BaseEvent GetEvent (Guid id)
 Gets a specific event based on the input id.
 
EventLine[] GetEventLines (int from, int maxCount, EventFilter filter)
 Gets event lines based on event filter. The lines received is a subset of the full set of event lines that satisfies the filter conditions. The subset is received based on the "from" and "maxCount" input parameters. An example: Get the newest 100 event lines where the event name contains "My event". The event lines should be returned in descending time order. Help on constructing the event filter matching this, see the event filter documentation. The "from" parameter should be set to 0 meaning the start of the resulting matching set and the "maxCount" parameter is set to 100.
 
VideoOS.Platform.Data.EventHeader GetHeader (Guid id)
 Gets the event header from a specific alarm.
 
AlarmUpdateData GetSessionAlarmLines (int maxCount, Guid sessionId)
 Get the specified number of alarm lines in the session.
 
EventUpdateData GetSessionEventLines (int maxCount, Guid sessionId)
 Gets the specified number of event lines in the session.
 
VideoOS.Platform.Data.SnapshotList GetSnapshots (Guid id)
 Get the snapshot list from a specific alarm.
 
Statistic[] GetStatistics ()
 Gets the alarm statistics. The statistics contains overall informations on alarm count based on different alarm properties like state and priority VideoOS.Platform.Proxy.Alarm.Statistic for more information about the content.
 
void OpenClient ()
 Opens the alarm client for use.
 
Guid StartAlarmLineSession (AlarmFilter filter)
 Starts a session which creates an alarm lines queue on the server, which matches the filter.
 
Guid StartEventLineSession (EventFilter filter)
 Starts a session which creates an event line queue on the server, which matches the filter.
 
void StopAlarmLineSession (Guid sessionId)
 Stops the session of alarm lines queue.
 
void StopEventLineSession (Guid sessionId)
 Stops the session of the event lines queue.
 
void UpdateAlarm (Guid id, string text, int state, int priority, DateTime time, string assignedTo)
 Updates a specific alarm with the input parameters. Only valid input parameters is updated.
 
void UpdateAlarmValues (Guid id, KeyValuePair< string, string >[] updates)
 Updates a set of fields on a given alarm. The alarm to update is identified by the id.
 
void UpdateMultipleAlarms (Guid objectId, int oldState, int newState, DateTime time, string assignedTo)
 Updates multiple alarms. The method updates all alarms which is created by a specific object. The object is defined by the Alarm.EventHeader.Source.FQID.ObjectId. Both state and the assigned to will be updated.
 

Properties

CommunicationState State [get]
 Gets the alarm client commnication state.
 

Detailed Description

The alarm client is used to handle alarm specific actions. The client can be used to both add and get alarms. Updates of already existing alarms can be done primarily updating the alarm management field such as alarm state and and owner. The alarm history can also be received which is the collection of all the changes made to a specific alarm.

This interface wrappes alarm client for XProtect.

Member Function Documentation

◆ Acknowledge()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.Acknowledge ( Guid id)

Acknowledges a specific alarm. Acknowledge alarms wil get the state set to In Progress (state = 4) and the owner will be set to the user calling.

Parameters
idId of the alarm to be updated
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


◆ AcknowledgeMultipleAlarms()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.AcknowledgeMultipleAlarms ( Guid objectId)

Acknowledges multiple alarms. The method will acknowledge all alarms which is created by a specific object. The object is defined by the Alarm.EventHeader.Source.FQID.ObjectId. The acknowledge alarms wil get the state set to In Progress (state = 4) and the owner will be set to the user calling.

Parameters
objectIdObject id of the alarms to update. The id is matched to Alarm.EventHeader.Source.FQID.ObjectId in the alarm.
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


◆ Add()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.Add ( VideoOS.Platform.Data.Alarm alarm)

Add an alarm to the Event Server. No filtering and manipulation is done on the way to the database and the alarm structure is preserved in the database. This means that adding the alarm and getting it afterwards using the Alarm.Eventheader.ID will result in an alarm containing the same data fields.

Parameters
alarmAlarm
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


◆ AddAsEvent()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.AddAsEvent ( VideoOS.Platform.Data.Alarm alarm)

Add alarm as event (deprecated)

Parameters
alarmAlarm
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.

◆ AddEvent()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.AddEvent ( VideoOS.Platform.Data.BaseEvent baseEvent)

Add an event to the Event Server. The event is checked and filtered in the Event Server against the user defined alarm definitions. Alarms are created based on the baseEvent data on every matching alarm definition. The match criteria is the BaseEvent.EventHeader.Message which match the alarm definition event message and the BaseEvent.EventHeader.Source.FQID.ObjectId which matches the source. The alarms created gets the alarm definition details added as data and the alarm is given a unique id.

Parameters
baseEventEvent
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


◆ AttachSnapshot()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.AttachSnapshot ( Guid id,
VideoOS.Platform.Data.Snapshot snapshot )

Attach a snapshot to a specific alarm.

Parameters
idAlarm id
snapshotSnapshot to attach
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


◆ CloseClient()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.CloseClient ( )

Closes the alarm client.

◆ Get()

VideoOS.Platform.Data.Alarm VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.Get ( Guid id)

Gets a specific alarm based on the input id.

Parameters
idAlarm id
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.
Returns
Alarm

◆ GetAlarmHistory()

AlarmHistory[] VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetAlarmHistory ( Guid id)

Gets the alarm history. This methods returns a collection alarm history objects which contains information on the changes made to the alarm. The alarm history reflects the alarm updates made Check VideoOS.Platform.Proxy.Alarm.AlarmHistory for details.

Parameters
idId of the alarm to get the history about
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication errors.
Returns
Alarm history

◆ GetAlarmLines()

AlarmLine[] VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetAlarmLines ( int from,
int maxCount,
AlarmFilter filter )

Gets alarm lines based on alarm filter. The lines received is a subset of the full set of alarm lines that satisfies the filter conditions. The subset is received based on the "from" and "maxCount" input parameters. An example: Get the newest 100 alarm lines where the alarm state is In Progress (state = 4). The alarm lines should be returned in descending time order. Help on constructing the alarm filter matching this, see the Alarm filter documentation. The "from" parameter should be set to 0 meaning the start of the resulting matching set and the "maxCount" parameter is set to 100.

Parameters
fromStart of alarm lines.
maxCountMax count of received alarm lines
filterThe alarm filter
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.
Returns
List of alarm lines

◆ GetAlarmMessages()

string[] VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetAlarmMessages ( )

Gets all the different alarm messages received up to this point in time. The alarm message is the Alarm.EventHeader.Message field in the alarm.

Exceptions
VideoOS.Platform.Proxy.Alarm.AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.
Returns
Messages

◆ GetAlarmUpdateHistory()

AlarmUpdate[] VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetAlarmUpdateHistory ( Guid id)

Gets the alarm update history. This method returns a collection of alarm update history objects which contains the information on the changes made to the alarm. The alarm update history reflects the alarm updates Check VideoOS.Platform.Proxy.Alarm.AlarmUpdate for details.

Parameters
idId for the alarm to get the history about
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication errors.
Returns
Alarm update history

◆ GetEvent()

VideoOS.Platform.Data.BaseEvent VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetEvent ( Guid id)

Gets a specific event based on the input id.

Parameters
idEvent id
Exceptions
AlarmServiceFaultThrown if the id is rejected by the Event Server
ExceptionThrown on communication error.
Returns
Event

◆ GetEventLines()

EventLine[] VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetEventLines ( int from,
int maxCount,
EventFilter filter )

Gets event lines based on event filter. The lines received is a subset of the full set of event lines that satisfies the filter conditions. The subset is received based on the "from" and "maxCount" input parameters. An example: Get the newest 100 event lines where the event name contains "My event". The event lines should be returned in descending time order. Help on constructing the event filter matching this, see the event filter documentation. The "from" parameter should be set to 0 meaning the start of the resulting matching set and the "maxCount" parameter is set to 100.

Parameters
fromStart of event lines.
maxCountMax count of received event lines
filterThe event filter
Exceptions
AlarmServiceFaultThrown if the event id is rejected by the Event Server
ExceptionThrown on communication errors.
Returns
List of event lines

◆ GetHeader()

VideoOS.Platform.Data.EventHeader VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetHeader ( Guid id)

Gets the event header from a specific alarm.

Parameters
idAlarm id
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.
Returns
Event header

◆ GetSessionAlarmLines()

AlarmUpdateData VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetSessionAlarmLines ( int maxCount,
Guid sessionId )

Get the specified number of alarm lines in the session.

Parameters
maxCountMaximum number of alarm lines to return
sessionIdThe session id returned by IAlarmClient.StartAlarmLineSession(AlarmFilter)
Returns
Alarm update data

◆ GetSessionEventLines()

EventUpdateData VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetSessionEventLines ( int maxCount,
Guid sessionId )

Gets the specified number of event lines in the session.

Parameters
maxCountMaximum number of event lines to return
sessionIdThe session id returned by IAlarmClient.StartEventLineSession(EventFilter)
Returns

◆ GetSnapshots()

VideoOS.Platform.Data.SnapshotList VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetSnapshots ( Guid id)

Get the snapshot list from a specific alarm.

Parameters
idAlarm id
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.
Returns
Snapshot list

◆ GetStatistics()

Statistic[] VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.GetStatistics ( )

Gets the alarm statistics. The statistics contains overall informations on alarm count based on different alarm properties like state and priority VideoOS.Platform.Proxy.Alarm.Statistic for more information about the content.

Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication errors.
Returns
Alarm statistics

◆ OpenClient()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.OpenClient ( )

Opens the alarm client for use.

◆ StartAlarmLineSession()

Guid VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.StartAlarmLineSession ( AlarmFilter filter)

Starts a session which creates an alarm lines queue on the server, which matches the filter.

Parameters
filterFilter on alarm lines
Returns
The session id

◆ StartEventLineSession()

Guid VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.StartEventLineSession ( EventFilter filter)

Starts a session which creates an event line queue on the server, which matches the filter.

Parameters
filterFilter on the event lines
Returns
The session id

◆ StopAlarmLineSession()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.StopAlarmLineSession ( Guid sessionId)

Stops the session of alarm lines queue.

Parameters
sessionIdThe session id returned by IAlarmClient.StartAlarmLineSession(AlarmFilter), used by IAlarmClient.GetSessionAlarmLines(int, Guid)

◆ StopEventLineSession()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.StopEventLineSession ( Guid sessionId)

Stops the session of the event lines queue.

Parameters
sessionIdThe session id returned by IAlarmClient.StartEventLineSession(EventFilter), used by IAlarmClient.GetSessionEventLines(int, Guid)

◆ UpdateAlarm()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.UpdateAlarm ( Guid id,
string text,
int state,
int priority,
DateTime time,
string assignedTo )

Updates a specific alarm with the input parameters. Only valid input parameters is updated.

Parameters
idId of the alarm to be updated
textThe text will not be added to the alarm but to the alarm history which contains the history of alarm updates VideoOS.Platform.Proxy.Alarm.AlarmHistory. If null no text is written
stateThe new alarm state. Only states greater than 0 is valid
priorityThe new alarm priority. Only priorities greater than 0 is valid
timeThe time of the update
assignedToThe new assigned to owner. If null no owner is assigned
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


◆ UpdateAlarmValues()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.UpdateAlarmValues ( Guid id,
KeyValuePair< string, string >[] updates )

Updates a set of fields on a given alarm. The alarm to update is identified by the id.

The updates parameter defines what fields to update, and what value to assign to them.

The following fields can be updated:

  • "AssignedTo"
  • "Comment"
  • "Priority"
  • "PriorityInt"
  • "PriorityName"
  • "ReasonCode"
  • "State"
  • "StateInt"
  • "StateName"
Exceptions
VideoOS.Platform.Proxy.Alarm.AlarmServiceFaultThrown if invalid field key or value
Parameters
idId of alarm to update
updatesKeyValuePair of fields to update

◆ UpdateMultipleAlarms()

void VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.UpdateMultipleAlarms ( Guid objectId,
int oldState,
int newState,
DateTime time,
string assignedTo )

Updates multiple alarms. The method updates all alarms which is created by a specific object. The object is defined by the Alarm.EventHeader.Source.FQID.ObjectId. Both state and the assigned to will be updated.

Parameters
objectIdObject id of the alarms to update. The id is matched to Alarm.EventHeader.Source.FQID.ObjectId in the alarm.
oldStateOld state. Only alarms with the this state will be updated.
newStateNew state.
timeThe time of the update
assignedToNew assigned to user
Exceptions
AlarmServiceFaultThrown if the alarm is rejected by the Event Server
ExceptionThrown on communication error.


Property Documentation

◆ State

CommunicationState VideoOS.Platform.Proxy.AlarmClient.IAlarmClient.State
get

Gets the alarm client commnication state.