26#ifndef RAVE_UTILITIES_H
27#define RAVE_UTILITIES_H
35#define strcasecmp(x, y) _stricmp(x,y)
Used for keeping track on attributes.
struct _RaveList_t RaveList_t
Defines a list.
Definition rave_list.h:33
RaveIO_ODIM_Version
The /Conventions version in a ODIM HDF5 file.
Definition rave_types.h:43
char * RaveUtilities_trimText(const char *str, int len)
Trims the text from all leading and trailing whitespaces.
Definition rave_utilities.c:205
char * RaveUtilities_toUpper(const char *str, int len)
Translates a string to upper case.
Definition rave_utilities.c:258
int RaveUtilities_addDoubleAttributeToList(RaveObjectList_t *l, const char *name, double value)
Adds a double attribute to an object list.
Definition rave_utilities.c:49
void RaveUtilities_removeAttributeFromList(RaveObjectList_t *l, const char *name)
Removes the rave attribute with specified name from the list.
Definition rave_utilities.c:162
char * RaveUtilities_toLower(const char *str, int len)
Translates a string to lower case.
Definition rave_utilities.c:242
int RaveUtilities_getRaveAttributeDoubleFromHash(RaveObjectHashTable_t *h, const char *name, double *v)
Gets the double value from a rave attribute that resides in a hash table.
Definition rave_utilities.c:182
int RaveUtilities_addStringAttributeToList(RaveObjectList_t *l, const char *name, const char *value)
Adds a string attribute to an object list.
Definition rave_utilities.c:64
int RaveUtilities_isLegacyProjEnabled(void)
Returns if legacy PROJ (PROJ.4 and PROJ 5) is enabled or not.
Definition rave_utilities.c:375
int RaveUtilities_arrayContains(const char *arr[], const char *str, int casecmp)
Checks if the array arr contains the string str.
Definition rave_utilities.c:335
int RaveUtilities_isCFConventionSupported(void)
Returns if CF convention IO support is activated or not.
Definition rave_utilities.c:366
int RaveUtilities_isXmlSupported(void)
Returns if xml support is activated or not since expat support is optional and ought to be tested.
Definition rave_utilities.c:357
int RaveUtilities_replaceStringAttributeInList(RaveObjectList_t *l, const char *name, const char *value)
Replaces the content of a attribute in the object list.
Definition rave_utilities.c:134
int RaveUtilities_addLongAttributeToList(RaveObjectList_t *l, const char *name, long value)
Adds a long attribute to an object list.
Definition rave_utilities.c:34
char * RaveUtilities_handleSourceVersion(const char *source, RaveIO_ODIM_Version version)
Handles the source value according to version.
Definition rave_utilities.c:384
int RaveUtilities_replaceDoubleAttributeInList(RaveObjectList_t *l, const char *name, double value)
Replaces the content of a attribute in the object list.
Definition rave_utilities.c:107
int RaveUtilities_isSourceValid(const char *source, RaveIO_ODIM_Version version)
Verifies if the source is valid according to ODIM version rules.
Definition rave_utilities.c:427
RaveList_t * RaveUtilities_getTrimmedTokens(const char *str, int c)
Returns a list of tokens delimited by 'c'.
Definition rave_utilities.c:274
int RaveUtilities_iswhitespace(char c)
Returns if the character is a whitespace character or not, i.e.
Definition rave_utilities.c:199
int RaveUtilities_replaceLongAttributeInList(RaveObjectList_t *l, const char *name, long value)
Replaces the content of a attribute in the object list.
Definition rave_utilities.c:79
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
Implementation of a rave object list that ensures that the objects contained within the list are rele...
struct _RaveObjectList_t RaveObjectList_t
Defines a list.
Definition raveobject_list.h:38