Main Page | Modules | Data Structures | File List | Data Fields | Globals | Related Pages

The Circular-Buff Library
[Helper Components]

Library that provides a method for writing and reading to/from a circular buffer. More...


Files

file  circ_buff.c
 This is the implementation of the Circular-Buffer Library.

file  circ_buff.h
 This is the header for the Circular-Buffer Library.


Data Structures

struct  circ_buff
 Storage structure for a key value pair. More...


Defines

#define _GNU_SOURCE

Typedefs

typedef circ_buff circ_buff_t

Functions

int circ_buff_init (circ_buff_t **new_buff, long buff_size)
void circ_buff_destroy (circ_buff_t *new_buff)
int circ_buff_init_thread (circ_buff_t *new_buff, long *thread_read_pnt, unsigned long long *thread_byte_id, struct timespec *timeout)
int circ_buff_wait_to_start (circ_buff_t *new_buff, unsigned long long thread_byte_id, struct timespec *timeout)
int circ_buff_wait_for_read (circ_buff_t *new_buff, struct timespec *timeout)
int circ_buff_wait_for_write (circ_buff_t *new_buff, struct timespec *timeout)
int circ_buff_resize (circ_buff_t *new_buff, long new_size, struct timespec *timeout)
long circ_buff_read (circ_buff_t *new_buff, void *read_data, long bytes_to_read, struct timespec *timeout)
long circ_buff_read_thread (circ_buff_t *new_buff, void *read_data, long *thread_read_pnt, unsigned long long *thread_byte_id, long read_size, struct timespec *timeout)
long circ_buff_write (circ_buff_t *new_buff, void *write_data, long bytes_to_write, struct timespec *timeout)

Detailed Description

Library that provides a method for writing and reading to/from a circular buffer.


Define Documentation

#define _GNU_SOURCE
 


Typedef Documentation

typedef struct circ_buff circ_buff_t
 


Function Documentation

void circ_buff_destroy circ_buff_t new_buff  ) 
 

int circ_buff_init circ_buff_t **  new_buff,
long  buff_size
 

int circ_buff_init_thread circ_buff_t new_buff,
long *  thread_read_pnt,
unsigned long long *  thread_byte_id,
struct timespec *  timeout
 

long circ_buff_read circ_buff_t new_buff,
void *  read_data,
long  bytes_to_read,
struct timespec *  timeout
 

long circ_buff_read_thread circ_buff_t new_buff,
void *  read_data,
long *  thread_read_pnt,
unsigned long long *  thread_byte_id,
long  read_size,
struct timespec *  timeout
 

int circ_buff_resize circ_buff_t new_buff,
long  new_size,
struct timespec *  timeout
 

int circ_buff_wait_for_read circ_buff_t new_buff,
struct timespec *  timeout
 

Warning:
timeout.tv_sec cannot exceed the maximum value of a long integer
  • the current number of seconds since 00:00:00 GMT January 1, 1970.

int circ_buff_wait_for_write circ_buff_t new_buff,
struct timespec *  timeout
 

int circ_buff_wait_to_start circ_buff_t new_buff,
unsigned long long  thread_byte_id,
struct timespec *  timeout
 

long circ_buff_write circ_buff_t new_buff,
void *  write_data,
long  bytes_to_write,
struct timespec *  timeout
 


Generated on Thu Dec 16 23:07:32 2004 for alsad by doxygen 1.3.6