open62541 1.4.15
Open source implementation of OPC UA
Loading...
Searching...
No Matches
Data Structures | Typedefs | Enumerations
eventloop.h File Reference
#include <open62541/types.h>
#include <open62541/types_generated.h>
#include <open62541/util.h>
#include <open62541/plugin/log.h>

Go to the source code of this file.

Data Structures

struct  UA_DelayedCallback
 
struct  UA_EventLoop
 
struct  UA_EventSource
 
struct  UA_ConnectionManager
 
struct  UA_InterruptManager
 

Typedefs

typedef struct UA_EventLoop UA_EventLoop
 
typedef struct UA_EventSource UA_EventSource
 
typedef struct UA_ConnectionManager UA_ConnectionManager
 
typedef struct UA_InterruptManager UA_InterruptManager
 
typedef void(* UA_Callback) (void *application, void *context)
 
typedef struct UA_DelayedCallback UA_DelayedCallback
 
typedef void(* UA_ConnectionManager_connectionCallback) (UA_ConnectionManager *cm, uintptr_t connectionId, void *application, void **connectionContext, UA_ConnectionState state, const UA_KeyValueMap *params, UA_ByteString msg)
 
typedef void(* UA_InterruptCallback) (UA_InterruptManager *im, uintptr_t interruptHandle, void *interruptContext, const UA_KeyValueMap *instanceInfos)
 

Enumerations

enum  UA_TimerPolicy
 
enum  UA_EventLoopState
 
enum  UA_EventSourceState
 
enum  UA_EventSourceType
 

Typedef Documentation

◆ UA_Callback

typedef void(* UA_Callback) (void *application, void *context)

Definition at line 40 of file eventloop.h.

◆ UA_ConnectionManager

Definition at line 26 of file eventloop.h.

◆ UA_ConnectionManager_connectionCallback

typedef void(* UA_ConnectionManager_connectionCallback) (UA_ConnectionManager *cm, uintptr_t connectionId, void *application, void **connectionContext, UA_ConnectionState state, const UA_KeyValueMap *params, UA_ByteString msg)

The ConnectionCallback is the only interface from the connection back to the application.

  • The connectionId is initially unknown to the target application and "announced" to the application when first used first in this callback.
  • The context is attached to the connection. Initially a default context is set. The context can be replaced within the callback (via the double-pointer).
  • The state argument indicates the lifecycle of the connection. Every connection calls the callback a last time with UA_CONNECTIONSTATE_CLOSING. Protocols individually can forward diagnostic information relevant to the state as part of the key-value parameters.
  • The parameters are a key-value list with additional information. The possible keys and their meaning are documented for the individual ConnectionManager implementations.
  • The msg ByteString is the message (or packet) received on the connection. Can be empty.

Definition at line 252 of file eventloop.h.

◆ UA_DelayedCallback

Delayed callbacks are executed not when they are registered, but in the following EventLoop cycle.

◆ UA_EventLoop

typedef struct UA_EventLoop UA_EventLoop

Definition at line 20 of file eventloop.h.

◆ UA_EventSource

Definition at line 23 of file eventloop.h.

◆ UA_InterruptCallback

typedef void(* UA_InterruptCallback) (UA_InterruptManager *im, uintptr_t interruptHandle, void *interruptContext, const UA_KeyValueMap *instanceInfos)

Interrupts can have additional key-value 'instanceInfos' for each individual triggering.

See the architecture-specific documentation.

Definition at line 348 of file eventloop.h.

◆ UA_InterruptManager

Definition at line 29 of file eventloop.h.

Enumeration Type Documentation

◆ UA_EventLoopState

Enumerator
UA_EVENTLOOPSTATE_FRESH 
UA_EVENTLOOPSTATE_STOPPED 
UA_EVENTLOOPSTATE_STARTED 
UA_EVENTLOOPSTATE_STOPPING 

Definition at line 51 of file eventloop.h.

◆ UA_EventSourceState

Enumerator
UA_EVENTSOURCESTATE_FRESH 
UA_EVENTSOURCESTATE_STOPPED 
UA_EVENTSOURCESTATE_STARTING 
UA_EVENTSOURCESTATE_STARTED 
UA_EVENTSOURCESTATE_STOPPING 

Definition at line 192 of file eventloop.h.

◆ UA_EventSourceType

Type-tag for proper casting of the difference EventSource (e.g.

when they are looked up via UA_EventLoop_findEventSource).

Enumerator
UA_EVENTSOURCETYPE_CONNECTIONMANAGER 
UA_EVENTSOURCETYPE_INTERRUPTMANAGER 

Definition at line 203 of file eventloop.h.

◆ UA_TimerPolicy

Enumerator
UA_TIMER_HANDLE_CYCLEMISS_WITH_CURRENTTIME 
UA_TIMER_HANDLE_CYCLEMISS_WITH_BASETIME 

Definition at line 33 of file eventloop.h.