#include <io_buffer.h>
Definition at line 14 of file io_buffer.h.
◆ Allocate() [1/2]
uint8_t * dart::bin::IOBuffer::Allocate |
( |
intptr_t |
size | ) |
|
|
static |
Definition at line 30 of file io_buffer.cc.
30 {
31 return static_cast<uint8_t*
>(
calloc(size,
sizeof(uint8_t)));
32}
void * calloc(size_t n, size_t size)
◆ Allocate() [2/2]
Dart_Handle dart::bin::IOBuffer::Allocate |
( |
intptr_t |
size, |
|
|
uint8_t ** |
buffer |
|
) |
| |
|
static |
Definition at line 12 of file io_buffer.cc.
12 {
14 if (
data ==
nullptr) {
16 }
19
23 }
26 }
28}
static void Free(void *buffer)
static void Finalizer(void *isolate_callback_data, void *buffer)
static Dart_Handle Allocate(intptr_t size, uint8_t **buffer)
struct _Dart_Handle * Dart_Handle
static const uint8_t buffer[]
DART_EXPORT Dart_Handle Dart_NewExternalTypedDataWithFinalizer(Dart_TypedData_Type type, void *data, intptr_t length, void *peer, intptr_t external_allocation_size, Dart_HandleFinalizer callback)
DART_EXPORT void Dart_PropagateError(Dart_Handle handle)
DART_EXPORT bool Dart_IsError(Dart_Handle handle)
DART_EXPORT Dart_Handle Dart_Null()
static int8_t data[kExtLength]
◆ Finalizer()
static void dart::bin::IOBuffer::Finalizer |
( |
void * |
isolate_callback_data, |
|
|
void * |
buffer |
|
) |
| |
|
inlinestatic |
◆ Free()
static void dart::bin::IOBuffer::Free |
( |
void * |
buffer | ) |
|
|
inlinestatic |
◆ Reallocate()
uint8_t * dart::bin::IOBuffer::Reallocate |
( |
uint8_t * |
buffer, |
|
|
intptr_t |
new_size |
|
) |
| |
|
static |
Definition at line 34 of file io_buffer.cc.
34 {
35
36
37
38
39
41 if (new_buffer != nullptr) {
42 memmove(new_buffer,
buffer, new_size);
44 return static_cast<uint8_t*>(new_buffer);
45 }
47}
void * realloc(void *ptr, size_t size)
The documentation for this class was generated from the following files: