TA-REF
vsnprintf.c File Reference
#include <stdbool.h>
#include <stdint.h>
#include <stdarg.h>
#include <stddef.h>
+ Include dependency graph for vsnprintf.c:

Classes

struct  out_fct_wrap_type
 

Typedefs

typedef void(* out_fct_type) (char character, void *buffer, size_t idx, size_t maxlen)
 

Functions

static void _out_buffer (char character, void *buffer, size_t idx, size_t maxlen)
 
static void _out_null (char character, void *buffer, size_t idx, size_t maxlen)
 
static void _out_char (char character, void *buffer, size_t idx, size_t maxlen)
 
static void _out_fct (char character, void *buffer, size_t idx, size_t maxlen)
 
static unsigned int _strlen (const char *str)
 
static bool _is_digit (char ch)
 
static unsigned int _atoi (const char **str)
 
static size_t _ntoa_format (out_fct_type out, char *buffer, size_t idx, size_t maxlen, char *buf, size_t len, bool negative, unsigned int base, unsigned int prec, unsigned int width, unsigned int flags)
 
static size_t _ntoa_long (out_fct_type out, char *buffer, size_t idx, size_t maxlen, unsigned long value, bool negative, unsigned long base, unsigned int prec, unsigned int width, unsigned int flags)
 
static int _vsnprintf (out_fct_type out, char *buffer, const size_t maxlen, const char *format, va_list va)
 
int sprintf (char *buffer, const char *format,...)
 
int snprintf (char *buffer, size_t count, const char *format,...)
 
int vsnprintf (char *buffer, size_t count, const char *format, va_list va)
 
int fctprintf (void(*out)(char character, void *arg), void *arg, const char *format,...)
 

Typedef Documentation

◆ out_fct_type

typedef void(* out_fct_type) (char character, void *buffer, size_t idx, size_t maxlen)

Function Documentation

◆ _atoi()

static unsigned int _atoi ( const char **  str)
static

◆ _is_digit()

static bool _is_digit ( char  ch)
inlinestatic

◆ _ntoa_format()

static size_t _ntoa_format ( out_fct_type  out,
char *  buffer,
size_t  idx,
size_t  maxlen,
char *  buf,
size_t  len,
bool  negative,
unsigned int  base,
unsigned int  prec,
unsigned int  width,
unsigned int  flags 
)
static

◆ _ntoa_long()

static size_t _ntoa_long ( out_fct_type  out,
char *  buffer,
size_t  idx,
size_t  maxlen,
unsigned long  value,
bool  negative,
unsigned long  base,
unsigned int  prec,
unsigned int  width,
unsigned int  flags 
)
static

◆ _out_buffer()

static void _out_buffer ( char  character,
void *  buffer,
size_t  idx,
size_t  maxlen 
)
inlinestatic

◆ _out_char()

static void _out_char ( char  character,
void *  buffer,
size_t  idx,
size_t  maxlen 
)
inlinestatic

◆ _out_fct()

static void _out_fct ( char  character,
void *  buffer,
size_t  idx,
size_t  maxlen 
)
inlinestatic

◆ _out_null()

static void _out_null ( char  character,
void *  buffer,
size_t  idx,
size_t  maxlen 
)
inlinestatic

◆ _strlen()

static unsigned int _strlen ( const char *  str)
inlinestatic

◆ _vsnprintf()

static int _vsnprintf ( out_fct_type  out,
char *  buffer,
const size_t  maxlen,
const char *  format,
va_list  va 
)
static

◆ fctprintf()

int fctprintf ( void(*)(char character, void *arg)  out,
void *  arg,
const char *  format,
  ... 
)

◆ snprintf()

int snprintf ( char *  buffer,
size_t  count,
const char *  format,
  ... 
)

◆ sprintf()

int sprintf ( char *  buffer,
const char *  format,
  ... 
)

◆ vsnprintf()

int vsnprintf ( char *  buffer,
size_t  count,
const char *  format,
va_list  va 
)