Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The NotifyEventStr method generates system events. Events are The generated event is sent to all system kernels connected to the local kernel. An In the NotifyEventStr method, an event is specified as by a group of String arguments.

Method call syntaxSyntax for method invocation:

Code Block
languagejavascript
 function  NotifyEventStr(objtype : String, id  : String, event : String, param<value>  [, param<value>] : String )

Method arguments:

  1. objtype - Required is a required argument. The It corresponds to the type of the object that the event should be generated for. It It takes the following values:  Type – String, range – existing object types.
  2. id - Required argument. Identification number of the object of the type set in the objtype argument. It takes the following values:  Type – String, range – existing identification numbers of the object of the specified type.
  3. system object for which you want to generate an event. Possible values: String type, range is limited by object types registered in the system.
  4. id is a required argument. It corresponds to the identification (registration) number of the object specified by the objtype argument. Possible values: String type, range is limited by the identification numbers of objects of the specified type registered in the system.
  5. event is a required argument. It specifies the event that you want to generate. Possible values: String type, range is limited by events available for the object event - Required argument. The event to be generated. It takes the following values:  Type – String, range – available events for the objects of the specified type.
  6. param<value> - Required is a required argument. Several You can specify several arguments of this type can be specified. The parameters . It corresponds to the parameter(s) of the system event.

One parameter has the following syntaxSyntax for setting a value to a parameter corresponds to a string:

"param<value>", where

param is a name of the parameter;

value is a value of the parameter.

Several parameters have the following syntaxSyntax for setting a value to several parameters corresponds to a string:

"param1<value1>,param2<value2>…".

Elements of the list are separated by commas with no white spacewithout spaces. If no parameters need parameter needs to be specified, an empty string is used:

Code Block
languagejavascript
DoReactStr("CAM","1","MD_START","");

The Possible values of the param argument can take the following values: Type – String, range – : String type, range is limited by the available parameters of the specified event. The Possible values of the value argument can take the following values: Type – String type, range depends on the parameter that you want to set.

Info
titleNote

Two types of system messages are available in the Intellect system: events and actionsreactions.The  The events usually contain some information and are used as notifications sent to all Intellect kernels connected to each other during the system setup architecture configuration. The actions reactions are the control commands sent to specific objects. An action A reaction is transmitted only to the kernel where on which the related required object belongsis registered, and not to the whole entire system.The  The DoReactStr and DoReact methods are used to generate actionsreactions. The NotifyEventStr and NotifyEvent methods are used to generate events.

Usage examples

ProblemExample. When an alarm is received, send the “panic lock” event for the corresponding to region of the camera region. For camera identification numbers are from 1 to 4, use region 1; for . For camera numbers from 5 to 10, use region 2.

...