libwebsockets
Lightweight C library for HTML5 websockets
Loading...
Searching...
No Matches
lws_log_cx Struct Reference

#include <lws-logs.h>

Collaboration diagram for lws_log_cx:

Data Fields

union { 
lws_log_emit_t emit
lws_log_emit_cx_t emit_cx
u
lws_log_use_cx_t refcount_cb
lws_log_prepend_cx_t prepend
struct lws_log_cxparent
void * opaque
void * stg
uint32_t lll_flags
int32_t refcount

Detailed Description

Definition at line 80 of file lws-logs.h.

Field Documentation

◆ [union]

union { ... } lws_log_cx::u

◆ refcount_cb

lws_log_use_cx_t lws_log_cx::refcount_cb

NULL, or a function called after each change to .refcount below, this enables implementing side-effects like opening and closing log files when the first and last object binds / unbinds

Definition at line 94 of file lws-logs.h.

◆ prepend

lws_log_prepend_cx_t lws_log_cx::prepend

NULL, or a cb to optionally prepend a string to logs we are a parent of

Definition at line 98 of file lws-logs.h.

◆ parent

struct lws_log_cx* lws_log_cx::parent

NULL, or points to log ctx we are a child of

Definition at line 101 of file lws-logs.h.

◆ opaque

void* lws_log_cx::opaque

ignored by lws, used to pass config to emit_cx, eg, filepath

Definition at line 103 of file lws-logs.h.

◆ stg

void* lws_log_cx::stg

ignored by lws, may be used a storage by refcount_cb / emit_cx

Definition at line 105 of file lws-logs.h.

◆ lll_flags

uint32_t lws_log_cx::lll_flags

mask of log levels we want to emit in this context

Definition at line 107 of file lws-logs.h.

◆ refcount

int32_t lws_log_cx::refcount

refcount of objects bound to this log context

Definition at line 109 of file lws-logs.h.


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