1LIBXO(3) BSD Library Functions Manual LIBXO(3)
2
4 xo_set_writer — set custom writer functions for a libxo handle
5
7 library “libxo”
8
10 #include <libxo/xo.h>
11
12 void typedef xo_ssize_t (*xo_write_func_t)(void *, const char *);
13
14 typedef void (*xo_close_func_t)(void *);
15
16 typedef int (*xo_flush_func_t)(void *);
17 xo_set_writer(xo_handle_t *handle, void *opaque);
18 "xo_write_func_t write_func"
19 "xo_close_func_t close_func"
20 "xo_flush_func_t flush_func"
21
23 The xo_set_writer() function allows custom “write” functions which can
24 tailor how libxo writes data. An opaque argument is recorded and passed
25 back to the write_func function, allowing the function to acquire context
26 information. The close_func function can release this opaque data and
27 any other resources as needed. The flush_func function should flush any
28 pending data associated with the opaque pointer.
29
31 xo_emit(3), libxo(3)
32
34 The libxo library first appeared in FreeBSD 11.0.
35
37 libxo was written by Phil Shafer <phil@freebsd.org>.
38
39
41 FreeBSD uses libxo version 1.6.0. Complete documentation can be found on
42 github:
43
44 https://juniper.github.io/libxo/1.6.0/html/index.html
45
46 libxo lives on github as:
47
48 https://github.com/Juniper/libxo
49
50 The latest release of libxo is available at:
51
52 https://github.com/Juniper/libxo/releases
53
55 The libxo library was added in FreeBSD 11.0.
56
58 Phil Shafer
59
60BSD December 4, 2014 BSD