#include <cctype>
#include <iomanip>
#include <istream>
#include <limits>
#include <ostream>
#include <string>
#include <vector>
#include "byte-swap.h"
#include "data-conv.h"
#include "file-ops.h"
#include "glob-match.h"
#include "lo-mappers.h"
#include "mach-info.h"
#include "oct-env.h"
#include "oct-time.h"
#include "quit.h"
#include "str-vec.h"
#include "oct-locbuf.h"
#include "Cell.h"
#include "defun.h"
#include "error.h"
#include "errwarn.h"
#include "interpreter.h"
#include "interpreter-private.h"
#include "load-save.h"
#include "oct-hdf5.h"
#include "ovl.h"
#include "oct-map.h"
#include "ov-cell.h"
#include "pager.h"
#include "sysdep.h"
#include "unwind-prot.h"
#include "utils.h"
#include "variables.h"
#include "version.h"
#include "dMatrix.h"
#include "ov-lazy-idx.h"
#include "ls-utils.h"
#include "ls-hdf5.h"
Go to the source code of this file.
Functions | |
bool | add_hdf5_data (octave_hdf5_id loc_id, const octave_value &tc, const std::string &name, const std::string &doc, bool mark_global, bool save_as_floats) |
static hid_t | check_hdf5_id_value (octave_hdf5_id id, const char *who) |
octave_hdf5_err | hdf5_add_attr (octave_hdf5_id loc_id, const char *attr_name) |
octave_hdf5_err | hdf5_add_scalar_attr (octave_hdf5_id loc_id, octave_hdf5_id type_id, const char *attr_name, void *buf) |
bool | hdf5_check_attr (octave_hdf5_id loc_id, const char *attr_name) |
bool | hdf5_get_scalar_attr (octave_hdf5_id loc_id, octave_hdf5_id type_id, const char *attr_name, void *buf) |
octave_hdf5_err | hdf5_h5g_iterate (octave_hdf5_id loc_id, const char *name, int *idx, void *operator_data) |
octave_hdf5_id | hdf5_make_complex_type (octave_hdf5_id num_type) |
static hid_t | hdf5_make_range_type (hid_t num_type) |
octave_hdf5_err | hdf5_read_next_data (octave_hdf5_id group_id, const char *name, void *dv) |
static herr_t | hdf5_read_next_data_internal (hid_t group_id, const char *name, void *dv) |
bool | hdf5_types_compatible (octave_hdf5_id t1, octave_hdf5_id t2) |
int | load_hdf5_empty (octave_hdf5_id loc_id, const char *name, dim_vector &d) |
static herr_t | load_inline_fcn (hid_t loc_id, const char *name, octave_value &retval) |
static std::string | make_valid_identifier (const std::string &nm) |
std::string | read_hdf5_data (std::istream &is, const std::string &, bool &global, octave_value &tc, std::string &doc, const string_vector &argv, int argv_idx, int argc) |
bool | save_hdf5_data (std::ostream &os, const octave_value &tc, const std::string &name, const std::string &doc, bool mark_global, bool save_as_floats) |
int | save_hdf5_empty (octave_hdf5_id loc_id, const char *name, const dim_vector &d) |
octave_hdf5_id | save_type_to_hdf5 (save_type st) |
bool add_hdf5_data | ( | octave_hdf5_id | loc_id, |
const octave_value & | tc, | ||
const std::string & | name, | ||
const std::string & | doc, | ||
bool | mark_global, | ||
bool | save_as_floats | ||
) |
Definition at line 1380 of file ls-hdf5.cc.
References err_disabled_feature(), error(), octave_value::full_value(), hdf5_add_attr(), octave_value::is_diag_matrix(), octave_value::is_perm_matrix(), name, octave_H5P_DEFAULT, octave_H5S_ALL, retval, octave_value::save_hdf5(), octave_lazy_index::static_type_id(), octave_value::type_id(), and octave_value::type_name().
Referenced by octave_cell::save_hdf5(), octave_class::save_hdf5(), octave::anonymous_fcn_handle::save_hdf5(), octave_struct::save_hdf5(), octave_scalar_struct::save_hdf5(), and save_hdf5_data().
|
static |
Definition at line 79 of file ls-hdf5.cc.
References error(), and max().
Referenced by hdf5_h5g_iterate(), and hdf5_read_next_data().
octave_hdf5_err hdf5_add_attr | ( | octave_hdf5_id | loc_id, |
const char * | attr_name | ||
) |
Definition at line 1139 of file ls-hdf5.cc.
References err_disabled_feature(), octave_H5P_DEFAULT, and retval.
Referenced by add_hdf5_data(), and save_hdf5_empty().
octave_hdf5_err hdf5_add_scalar_attr | ( | octave_hdf5_id | loc_id, |
octave_hdf5_id | type_id, | ||
const char * | attr_name, | ||
void * | buf | ||
) |
Definition at line 1180 of file ls-hdf5.cc.
References err_disabled_feature(), octave_H5P_DEFAULT, and retval.
Referenced by octave_range::save_hdf5().
bool hdf5_check_attr | ( | octave_hdf5_id | loc_id, |
const char * | attr_name | ||
) |
Definition at line 296 of file ls-hdf5.cc.
References err_disabled_feature(), octave_H5E_DEFAULT, and retval.
Referenced by hdf5_read_next_data_internal(), and load_hdf5_empty().
bool hdf5_get_scalar_attr | ( | octave_hdf5_id | loc_id, |
octave_hdf5_id | type_id, | ||
const char * | attr_name, | ||
void * | buf | ||
) |
Definition at line 343 of file ls-hdf5.cc.
References err_disabled_feature(), octave_H5E_DEFAULT, and retval.
Referenced by octave_range::load_hdf5().
octave_hdf5_err hdf5_h5g_iterate | ( | octave_hdf5_id | loc_id, |
const char * | name, | ||
int * | idx, | ||
void * | operator_data | ||
) |
Definition at line 1034 of file ls-hdf5.cc.
References check_hdf5_id_value(), err_disabled_feature(), hdf5_read_next_data_internal(), and name.
Referenced by octave::anonymous_fcn_handle::load_hdf5(), octave_cell::load_hdf5(), octave_class::load_hdf5(), octave_struct::load_hdf5(), and octave_scalar_struct::load_hdf5().
octave_hdf5_id hdf5_make_complex_type | ( | octave_hdf5_id | num_type | ) |
Definition at line 401 of file ls-hdf5.cc.
References err_disabled_feature().
Referenced by hdf5_read_next_data_internal(), octave_complex::load_hdf5(), octave_complex_matrix::load_hdf5(), octave_sparse_complex_matrix::load_hdf5(), octave_float_complex::load_hdf5(), octave_float_complex_matrix::load_hdf5(), octave_complex::save_hdf5(), octave_complex_matrix::save_hdf5(), octave_sparse_complex_matrix::save_hdf5(), octave_float_complex::save_hdf5(), and octave_float_complex_matrix::save_hdf5().
|
static |
Definition at line 426 of file ls-hdf5.cc.
Referenced by hdf5_read_next_data_internal().
octave_hdf5_err hdf5_read_next_data | ( | octave_hdf5_id | group_id, |
const char * | name, | ||
void * | dv | ||
) |
Definition at line 1020 of file ls-hdf5.cc.
References check_hdf5_id_value(), err_disabled_feature(), hdf5_read_next_data_internal(), and name.
|
static |
Definition at line 654 of file ls-hdf5.cc.
References octave::__get_type_info__(), d, hdf5_check_attr(), hdf5_make_complex_type(), hdf5_make_range_type(), hdf5_types_compatible(), load_inline_fcn(), octave_value_typeinfo::lookup_type(), octave::type_info::lookup_type(), make_valid_identifier(), name, octave_H5P_DEFAULT, octave_H5S_ALL, OCTAVE_LOCAL_BUFFER, retval, octave::valid_identifier(), and warning().
Referenced by hdf5_h5g_iterate(), hdf5_read_next_data(), and read_hdf5_data().
bool hdf5_types_compatible | ( | octave_hdf5_id | t1, |
octave_hdf5_id | t2 | ||
) |
Definition at line 265 of file ls-hdf5.cc.
References err_disabled_feature(), and n.
Referenced by hdf5_read_next_data_internal(), octave_complex::load_hdf5(), octave_complex_matrix::load_hdf5(), octave_sparse_complex_matrix::load_hdf5(), octave_float_complex::load_hdf5(), octave_float_complex_matrix::load_hdf5(), and octave_range::load_hdf5().
int load_hdf5_empty | ( | octave_hdf5_id | loc_id, |
const char * | name, | ||
dim_vector & | d | ||
) |
Definition at line 1280 of file ls-hdf5.cc.
References d, err_disabled_feature(), H5T_NATIVE_IDX, hdf5_check_attr(), name, octave_H5P_DEFAULT, octave_H5S_ALL, OCTAVE_LOCAL_BUFFER, and retval.
Referenced by octave_bool_matrix::load_hdf5(), octave_sparse_bool_matrix::load_hdf5(), octave_cell::load_hdf5(), octave_complex_matrix::load_hdf5(), octave_sparse_complex_matrix::load_hdf5(), octave_float_complex_matrix::load_hdf5(), octave_float_matrix::load_hdf5(), octave_matrix::load_hdf5(), octave_sparse_matrix::load_hdf5(), octave_char_matrix_str::load_hdf5(), and octave_base_int_matrix< T >::load_hdf5_internal().
|
static |
Definition at line 438 of file ls-hdf5.cc.
References octave::__get_interpreter__(), octave::interpreter::feval(), octave_value_list::length(), name, octave_H5P_DEFAULT, octave_H5S_ALL, OCTAVE_LOCAL_BUFFER, and retval.
Referenced by hdf5_read_next_data_internal().
|
static |
Definition at line 238 of file ls-hdf5.cc.
References retval.
Referenced by hdf5_read_next_data_internal().
std::string read_hdf5_data | ( | std::istream & | is, |
const std::string & | filename, | ||
bool & | global, | ||
octave_value & | tc, | ||
std::string & | doc, | ||
const string_vector & | argv, | ||
int | argv_idx, | ||
int | argc | ||
) |
Definition at line 1054 of file ls-hdf5.cc.
References check_hdf5_types(), Array< T >::clear(), hdf5_fstreambase::current_item, d, err_disabled_feature(), hdf5_fstreambase::file_id, hdf5_read_next_data_internal(), len, glob_match::match(), octave_H5P_DEFAULT, and retval.
Referenced by octave::load_save_system::load_vars().
bool save_hdf5_data | ( | std::ostream & | os, |
const octave_value & | tc, | ||
const std::string & | name, | ||
const std::string & | doc, | ||
bool | mark_global, | ||
bool | save_as_floats | ||
) |
Definition at line 1475 of file ls-hdf5.cc.
References add_hdf5_data(), check_hdf5_types(), err_disabled_feature(), hdf5_fstreambase::file_id, and name.
Referenced by octave::load_save_system::do_save().
int save_hdf5_empty | ( | octave_hdf5_id | loc_id, |
const char * | name, | ||
const dim_vector & | d | ||
) |
Definition at line 1224 of file ls-hdf5.cc.
References d, err_disabled_feature(), H5T_NATIVE_IDX, hdf5_add_attr(), name, octave_H5P_DEFAULT, octave_H5S_ALL, OCTAVE_LOCAL_BUFFER, and retval.
Referenced by octave_bool_matrix::save_hdf5(), octave_sparse_bool_matrix::save_hdf5(), octave_cell::save_hdf5(), octave_complex_matrix::save_hdf5(), octave_sparse_complex_matrix::save_hdf5(), octave_float_complex_matrix::save_hdf5(), octave_float_matrix::save_hdf5(), octave_matrix::save_hdf5(), octave_sparse_matrix::save_hdf5(), octave_char_matrix_str::save_hdf5(), and octave_base_int_matrix< T >::save_hdf5_internal().
octave_hdf5_id save_type_to_hdf5 | ( | save_type | st | ) |
Definition at line 1324 of file ls-hdf5.cc.
References err_disabled_feature(), LS_CHAR, LS_DOUBLE, LS_FLOAT, LS_INT, LS_SHORT, LS_U_CHAR, LS_U_INT, and LS_U_SHORT.
Referenced by octave_complex_matrix::save_hdf5(), octave_sparse_complex_matrix::save_hdf5(), octave_float_complex_matrix::save_hdf5(), octave_float_matrix::save_hdf5(), octave_matrix::save_hdf5(), and octave_sparse_matrix::save_hdf5().