ESL Reference
Following are the most important functions and their arguments, as per how they are available in all ESL implementations for the various programming languages.
eslSetLogLevel
eslSetLogLevel($loglevel)
Calling this function within your program causes your program to issue informative messages related to the Event Socket Library on STDOUT.
The values for $loglevel are the usual:
- 0 is EMERG
- 1 is ALERT
- 2 is CRIT
- 3 is ERROR
- 4 is WARNING
- 5 is NOTICE
- 6 is INFO
- 7 is DEBUG
ESLevent Object
This is the object that represent an Event, can be created (with new()) or received. Its methods are as follows:
new
new($event_type [, $event_subclass])
Instantiates a new event object of that type. Optionally, in case of CUSTOM and other type of events, you specify the subclass.
serialize
serialize([$format])
Print the event into colon-separated 'name: value' pairs similar to a sip/email packet (the way it looks on '/events plain all').
$format can be:
- "xml"
- "json"
- "plain" (default)
setPriority
setPriority([$number])
Sets...