Please, help us to better serve our user community by answering the following short survey: https://www.hdfgroup.org/website-survey/
HDF5  1.14.4.3
API Reference
 
Loading...
Searching...
No Matches
Fortran High Level Table (H5TB) Interface

Detailed Description

See also
HDF5 Table APIs (H5TB), C-HL API
The HDF5 High Level Table, User Guide

Modules

module  h5tb
 This module contains Fortran interfaces for H5TB.
 

Functions/Subroutines

subroutine h5tbmake_table_f (table_title, loc_id, dset_name, nfields, nrecords, type_size, field_names, field_offset, field_types, chunk_size, compress, errcode)
 Creates (DOES NOT WRITE) a dataset named dset_name attached to the object specified by the identifier loc_id.
 
subroutine h5tbmake_table_f (table_title, loc_id, dset_name, nfields, nrecords, type_size, field_names, field_offset, field_types, chunk_size, fill_data, compress, data, errcode)
 Creates and writes a dataset named dset_name attached to the object specified by the identifier loc_id.
 
subroutine h5tbread_table_f (loc_id, dset_name, nfields, dst_size, dst_offset, dst_sizes, dst_buf, errcode)
 Reads a table.
 
subroutine h5tbwrite_field_name_f (loc_id, dset_name, field_name, start, nrecords, type_size, buf, errcode)
 Overwrites field.
 
subroutine h5tbread_field_name_f (loc_id, dset_name, field_name, start, nrecords, type_size, buf, errcode)
 Reads one or several fields. The fields are identified by name.
 
subroutine h5tbwrite_field_index_f (loc_id, dset_name, field_index, start, nrecords, type_size, buf, errcode)
 Overwrites a field.
 
subroutine h5tbread_field_index_f (loc_id, dset_name, field_index, start, nrecords, type_size, buf, errcode)
 Reads field. The fields are identified by index.
 
subroutine h5tbinsert_field_f (loc_id, dset_name, field_name, field_type, position, buf, errcode)
 Insert a new field into a table.
 
subroutine h5tbdelete_field_f (loc_id, dset_name, field_name, errcode)
 Deletes a field from a table.
 
subroutine h5tbget_table_info_f (loc_id, dset_name, nfields, nrecords, errcode)
 Gets the table dimensions.
 
subroutine h5tbget_field_info_f (loc_id, dset_name, nfields, field_names, field_sizes, field_offsets, type_size, errcode, maxlen_out)
 Gets information about a table.
 

Function/Subroutine Documentation

◆ h5tbdelete_field_f()

subroutine h5tbdelete_field_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
character(len=*), intent(in)  field_name,
integer  errcode 
)

Deletes a field from a table.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the table.
field_nameThe name of the field to delete.
errcodeReturns 0 if successful and -1 if it fails.

See C API: H5TBdelete_field()

◆ h5tbget_field_info_f()

subroutine h5tbget_field_info_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer(hsize_t), intent(in)  nfields,
character(len=*), dimension(nfields), intent(inout)  field_names,
integer(size_t), dimension(nfields), intent(inout)  field_sizes,
integer(size_t), dimension(nfields), intent(inout)  field_offsets,
integer(size_t), intent(inout)  type_size,
integer  errcode,
integer(size_t), optional  maxlen_out 
)

Gets information about a table.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to read.
nfieldsThe number of fields.
field_namesAn array containing the names of the fields.
field_sizesAn array containing the size of the fields.
field_offsetsAn array containing the offsets of the fields.
type_sizeThe size of the HDF5 datatype associated with the table (i.e., the size in bytes of the HDF5 compound datatype used to define a row, or record, in the table).
errcodeReturns 0 if successful and -1 if it fails.
maxlen_outMaximum character length of the field names.

See C API: H5TBget_field_info()

◆ h5tbget_table_info_f()

subroutine h5tbget_table_info_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer(hsize_t), intent(inout)  nfields,
integer(hsize_t), intent(inout)  nrecords,
integer  errcode 
)

Gets the table dimensions.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to read.
nfieldsThe number of fields.
nrecordsThe number of records.
errcodeReturns 0 if successful and -1 if it fails.

See C API: H5TBget_table_info()

◆ h5tbinsert_field_f()

subroutine h5tbinsert_field_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
character(len=*), intent(in)  field_name,
integer(hid_t), intent(in)  field_type,
integer, intent(in)  position,
type(type), dimension(*), intent(in)  buf,
integer  errcode 
)

Insert a new field into a table.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the table.
field_nameThe name of the field to insert.
field_typeThe data type of the field.
positionThe zero based index position where to insert the field.
bufBuffer with data.
errcodeReturns 0 if successful and -1 if it fails.

See C API: H5TBinsert_field()

◆ h5tbmake_table_f() [1/2]

subroutine h5tbmake_table_f ( character(len=*), intent(in)  table_title,
integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer(hsize_t), intent(in)  nfields,
integer(hsize_t), intent(in)  nrecords,
integer(size_t), intent(in)  type_size,
character(len=*), dimension(1:nfields), intent(in)  field_names,
integer(size_t), dimension(1:nfields), intent(in)  field_offset,
integer(hid_t), dimension(1:nfields), intent(in)  field_types,
integer(hsize_t), intent(in)  chunk_size,
integer, intent(in)  compress,
integer  errcode 
)

Creates (DOES NOT WRITE) a dataset named dset_name attached to the object specified by the identifier loc_id.

Attention
Obsolete API, use the Fortran 2003 version instead.
Parameters
table_titleThe title of the table.
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to create.
nfieldsThe number of fields.
nrecordsThe number of records.
type_sizeThe size in bytes of the structure associated with the table. Obtained with sizeof or storage_size.
field_namesAn array containing the names of the fields.
field_offsetAn array containing the offsets of the fields.
field_typesAn array containing the type of the fields.
chunk_sizeThe chunk size.
compressFlag that turns compression on or off.
errcodeReturns 0 if successful and -1 if it fails.

See C API: H5TBmake_table()

◆ h5tbmake_table_f() [2/2]

subroutine h5tbmake_table_f ( character(len=*), intent(in)  table_title,
integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer(hsize_t), intent(in)  nfields,
integer(hsize_t), intent(in)  nrecords,
integer(size_t), intent(in)  type_size,
character(len=*), dimension(1:nfields), intent(in)  field_names,
integer(size_t), dimension(1:nfields), intent(in)  field_offset,
integer(hid_t), dimension(1:nfields), intent(in)  field_types,
integer(hsize_t), intent(in)  chunk_size,
type(c_ptr), intent(in)  fill_data,
integer, intent(in)  compress,
type(c_ptr), intent(in)  data,
integer  errcode 
)

Creates and writes a dataset named dset_name attached to the object specified by the identifier loc_id.

Attention
The preferred API, Fortran 2003 version.
Parameters
table_titleThe title of the table
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to create
nfieldsThe number of fields
nrecordsThe number of records
type_sizeThe size in bytes of the structure associated with the table; This value is obtained with sizeof().
field_namesAn array containing the names of the fields
field_offsetAn array containing the offsets of the fields
field_typesAn array containing the type of the fields
chunk_sizeThe chunk size
fill_dataFill values data
compressFlag that turns compression on or off
dataBuffer with data to be written to the table
errcodeReturns 0 if successful and -1 if it fails.

See C API: H5TBmake_table()

◆ h5tbread_field_index_f()

subroutine h5tbread_field_index_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer, intent(in)  field_index,
integer(hsize_t), intent(in)  start,
integer(hsize_t), intent(in)  nrecords,
integer(size_t), intent(in)  type_size,
type(type), dimension(*), intent(inout)  buf,
integer  errcode 
)

Reads field. The fields are identified by index.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to read.
field_indexThe indexes of the fields to read.
startThe start record to read from.
nrecordsThe number of records to read.
type_sizeThe size in bytes of the structure associated with the table. Obtained with sizeof or storage_size.
bufBuffer with data.
errcodeReturns 0 if successful and -1 if it fails.

See similar C API: H5TBread_fields_index()

◆ h5tbread_field_name_f()

subroutine h5tbread_field_name_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
character(len=*), intent(in)  field_name,
integer(hsize_t), intent(in)  start,
integer(hsize_t), intent(in)  nrecords,
integer(size_t), intent(in)  type_size,
type(type), dimension(*), intent(inout)  buf,
integer  errcode 
)

Reads one or several fields. The fields are identified by name.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to read.
field_nameAn array containing the names of the fields to read.
startThe start record to read from.
nrecordsThe number of records to read.
type_sizeThe size in bytes of the structure associated with the table. Obtained with sizeof or storage_size.
bufBuffer with data
errcodeReturns 0 if successful and -1 if it fails.

See similar C API: H5TBread_fields_name()

◆ h5tbread_table_f()

subroutine h5tbread_table_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer(hsize_t), intent(in)  nfields,
integer(size_t), intent(in)  dst_size,
integer(size_t), dimension(1:nfields), intent(in)  dst_offset,
integer(size_t), dimension(1:nfields), intent(in)  dst_sizes,
type(c_ptr)  dst_buf,
integer  errcode 
)

Reads a table.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to read
nfieldsNumber of fields, i.e., size of dst_offset and dst_sizes arrays.
dst_sizeThe size of the structure type, as calculated by sizeof or storage_size
dst_offsetAn array containing the offsets of the fields. These offsets can be calculated with H5OFFSETOF.
dst_sizesAn array containing the sizes of the fields. These sizes can be calculated with sizeof or storage_size.
dst_bufPointer to buffer with data.
errcodeReturns 0 if successful and -1 if it fails.

See C API: H5TBread_table()

◆ h5tbwrite_field_index_f()

subroutine h5tbwrite_field_index_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
integer, intent(in)  field_index,
integer(hsize_t), intent(in)  start,
integer(hsize_t), intent(in)  nrecords,
integer(size_t), intent(in)  type_size,
integer, dimension(*), intent(in)  buf,
integer  errcode 
)

Overwrites a field.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to overwrite.
field_indexThe indexe of the fields to write.
startThe zero based index record to start writing.
nrecordsThe number of records to write.
type_sizeThe size of the structure type, as calculated by sizeof or storage_size.
bufBuffer with data.
errcodeReturns 0 if successful and -1 if it fails.

See similar C API: H5TBwrite_fields_index()

◆ h5tbwrite_field_name_f()

subroutine h5tbwrite_field_name_f ( integer(hid_t), intent(in)  loc_id,
character(len=*), intent(in)  dset_name,
character(len=*), intent(in)  field_name,
integer(hsize_t), intent(in)  start,
integer(hsize_t), intent(in)  nrecords,
integer(size_t), intent(in)  type_size,
type(type), dimension(*), intent(in)  buf,
integer  errcode 
)

Overwrites field.

Parameters
loc_idLocation identifier. The identifier may be that of a file or group.
dset_nameThe name of the dataset to overwrite
field_nameThe names of the fields to write
startThe zero index record to start writing
nrecordsThe number of records to write
type_sizeThe size of the structure type, as calculated by sizeof or storage_size.
bufBuffer with data.
errcodeReturns 0 if successful and -1 if it fails.

See similar C API: H5TBwrite_fields_name()