Libtrap: Internal development docs  1.16.1
Data Fields
trap_ctx_priv_s Struct Reference

#include <trap_internal.h>

Collaboration diagram for trap_ctx_priv_s:
Collaboration graph
[legend]

Data Fields

int initialized
 
volatile int terminated
 
volatile int ifc_change
 
int trap_last_error
 
const char * trap_last_error_msg
 
char error_msg_buffer [MAX_ERROR_MSG_BUFF_SIZE]
 
trap_input_ifc_tin_ifc_list
 
trap_output_ifc_tout_ifc_list
 
uint32_t num_ifc_in
 
uint32_t num_ifc_out
 
int get_data_timeout
 
pthread_mutex_t error_mtx
 
ifc_autoflush_tifc_autoflush_timeout
 
pthread_t service_thread
 
char * service_ifc_name
 
int service_thread_initialized
 
uint64_t * counter_send_message
 
uint64_t * counter_dropped_message
 
uint64_t * counter_recv_message
 
uint64_t * counter_send_buffer
 
uint64_t * counter_autoflush
 
uint64_t * counter_recv_buffer
 
uint64_t * counter_recv_delay_last
 
uint64_t * counter_recv_delay_total
 
uint64_t * recv_delay_timestamp
 

Detailed Description

Libtrap context structure.

It contains the whole context of one instance of libtrap. The context contains arrays of communication interfaces (IFC), buffers, locks/mutexes.

Definition at line 220 of file trap_internal.h.

Field Documentation

◆ error_msg_buffer

char trap_ctx_priv_s::error_msg_buffer[MAX_ERROR_MSG_BUFF_SIZE]

Buffer for dynamically generated messages

Definition at line 248 of file trap_internal.h.

◆ error_mtx

pthread_mutex_t trap_ctx_priv_s::error_mtx

Lock setting last error code and last error message.

Definition at line 278 of file trap_internal.h.

◆ get_data_timeout

int trap_ctx_priv_s::get_data_timeout

Timeout common to all readers for multiread feature

Definition at line 273 of file trap_internal.h.

◆ ifc_autoflush_timeout

ifc_autoflush_t* trap_ctx_priv_s::ifc_autoflush_timeout

Timeouts for autoflush thread.

Definition at line 283 of file trap_internal.h.

◆ ifc_change

volatile int trap_ctx_priv_s::ifc_change

Number of interface changes waiting to be applied.

Definition at line 233 of file trap_internal.h.

◆ in_ifc_list

trap_input_ifc_t* trap_ctx_priv_s::in_ifc_list

Array of input interfaces

Definition at line 253 of file trap_internal.h.

◆ initialized

int trap_ctx_priv_s::initialized

Is libtrap initialized correctly? (0 ~ false)

Definition at line 224 of file trap_internal.h.

◆ num_ifc_in

uint32_t trap_ctx_priv_s::num_ifc_in

Number of input interfaces

Definition at line 263 of file trap_internal.h.

◆ num_ifc_out

uint32_t trap_ctx_priv_s::num_ifc_out

Number of output interfaces

Definition at line 268 of file trap_internal.h.

◆ out_ifc_list

trap_output_ifc_t* trap_ctx_priv_s::out_ifc_list

Arrays of output interfaces

Definition at line 258 of file trap_internal.h.

◆ service_ifc_name

char* trap_ctx_priv_s::service_ifc_name

Name of the service IFC socket, it is disabled when NULL.

Definition at line 293 of file trap_internal.h.

◆ service_thread

pthread_t trap_ctx_priv_s::service_thread

Service thread that enables communication with module

Definition at line 288 of file trap_internal.h.

◆ service_thread_initialized

int trap_ctx_priv_s::service_thread_initialized

Indicator of initialized service thread

Definition at line 298 of file trap_internal.h.

◆ terminated

volatile int trap_ctx_priv_s::terminated

Is libtrap terminated? (0 ~ false, should run)

Definition at line 228 of file trap_internal.h.

◆ trap_last_error

int trap_ctx_priv_s::trap_last_error

Code of last error (one of the codes above)

Definition at line 238 of file trap_internal.h.

◆ trap_last_error_msg

const char* trap_ctx_priv_s::trap_last_error_msg

Human-readable message about last error

Definition at line 243 of file trap_internal.h.


The documentation for this struct was generated from the following file: