buffer.c File Reference

#include <stdlib.h>
#include <string.h>
#include "buffer.h"
Include dependency graph for buffer.c:

Go to the source code of this file.

Classes

struct  buffer

Defines

#define INITIAL_BUFFER_SIZE   256

Functions

static int buffer_assure_space (buffer_t buffer, int size)
int buffer_free (buffer_t buffer)
char * buffer_get_buffer (buffer_t buffer)
int buffer_get_position (buffer_t buffer)
static int buffer_grow (buffer_t buffer, int min_length)
buffer_t buffer_new (void)
buffer_position buffer_save_space (buffer_t buffer, int size)
int buffer_write (buffer_t buffer, const char *data, int size)
int buffer_write_at_position (buffer_t buffer, buffer_position position, const char *data, int size)

Define Documentation

#define INITIAL_BUFFER_SIZE   256

Definition at line 22 of file buffer.c.


Function Documentation

static int buffer_assure_space ( buffer_t  buffer,
int  size 
) [static]

Definition at line 84 of file buffer.c.

int buffer_free ( buffer_t  buffer  ) 

Definition at line 52 of file buffer.c.

char* buffer_get_buffer ( buffer_t  buffer  ) 

Definition at line 133 of file buffer.c.

int buffer_get_position ( buffer_t  buffer  ) 

Definition at line 129 of file buffer.c.

static int buffer_grow ( buffer_t  buffer,
int  min_length 
) [static]

Definition at line 63 of file buffer.c.

buffer_t buffer_new ( void   ) 

Definition at line 32 of file buffer.c.

buffer_position buffer_save_space ( buffer_t  buffer,
int  size 
)

Definition at line 93 of file buffer.c.

int buffer_write ( buffer_t  buffer,
const char *  data,
int  size 
)

Definition at line 104 of file buffer.c.

int buffer_write_at_position ( buffer_t  buffer,
buffer_position  position,
const char *  data,
int  size 
)

Definition at line 117 of file buffer.c.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines


pymongo
Author(s): Bhaskara Marthi
autogenerated on Fri Jan 11 10:09:03 2013