41 RaveValue_Type_List = 7
struct _RaveList_t RaveList_t
Defines a list.
Definition rave_list.h:33
Generic implementation of an object that is used within rave.
struct _raveobjecttype RaveCoreObjectType
The rave object type definition.
RaveCoreObjectType RaveValue_TYPE
Type definition to use when creating a rave object.
Definition rave_value.c:1167
void RaveValueHash_clear(RaveValue_t *self)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_clear.
Definition rave_value.c:807
void RaveValueList_release(RaveValue_t *self, int index)
If rave value is list, then this provides same functionality as RaveObjectList_release.
Definition rave_value.c:903
int RaveValue_setString(RaveValue_t *self, const char *value)
Sets a string value in self.
Definition rave_value.c:174
RaveValue_t * RaveValueHash_get(RaveValue_t *self, const char *key)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_get.
Definition rave_value.c:762
int RaveValue_getString(RaveValue_t *self, char **value)
Returns the value as a string.
Definition rave_value.c:197
int RaveValue_getLongArray(RaveValue_t *self, long **value, int *len)
Returns the value as a long array.
Definition rave_value.c:528
int RaveValue_getList(RaveValue_t *self, RaveObjectList_t **rlist)
Returns the rave list if possible.
Definition rave_value.c:848
int RaveValueHash_size(RaveValue_t *self)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_size.
Definition rave_value.c:777
RaveValue_t * RaveValue_createString(const char *value)
Creates a string rave value.
Definition rave_value.c:163
void RaveValue_setBoolean(RaveValue_t *self, int value)
Sets the value as a boolean.
Definition rave_value.c:301
int RaveValue_getHashTable(RaveValue_t *self, RaveObjectHashTable_t **table)
Returns the hash table if possible.
Definition rave_value.c:735
char * RaveValue_toJSON(RaveValue_t *self)
Translates self to a json representation.
Definition rave_value.c:998
RaveValue_t * RaveValue_loadJSON(const char *filename)
Loads a JSON object from a file.
Definition rave_value.c:1149
RaveValue_t * RaveValue_createList(RaveObjectList_t *rlist)
Creates a rave value list.
Definition rave_value.c:825
RaveValue_Type RaveValue_type(RaveValue_t *self)
Returns the format for this attribute.
Definition rave_value.c:144
int RaveValueHash_exists(RaveValue_t *self, const char *key)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_exists.
Definition rave_value.c:786
int RaveValue_setStringArray(RaveValue_t *self, const char **value, int len)
Sets the value as a simple 1-dimensional string array.
Definition rave_value.c:384
int RaveValue_isStringArray(RaveValue_t *self)
Returns if the rave value can be represented as a string array (list of strings only)
Definition rave_value.c:351
int RaveValue_toBoolean(RaveValue_t *self)
Returns the boolean value.
Definition rave_value.c:321
int RaveValue_getStringArray(RaveValue_t *self, char ***value, int *len)
Returns the value as a string array.
Definition rave_value.c:417
RaveList_t * RaveValueHash_keys(RaveValue_t *self)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_keys.
Definition rave_value.c:815
const char * RaveValue_toString(RaveValue_t *self)
Returns the string value.
Definition rave_value.c:209
int RaveValueList_add(RaveValue_t *self, RaveValue_t *value)
If rave value is list, then this provides same functionality as RaveObjectList_add.
Definition rave_value.c:865
RaveValue_t * RaveValue_createLongArray(long *value, int len)
Creates a long array rave value.
Definition rave_value.c:489
RaveValue_t * RaveValueList_get(RaveValue_t *self, int index)
If rave value is list, then this provides same functionality as RaveObjectList_get.
Definition rave_value.c:894
void RaveValue_setLong(RaveValue_t *self, long value)
Sets the value as a long.
Definition rave_value.c:226
RaveValue_t * RaveValue_createNull()
Creates a null rave value.
Definition rave_value.c:327
RaveValue_t * RaveValue_createStringArray(const char **value, int len)
Creates a string array rave value.
Definition rave_value.c:373
int RaveValue_setHashTable(RaveValue_t *self, RaveObjectHashTable_t *table)
Sets the value as a hash table.
Definition rave_value.c:724
void RaveValueHash_remove(RaveValue_t *self, const char *key)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_remove except tha...
Definition rave_value.c:798
int RaveValue_setLongArray(RaveValue_t *self, long *value, int len)
Sets the value as a simple 1-dimensional long array.
Definition rave_value.c:500
RaveObjectList_t * RaveValue_toList(RaveValue_t *self)
NOTE!
Definition rave_value.c:859
int RaveValue_setList(RaveValue_t *self, RaveObjectList_t *rlist)
Sets the value as a rave list.
Definition rave_value.c:836
RaveValue_t * RaveValue_createBoolean(int value)
Creates a boolean rave value.
Definition rave_value.c:290
int RaveValue_isLongArray(RaveValue_t *self)
Returns if the rave value can be represented as a long array (list of long only)
Definition rave_value.c:468
RaveObjectHashTable_t * RaveValue_toHashTable(RaveValue_t *self)
NOTE!
Definition rave_value.c:746
int RaveValueList_insert(RaveValue_t *self, int index, RaveValue_t *value)
If rave value is list, then this provides same functionality as RaveObjectList_insert.
Definition rave_value.c:875
int RaveValue_getDouble(RaveValue_t *self, double *value)
Returns the value as a double.
Definition rave_value.c:272
int RaveValue_getLong(RaveValue_t *self, long *value)
Returns the value as a long.
Definition rave_value.c:234
struct _RaveValue_t RaveValue_t
Defines a rave value.
Definition rave_value.h:47
void RaveValue_reset(RaveValue_t *self)
Resets the value object.
Definition rave_value.c:150
long RaveValue_toLong(RaveValue_t *self)
Returns the long value.
Definition rave_value.c:246
RaveValue_t * RaveValue_createDoubleArray(double *value, int len)
Creates a double array rave value.
Definition rave_value.c:591
int RaveValueHash_put(RaveValue_t *self, const char *key, RaveValue_t *value)
If rave value is hash, then this provides same functionality as RaveObjectHashTable_put.
Definition rave_value.c:752
int RaveValue_isDoubleArray(RaveValue_t *self)
Returns if the rave value can be represented as a double array (list of double only)
Definition rave_value.c:570
RaveValue_t * RaveValue_createDouble(double value)
Creates a double rave value.
Definition rave_value.c:252
RaveValue_t * RaveValue_createLong(long value)
Creates a long rave value.
Definition rave_value.c:215
int RaveValue_isNull(RaveValue_t *self)
Returns if the value is null or not.
Definition rave_value.c:345
double RaveValue_toDouble(RaveValue_t *self)
Returns the double value.
Definition rave_value.c:284
RaveValue_Type
Definition rave_value.h:32
@ RaveValue_Type_String
String.
Definition rave_value.h:34
@ RaveValue_Type_Long
Long.
Definition rave_value.h:35
@ RaveValue_Type_Boolean
Boolean.
Definition rave_value.h:37
@ RaveValue_Type_Hashtable
Hash table.
Definition rave_value.h:40
@ RaveValue_Type_Data2D
2D array
Definition rave_value.h:39
@ RaveValue_Type_Undefined
Undefined.
Definition rave_value.h:33
@ RaveValue_Type_Null
Null.
Definition rave_value.h:38
@ RaveValue_Type_Double
Double.
Definition rave_value.h:36
int RaveValueList_size(RaveValue_t *self)
If rave value is list, then this provides same functionality as RaveObjectList_size.
Definition rave_value.c:885
RaveValue_t * RaveValue_fromJSON(const char *json)
Support function for translating a json structure to a rave value.
Definition rave_value.c:1127
int RaveValue_setDoubleArray(RaveValue_t *self, double *value, int len)
Sets the value as a simple 1-dimensional double array.
Definition rave_value.c:602
void RaveValue_setDouble(RaveValue_t *self, double value)
Sets the value as a double.
Definition rave_value.c:264
RaveValue_t * RaveValue_createHashTable(RaveObjectHashTable_t *hashtable)
Creates a rave value hash table.
Definition rave_value.c:676
int RaveValue_getBoolean(RaveValue_t *self, int *value)
Returns the value as a boolean.
Definition rave_value.c:309
int RaveValue_getDoubleArray(RaveValue_t *self, double **value, int *len)
Returns the value as a double array.
Definition rave_value.c:630
void RaveValueList_clear(RaveValue_t *self)
If rave value is list, then this provides same functionality as RaveObjectList_clear.
Definition rave_value.c:911
void RaveValue_setNull(RaveValue_t *self)
Sets the value as a null value.
Definition rave_value.c:338
Implementation of a rave object hashtable that maps between strings and rave core objects.
struct _RaveObjectHashTable_t RaveObjectHashTable_t
Defines a hash table.
Definition raveobject_hashtable.h:38
struct _RaveObjectList_t RaveObjectList_t
Defines a list.
Definition raveobject_list.h:38
Represents one scan in a volume.
Definition rave_value.c:47
RaveObjectHashTable_t * hashtable
the hash table
Definition rave_value.c:54