25#ifndef RAVE_HLHDF_UTILITIES_H
26#define RAVE_HLHDF_UTILITIES_H
36#define RAVE_ODIM_VERSION_2_0_STR "ODIM_H5/V2_0"
41#define RAVE_ODIM_VERSION_2_1_STR "ODIM_H5/V2_1"
46#define RAVE_ODIM_VERSION_2_2_STR "ODIM_H5/V2_2"
51#define RAVE_ODIM_VERSION_2_3_STR "ODIM_H5/V2_3"
56#define RAVE_ODIM_VERSION_2_4_STR "ODIM_H5/V2_4"
61#define RAVE_ODIM_H5RAD_VERSION_2_0_STR "H5rad 2.0"
66#define RAVE_ODIM_H5RAD_VERSION_2_1_STR "H5rad 2.1"
71#define RAVE_ODIM_H5RAD_VERSION_2_2_STR "H5rad 2.2"
76#define RAVE_ODIM_H5RAD_VERSION_2_3_STR "H5rad 2.3"
81#define RAVE_ODIM_H5RAD_VERSION_2_4_STR "H5rad 2.4"
110typedef int (*
RaveHL_group_f)(
void* object,
const char* groupname,
const char* name);
282 HL_NodeList* nodelist,
287 const char* fmt, ...);
struct _RaveAttribute_t RaveAttribute_t
Defines a rave attribute.
Definition rave_attribute.h:47
RaveAttribute_t * RaveHL_createAttribute(HL_Node *node)
Creates a rave attribute from a HLHDF node value.
Definition rave_hlhdf_utilities.c:260
RaveDataType RaveHL_hlhdfToRaveType(HL_FormatSpecifier format)
Translates a hlhdf format specified into a rave data type.
Definition rave_hlhdf_utilities.c:1045
int RaveHL_addAttribute(HL_NodeList *nodelist, RaveAttribute_t *attribute, const char *fmt,...)
Puts an attribute in the nodelist as a hlhdf node.
Definition rave_hlhdf_utilities.c:578
int RaveHL_getStringValue(HL_NodeList *nodelist, char **value, const char *fmt,...)
Gets a string value from a nodelist that is represented by a node named according to the varargs form...
Definition rave_hlhdf_utilities.c:419
int RaveHL_createDataset(HL_NodeList *nodelist, void *data, long xsize, long ysize, RaveDataType dataType, const char *fmt,...)
Creates a dataset with the provided 2-dimensional array.
Definition rave_hlhdf_utilities.c:933
const char * RaveHL_getOdimVersionString(RaveIO_ODIM_Version version)
Returns the string representation of the specified odim version.
Definition rave_hlhdf_utilities.c:209
RaveAttribute_t * RaveHL_getAttribute(HL_NodeList *nodelist, const char *fmt,...)
Tries to find the node as defined by the varargs string and then create a rave attribute from it.
Definition rave_hlhdf_utilities.c:365
const char * RaveHL_getH5RadVersionStringFromOdimVersion(RaveIO_ODIM_Version version)
Returns the h5rad string representation of the specified odim version since we can assume that the h5...
Definition rave_hlhdf_utilities.c:225
int RaveHL_createGroupUnlessExists(HL_NodeList *nodelist, const char *fmt,...)
Creates a group node in the node list unless it already exists.
Definition rave_hlhdf_utilities.c:492
int RaveHL_addAttributes(HL_NodeList *nodelist, RaveObjectList_t *attributes, const char *name)
Stores the attributes from the object into the nodelist name/how/..., name/where/....
Definition rave_hlhdf_utilities.c:843
int RaveHL_addRaveValue(HL_NodeList *nodelist, RaveValue_t *value, const char *fmt,...)
Adds a rave value in the nodelist as a hlhdf node.
Definition rave_hlhdf_utilities.c:681
int RaveHL_createStringValue(HL_NodeList *nodelist, const char *value, const char *fmt,...)
Adds a string value to a nodelist.
Definition rave_hlhdf_utilities.c:527
int RaveHL_addData(HL_NodeList *nodelist, void *data, long xsize, long ysize, RaveDataType dataType, const char *fmt,...)
Adds a data field to the node list according to ODIM H5.
Definition rave_hlhdf_utilities.c:976
RaveIO_ODIM_Version RaveHL_getOdimVersionFromString(const char *str)
Returns the odim version for the string representation of the ODIM version.
Definition rave_hlhdf_utilities.c:240
int RaveHL_hasNodeByName(HL_NodeList *nodelist, const char *fmt,...)
Verifies if the file contains a node with the name as specified by the variable argument list.
Definition rave_hlhdf_utilities.c:403
const char * RaveHL_convertQuantity(const char *name)
Translates a quantity from 2.0/2.1 ODIM into 2.2 ODIM.
Definition rave_hlhdf_utilities.c:193
RaveList_t * RaveHL_extractSubGroups(const char *attrname)
Extract all subgroups for an attribute name.
Definition rave_hlhdf_utilities.c:815
HL_FormatSpecifier RaveHL_raveToHlhdfType(RaveDataType format)
Translates a rave data type into a hlhdf format specifier.
Definition rave_hlhdf_utilities.c:1031
int RaveHL_createGroup(HL_NodeList *nodelist, const char *fmt,...)
Creates a group node in the node list.
Definition rave_hlhdf_utilities.c:461
int(* RaveHL_attr_f)(void *object, RaveAttribute_t *attr)
Attribute function called when an attribute is found.
Definition rave_hlhdf_utilities.h:89
int RaveHL_loadAttributesAndData(HL_NodeList *nodelist, void *object, RaveHL_attr_f attrf, RaveHL_data_f dataf, const char *fmt,...)
Loads the attributes from the nodelist name and calls the attrf and dataf respectively depending on w...
Definition rave_hlhdf_utilities.c:1068
const char * RaveHL_convertAttributeName(const char *name)
Translates an attribute name from 2.0/2.1 ODIM into 2.2 ODIM.
Definition rave_hlhdf_utilities.c:180
int(* RaveHL_group_f)(void *object, const char *groupname, const char *name)
Group function called when a group is found.
Definition rave_hlhdf_utilities.h:110
int(* RaveHL_data_f)(void *object, hsize_t xsize, hsize_t ysize, void *data, RaveDataType dtype, const char *nodeName)
Data function called when an dataset is found.
Definition rave_hlhdf_utilities.h:101
struct _RaveList_t RaveList_t
Defines a list.
Definition rave_list.h:33
Type definitions for RAVE.
RaveIO_ODIM_Version
The /Conventions version in a ODIM HDF5 file.
Definition rave_types.h:43
RaveDataType
Different data types that are supported during transformation.
Definition rave_types.h:130
Contains various utility functions that makes life easier when working with the rave framework.
A value object that can represent standard types like int, double, .
struct _RaveValue_t RaveValue_t
Defines a rave value.
Definition rave_value.h:47
struct _RaveObjectList_t RaveObjectList_t
Defines a list.
Definition raveobject_list.h:38