Memory Advice debugging functions
Summary
| Typedefs | |
|---|---|
| MemoryAdvice_JsonSerialization | typedef A char* representing a serialized json object.  | 
| Variables | |
|---|---|
| dealloc)(struct MemoryAdvice_JsonSerialization *) | void(* | 
| json | char *String for the json object.  | 
| size | uint32_tSize of the json string.  | 
| Functions | |
|---|---|
| MemoryAdvice_JsonSerialization_free(MemoryAdvice_JsonSerialization *ser) | voidDeallocate any memory owned by the json serialization.  | 
| MemoryAdvice_getAdvice(MemoryAdvice_JsonSerialization *advice) | Returns the advice regarding the current memory state.  | 
| MemoryAdvice_test() | int32_tPerform tests on the memory advice library.  | 
| Structs | |
|---|---|
| MemoryAdvice_JsonSerialization | A char* representing a serialized json object. | 
Typedefs
MemoryAdvice_JsonSerialization
struct MemoryAdvice_JsonSerialization MemoryAdvice_JsonSerialization
A char* representing a serialized json object.
See also:MemoryAdvice_JsonSerialization_free for how to deallocate the memory once finished with the buffer.
Variables
dealloc
void(* dealloc)(struct MemoryAdvice_JsonSerialization *)
json
char * json
String for the json object.
size
uint32_t size
Size of the json string.
Deallocation callback (may be NULL if not owned).
Functions
MemoryAdvice_JsonSerialization_free
void MemoryAdvice_JsonSerialization_free( MemoryAdvice_JsonSerialization *ser )
Deallocate any memory owned by the json serialization.
| Details | |||
|---|---|---|---|
| Parameters | 
 | 
MemoryAdvice_getAdvice
MemoryAdvice_ErrorCode MemoryAdvice_getAdvice( MemoryAdvice_JsonSerialization *advice )
Returns the advice regarding the current memory state.
| Details | |||
|---|---|---|---|
| Parameters | 
 | ||
| Returns | MEMORYADVICE_ERROR_OK if successful,  | ||
| Returns | MEMORYADVICE_ERROR_NOT_INITIALIZED if Memory Advice was not yet initialized.  | 
MemoryAdvice_test
int32_t MemoryAdvice_test()
Perform tests on the memory advice library.
| Details | |
|---|---|
| Returns | 0 if the tests pass.  | 
| Returns | non-zero if the tests fail. Error messages will be printed to logcat in this case.  | 
