AT&T ECOMP Vendor Event Listener library  0.1
Functions
evel_signaling.c File Reference

Implementation of EVEL functions relating to Signaling. More...

#include <string.h>
#include <assert.h>
#include <stdlib.h>
#include "evel_throttle.h"
Include dependency graph for evel_signaling.c:

Go to the source code of this file.

Functions

EVENT_SIGNALINGevel_new_signaling (const char *const vendor_id, const char *const event_id)
 Create a new Signaling event. More...
 
void evel_signaling_type_set (EVENT_SIGNALING *const event, const char *const type)
 Set the Event Type property of the Signaling event. More...
 
void evel_signaling_local_ip_address_set (EVENT_SIGNALING *const event, const char *const local_ip_address)
 Set the Local Ip Address property of the Signaling event. More...
 
void evel_signaling_local_port_set (EVENT_SIGNALING *const event, const char *const local_port)
 Set the Local Port property of the Signaling event. More...
 
void evel_signaling_remote_ip_address_set (EVENT_SIGNALING *const event, const char *const remote_ip_address)
 Set the Remote Ip Address property of the Signaling event. More...
 
void evel_signaling_remote_port_set (EVENT_SIGNALING *const event, const char *const remote_port)
 Set the Remote Port property of the Signaling event. More...
 
void evel_signaling_compressed_sip_set (EVENT_SIGNALING *const event, const char *const compressed_sip)
 Set the Compressed SIP property of the Signaling event. More...
 
void evel_signaling_summary_sip_set (EVENT_SIGNALING *const event, const char *const summary_sip)
 Set the Summary SIP property of the Signaling event. More...
 
void evel_signaling_product_id_set (EVENT_SIGNALING *const event, const char *const product_id)
 Set the Product Id property of the Signaling event. More...
 
void evel_signaling_subsystem_id_set (EVENT_SIGNALING *const event, const char *const subsystem_id)
 Set the Subsystem Id property of the Signaling event. More...
 
void evel_signaling_friendly_name_set (EVENT_SIGNALING *const event, const char *const friendly_name)
 Set the Friendly Name property of the Signaling event. More...
 
void evel_signaling_correlator_set (EVENT_SIGNALING *const event, const char *const correlator)
 Set the Correlator property of the Signaling event. More...
 
void evel_json_encode_signaling (EVEL_JSON_BUFFER *const jbuf, EVENT_SIGNALING *const event)
 Encode the Signaling in JSON according to AT&T's schema for the event type. More...
 
void evel_free_signaling (EVENT_SIGNALING *const event)
 Free a Signaling event. More...
 

Detailed Description

Implementation of EVEL functions relating to Signaling.

License

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  3. All advertising materials mentioning features or use of this software must display the following acknowledgement: This product includes software developed by the AT&T.
  4. Neither the name of AT&T nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY AT&T INTELLECTUAL PROPERTY ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL AT&T INTELLECTUAL PROPERTY BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Definition in file evel_signaling.c.

Function Documentation

§ evel_free_signaling()

void evel_free_signaling ( EVENT_SIGNALING *const  event)

Free a Signaling event.

Free off the event supplied. Will free all the contained allocated memory.

Note
It does not free the event itself, since that may be part of a larger structure.

Definition at line 487 of file evel_signaling.c.

§ evel_json_encode_signaling()

void evel_json_encode_signaling ( EVEL_JSON_BUFFER *const  jbuf,
EVENT_SIGNALING *const  event 
)

Encode the Signaling in JSON according to AT&T's schema for the event type.

Parameters
jbufPointer to the EVEL_JSON_BUFFER to encode into.
eventPointer to the EVENT_HEADER to encode.

Definition at line 441 of file evel_signaling.c.

§ evel_new_signaling()

EVENT_SIGNALING* evel_new_signaling ( const char *const  vendor_id,
const char *const  event_id 
)

Create a new Signaling event.

Note
The mandatory fields on the Signaling must be supplied to this factory function and are immutable once set. Optional fields have explicit setter functions, but again values may only be set once so that the event has immutable properties.
Parameters
vendor_idThe vendor id to encode in the event instance id.
event_idThe vendor event id to encode in the event instance id.
Returns
pointer to the newly manufactured EVENT_SIGNALING. If the event is not used (i.e. posted) it must be released using evel_free_signaling.
Return values
NULLFailed to create the event.

Definition at line 55 of file evel_signaling.c.

§ evel_signaling_compressed_sip_set()

void evel_signaling_compressed_sip_set ( EVENT_SIGNALING *const  event,
const char *const  compressed_sip 
)

Set the Compressed SIP property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
compressed_sipThe Compressed SIP to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 268 of file evel_signaling.c.

§ evel_signaling_correlator_set()

void evel_signaling_correlator_set ( EVENT_SIGNALING *const  event,
const char *const  correlator 
)

Set the Correlator property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
correlatorThe correlator to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 417 of file evel_signaling.c.

§ evel_signaling_friendly_name_set()

void evel_signaling_friendly_name_set ( EVENT_SIGNALING *const  event,
const char *const  friendly_name 
)

Set the Friendly Name property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
friendly_nameThe vendor friendly name to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 388 of file evel_signaling.c.

§ evel_signaling_local_ip_address_set()

void evel_signaling_local_ip_address_set ( EVENT_SIGNALING *const  event,
const char *const  local_ip_address 
)

Set the Local Ip Address property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
local_ip_addressThe Local Ip Address to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 142 of file evel_signaling.c.

§ evel_signaling_local_port_set()

void evel_signaling_local_port_set ( EVENT_SIGNALING *const  event,
const char *const  local_port 
)

Set the Local Port property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
local_portThe Local Port to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 173 of file evel_signaling.c.

§ evel_signaling_product_id_set()

void evel_signaling_product_id_set ( EVENT_SIGNALING *const  event,
const char *const  product_id 
)

Set the Product Id property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
product_idThe vendor product id to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 330 of file evel_signaling.c.

§ evel_signaling_remote_ip_address_set()

void evel_signaling_remote_ip_address_set ( EVENT_SIGNALING *const  event,
const char *const  remote_ip_address 
)

Set the Remote Ip Address property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
remote_ip_addressThe Remote Ip Address to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 205 of file evel_signaling.c.

§ evel_signaling_remote_port_set()

void evel_signaling_remote_port_set ( EVENT_SIGNALING *const  event,
const char *const  remote_port 
)

Set the Remote Port property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
remote_portThe Remote Port to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 236 of file evel_signaling.c.

§ evel_signaling_subsystem_id_set()

void evel_signaling_subsystem_id_set ( EVENT_SIGNALING *const  event,
const char *const  subsystem_id 
)

Set the Subsystem Id property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
subsystem_idThe vendor subsystem id to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 359 of file evel_signaling.c.

§ evel_signaling_summary_sip_set()

void evel_signaling_summary_sip_set ( EVENT_SIGNALING *const  event,
const char *const  summary_sip 
)

Set the Summary SIP property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
summary_sipThe Summary SIP to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 299 of file evel_signaling.c.

§ evel_signaling_type_set()

void evel_signaling_type_set ( EVENT_SIGNALING *const  event,
const char *const  type 
)

Set the Event Type property of the Signaling event.

Note
The property is treated as immutable: it is only valid to call the setter once. However, we don't assert if the caller tries to overwrite, just ignoring the update instead.
Parameters
eventPointer to the Signaling event.
typeThe Event Type to be set. ASCIIZ string. The caller does not need to preserve the value once the function returns.

Definition at line 114 of file evel_signaling.c.