Пример #1
0
// Returns a new identifier for a previously-opened HDF5 file.
func (f *File) ReOpen() (*File, error) {
	hid := C.H5Freopen(f.id)
	if err := checkID(hid); err != nil {
		return nil, fmt.Errorf("error reopening hdf5 file: %s", err)
	}
	return newFile(hid), nil
}
Пример #2
0
// Returns a new identifier for a previously-opened HDF5 file.
func (self *File) ReOpen() (*File, error) {
	hid := C.H5Freopen(self.id)
	err := h5err(C.herr_t(int(hid)))
	if err != nil {
		return nil, err
	}
	return newFile(hid), nil
}
Пример #3
0
// Returns a new identifier for a previously-opened HDF5 file.
func (self *File) ReOpen() (f *File, err error) {
	f = nil
	err = nil

	hid := C.H5Freopen(self.id)
	err = togo_err(C.herr_t(int(hid)))
	if err != nil {
		return
	}
	f = new_file(hid)
	return
}