Flutter Engine
The Flutter Engine
|
#include <SkTemplates.h>
Public Member Functions | |
AutoTMalloc (T *ptr=nullptr) | |
AutoTMalloc (size_t count) | |
AutoTMalloc (AutoTMalloc &&)=default | |
AutoTMalloc & | operator= (AutoTMalloc &&)=default |
void | realloc (size_t count) |
T * | reset (size_t count=0) |
T * | get () const |
operator T* () | |
operator const T * () const | |
T & | operator[] (int index) |
const T & | operator[] (int index) const |
const T * | data () const |
T * | data () |
T * | release () |
Manages an array of T elements, freeing the array in the destructor. Does NOT call any constructors/destructors on T (T must be POD).
Definition at line 278 of file SkTemplates.h.
|
inlineexplicit |
Takes ownership of the ptr. The ptr must be a value which can be passed to sk_free.
Definition at line 281 of file SkTemplates.h.
|
inlineexplicit |
|
default |
|
inline |
Definition at line 313 of file SkTemplates.h.
|
inline |
Aliases matching other types, like std::vector.
Definition at line 312 of file SkTemplates.h.
|
inline |
Definition at line 301 of file SkTemplates.h.
|
inline |
Definition at line 305 of file SkTemplates.h.
|
inline |
Definition at line 303 of file SkTemplates.h.
|
default |
|
inline |
Definition at line 307 of file SkTemplates.h.
|
inline |
Definition at line 309 of file SkTemplates.h.
|
inline |
Resize the memory area pointed to by the current ptr preserving contents.
Definition at line 291 of file SkTemplates.h.
|
inline |
Transfer ownership of the ptr to the caller, setting the internal pointer to NULL. Note that this differs from get(), which also returns the pointer, but it does not transfer ownership.
Definition at line 320 of file SkTemplates.h.
|
inline |
Resize the memory area pointed to by the current ptr without preserving contents.
Definition at line 296 of file SkTemplates.h.