lightify_ctx Struct Reference

`#include <context.h>`

Collaboration diagram for lightify_ctx:
[legend]

## Data Fields

void(* | log_fn )(struct lightify_ctx *ctx, int priority, const char *file, int line, const char *fn, const char *format, va_list args)
int(* | socket_read_fn )(struct lightify_ctx *ctx, unsigned char *msg, size_t size)
| Function pointer to the I/O handling – read from. More...
int(* | socket_write_fn )(struct lightify_ctx *ctx, unsigned char *msg, size_t size)
| Function pointer to the I/O handling – read from. More...
void * | userdata
| Function pointer to the I/O handling – write to. More...
int | log_priority
int | socket
struct lightify_node * | nodes
struct lightify_group * | groups
long | cnt
struct timeval | iotimeout

## Detailed Description

lightify_ctx:

Opaque object representing the library context.

Definition at line 63 of file context.h.

## Field Documentation

long cnt

request id counter

Definition at line 91 of file context.h.

struct lightify_group* groups

pointer to the first group, if any

Definition at line 88 of file context.h.

struct timeval iotimeout

timeout for IO

Definition at line 94 of file context.h.

void(* log_fn) (struct lightify_ctx *ctx, int priority, const char *file, int line, const char *fn, const char *format, va_list args)

Definition at line 65 of file context.h.

int log_priority

Definition at line 79 of file context.h.

struct lightify_node* nodes

pointer to the first node, if any.

Definition at line 85 of file context.h.

int socket

fd for network socket

Definition at line 82 of file context.h.

int(* socket_read_fn) (struct lightify_ctx *ctx, unsigned char *msg, size_t size)

Function pointer to the I/O handling – read from.

Definition at line 69 of file context.h.

int(* socket_write_fn) (struct lightify_ctx *ctx, unsigned char *msg, size_t size)

Function pointer to the I/O handling – read from.

Definition at line 72 of file context.h.

void* userdata

Function pointer to the I/O handling – write to.

Definition at line 77 of file context.h.

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

- src/context.h