C Container Collection (CCC)
Loading...
Searching...
No Matches
CCC_Buffer Struct Reference

#include <private_buffer.h>

Detailed Description

A Buffer is a contiguous array of a uniform type. The user can specify any type. The Buffer can be fixed size if no allocation permission is given or dynamic if allocation permission is granted. The Buffer can also be manually resized via the interface.

Data Fields

void * data
 
size_t count
 
size_t capacity
 
size_t sizeof_type
 
CCC_Allocatorallocate
 
void * context
 

Field Documentation

◆ allocate

CCC_Allocator* CCC_Buffer::allocate

An allocation function for resizing, if allowed.

◆ capacity

size_t CCC_Buffer::capacity

The total Buffer slots possible for this array.

◆ context

void* CCC_Buffer::context

Auxiliary data, if any.

◆ count

size_t CCC_Buffer::count

The current count of active Buffer slots.

◆ data

void* CCC_Buffer::data

The contiguous memory of uniform type.

◆ sizeof_type

size_t CCC_Buffer::sizeof_type

The size of the type the user stores in the buffer.


The documentation for this struct was generated from the following file: