21 #define AFW_IMPLEMENTATION_ID "afw_writer_fd"
40 impl_afw_writer_release(
47 if (self->close_on_release) {
56 impl_afw_writer_flush(
79 len = fwrite(buffer, size, 1, self->fd);
101 len = fwrite(
"\n", 1, 1, self->fd);
113 impl_afw_writer_increment_indent(
120 (
self->pub.indent)++;
127 impl_afw_writer_decrement_indent(
134 if (self->pub.indent == 0) {
136 "afw_writer_decrement_indent() call when indent is already 0",
139 (
self->pub.indent)--;
AFW_DEFINE(const afw_object_t *)
Adaptive Framework Core Internal.
Interface afw_interface implementation declares.
#define AFW_SIZE_T_MAX_BUFFER
this is the maximum number of digits that can be produced by afw_size_t plus null terminator.
#define AFW_INTEGER_FMT
Format string specifier used for afw_integer_t.
apr_size_t afw_size_t
size_t.
#define AFW_SIZE_T_FMT
Format string specifier used for afw_size_t.
#define AFW_INTEGER_MAX_BUFFER
this is the maximum number of digits that can be produced by afw_integer_t plus negative sign plus nu...
apr_int64_t afw_integer_t
typedef for big signed int.
#define AFW_THROW_ERROR_RV_Z(code, rv_source_id, rv, message_z, xctx)
Macro used to set error and rv in xctx and throw it.
#define AFW_THROW_ERROR_Z(code, message_z, xctx)
Macro used to set error and 0 rv in xctx and throw it.
void impl_afw_writer_write(const afw_writer_t *instance, const void *buffer, afw_size_t size, afw_xctx_t *xctx)
void impl_afw_writer_write_eol(const afw_writer_t *instance, afw_xctx_t *xctx)
afw_writer_write_integer(const afw_writer_t *writer, afw_integer_t integer, afw_xctx_t *xctx)
Call afw_writer_write() with an integer.
#define afw_writer_write_z(writer, s_z, xctx)
Call afw_writer_write() with zero terminated string.
afw_writer_write_size(const afw_writer_t *writer, afw_size_t size, afw_xctx_t *xctx)
Call afw_writer_write() with an size.
Interface afw_writer public struct.
Interface afw_xctx public struct.