![]() |
kinetic-c
v0.12.0
Seagate Kinetic Protocol Client Library for C
|
#include "byte_array.h"
#include <assert.h>
#include <string.h>
#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
#include <sys/param.h>
Go to the source code of this file.
|
static |
Definition at line 191 of file byte_array.c.
References ByteBuffer::array, ByteBuffer_BytesRemaining(), ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteArray ByteArray_Create | ( | void * | data, |
size_t | len | ||
) |
Definition at line 31 of file byte_array.c.
References ByteArray::data.
ByteArray ByteArray_CreateWithCString | ( | const char * | str | ) |
Definition at line 38 of file byte_array.c.
References ByteArray::data.
void ByteArray_FillWithDummyData | ( | ByteArray | array | ) |
Definition at line 45 of file byte_array.c.
References ByteArray::data, and ByteArray::len.
Definition at line 52 of file byte_array.c.
References ByteArray::data, and ByteArray::len.
void ByteBuffer_Reset | ( | ByteBuffer * | buffer | ) |
Definition at line 62 of file byte_array.c.
References ByteBuffer::bytesUsed.
ByteBuffer ByteBuffer_Create | ( | void * | data, |
size_t | max_len, | ||
size_t | used | ||
) |
Definition at line 68 of file byte_array.c.
ByteBuffer ByteBuffer_CreateWithArray | ( | ByteArray | array | ) |
Definition at line 78 of file byte_array.c.
References ByteBuffer::array.
ByteBuffer ByteBuffer_CreateAndAppend | ( | void * | data, |
size_t | max_len, | ||
const void * | value, | ||
size_t | value_len | ||
) |
Definition at line 83 of file byte_array.c.
References ByteBuffer_Append(), and ByteBuffer_Create().
ByteBuffer ByteBuffer_CreateAndAppendArray | ( | void * | data, |
size_t | max_len, | ||
const ByteArray | value | ||
) |
Definition at line 90 of file byte_array.c.
References ByteBuffer_AppendArray(), and ByteBuffer_Create().
ByteBuffer ByteBuffer_CreateAndAppendCString | ( | void * | data, |
size_t | max_len, | ||
const char * | value | ||
) |
Definition at line 97 of file byte_array.c.
References ByteBuffer_AppendCString(), and ByteBuffer_Create().
ByteBuffer ByteBuffer_CreateAndAppendDummyData | ( | void * | data, |
size_t | max_len, | ||
size_t | len | ||
) |
Definition at line 104 of file byte_array.c.
References ByteBuffer_AppendDummyData(), and ByteBuffer_Create().
long ByteBuffer_BytesRemaining | ( | const ByteBuffer | buffer | ) |
Definition at line 111 of file byte_array.c.
References ByteBuffer::array, ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteArray ByteBuffer_Consume | ( | ByteBuffer * | buffer, |
size_t | max_len | ||
) |
Definition at line 117 of file byte_array.c.
References ByteBuffer::array, BYTE_ARRAY_NONE, ByteBuffer_BytesRemaining(), ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteBuffer* ByteBuffer_Append | ( | ByteBuffer * | buffer, |
const void * | data, | ||
size_t | len | ||
) |
Definition at line 135 of file byte_array.c.
References ByteBuffer::array, ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteBuffer* ByteBuffer_AppendArray | ( | ByteBuffer * | buffer, |
const ByteArray | array | ||
) |
Definition at line 149 of file byte_array.c.
References ByteBuffer::array, ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteBuffer* ByteBuffer_AppendBuffer | ( | ByteBuffer * | buffer, |
const ByteBuffer | bufferToAppend | ||
) |
Definition at line 162 of file byte_array.c.
References ByteBuffer::array, ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteBuffer* ByteBuffer_AppendCString | ( | ByteBuffer * | buffer, |
const char * | str | ||
) |
Definition at line 176 of file byte_array.c.
References ByteBuffer::array, ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
ByteBuffer* ByteBuffer_AppendFormattedCString | ( | ByteBuffer * | buffer, |
const char * | format, | ||
... | |||
) |
Definition at line 205 of file byte_array.c.
References append_formatted_cstring_va_list(), ByteBuffer::array, and ByteArray::data.
ByteBuffer ByteBuffer_CreateAndAppendFormattedCString | ( | void * | data, |
size_t | max_len, | ||
const char * | format, | ||
... | |||
) |
Definition at line 221 of file byte_array.c.
References append_formatted_cstring_va_list(), and ByteBuffer_Create().
ByteBuffer* ByteBuffer_AppendDummyData | ( | ByteBuffer * | buffer, |
size_t | len | ||
) |
Definition at line 235 of file byte_array.c.
References ByteBuffer::array, ByteBuffer::bytesUsed, ByteArray::data, and ByteArray::len.
bool ByteBuffer_IsNull | ( | ByteBuffer const | buffer | ) |
Definition at line 249 of file byte_array.c.
References ByteBuffer::array, and ByteArray::data.
ByteBuffer ByteBuffer_Malloc | ( | size_t | size | ) |
Definition at line 254 of file byte_array.c.
References ByteBuffer_Create().
ByteBuffer ByteBuffer_MallocAndAppend | ( | const void * | data, |
size_t | len | ||
) |
Definition at line 262 of file byte_array.c.
References ByteBuffer_Append(), ByteBuffer_IsNull(), and ByteBuffer_Malloc().
void ByteBuffer_Free | ( | ByteBuffer | buffer | ) |
Definition at line 272 of file byte_array.c.
References ByteBuffer::array, and ByteArray::data.