bes Updated for version 3.20.13
h5common.cc File Reference
#include "h5common.h"
#include <string.h>
#include <libdap/InternalErr.h>
#include <BESDebug.h>
Include dependency graph for h5common.cc:

Go to the source code of this file.

Functions

void get_data (hid_t dset, void *buf)
 
int get_slabdata (hid_t dset, const int *offset, const int *step, const int *count, const int num_dim, void *buf)
 
void get_strdata (int strindex, char *allbuf, char *buf, int elesize)
 
void get_vlen_str_data (const char *temp_bp, string &finalstr_val)
 
bool promote_char_to_short (H5T_class_t type_cls, hid_t type_id)
 
bool read_vlen_string (hid_t dsetid, const int nelms, const hsize_t *hoffset, const hsize_t *hstep, const hsize_t *hcount, vector< string > &finstrval)
 

Detailed Description

Common helper functions to access HDF5 data for both the CF and the default options.

Definition in file h5common.cc.

Function Documentation

◆ get_data()

get_data ( hid_t  dset,
void *  buf 
)
Parameters
[in]dsetdataset id(dset)
[out]bufpointer to a buffer

will get all data of a dset dataset and put it into buf. Note: this routine is only used to access HDF5 integer,float and fixed-size string.

Definition at line 50 of file h5common.cc.

◆ get_slabdata()

int get_slabdata ( hid_t  dset,
const int offset,
const int step,
const int count,
const int  num_dim,
void *  buf 
)

Definition at line 149 of file h5common.cc.

◆ get_strdata()

get_strdata ( int  strindex,
char *  allbuf,
char *  buf,
int  elesize 
)

will get an individual string data from all string data elements and put it into buf.

Parameters
[in]strindexindex of H5T_STRING array
[in]allbufpointer to string buffer that has been built so far
[in]elesizesize of string element in the array
[out]bufpointer to a buf
Returns
void

Definition at line 115 of file h5common.cc.

◆ get_vlen_str_data()

void get_vlen_str_data ( const char *  temp_bp,
string &  finalstr_val 
)

Definition at line 382 of file h5common.cc.

◆ promote_char_to_short()

bool promote_char_to_short ( H5T_class_t  type_cls,
hid_t  type_id 
)

Definition at line 368 of file h5common.cc.

◆ read_vlen_string()

bool read_vlen_string ( hid_t  dsetid,
const int  nelms,
const hsize_t *  hoffset,
const hsize_t *  hstep,
const hsize_t *  hcount,
vector< string > &  finstrval 
)

Definition at line 244 of file h5common.cc.