#include <aerospike/as_util.h>
#include <aerospike/as_val.h>
#include <stdbool.h>
Go to the source code of this file.
bool as_boolean_getorelse |
( |
const as_boolean * |
boolean, |
|
|
bool |
fallback |
|
) |
| |
|
inline |
Get the bool value. If boolean is NULL, then return the fallback value.
Definition at line 131 of file as_boolean.h.
Initialize a stack allocated as_boolean
with the given boolean value.
- Parameters
-
boolean | The as_boolean to initialize. |
value | The bool value. |
- Returns
- On success, the initialized value. Otherwise NULL.
Creates a new heap allocated as_boolean
and initializes with the given boolean value.
- Parameters
-
- Returns
- On success, the newly allocated value. Otherwise NULL.
bool as_boolean_tobool |
( |
const as_boolean * |
boolean) | |
|
|
inline |
void as_boolean_val_destroy |
( |
as_val * |
v) | |
|
|
private |
Internal helper function for destroying an as_val.
uint32_t as_boolean_val_hashcode |
( |
const as_val * |
v) | |
|
|
private |
Internal helper function for getting the hashcode of an as_val.
char* as_boolean_val_tostring |
( |
const as_val * |
v) | |
|
|
private |
Internal helper function for getting the string representation of an as_val.
False value.
Use this when you need to use an as_boolean
containing true
, rather than allocating a new as_boolean
.
True value.
Use this when you need to use an as_boolean
containing true
, rather than allocating a new as_boolean
.