#include <stdlib.h>
#include <string.h>
#include <H5Tpublic.h>
#include <H5Gpublic.h>
#include <H5Dpublic.h>
#include <H5Spublic.h>
#include <H5Apublic.h>
#include <H5Ppublic.h>
#include "status.h"
#include "file-handle.h"
#include "mhdf.h"
#include "util.h"
#include "names-and-paths.h"
Go to the source code of this file.
Functions | |
hid_t | mhdf_getNativeType (hid_t input_type, int size, mhdf_Status *status) |
Make type native-endian. More... | |
static hid_t | get_tag (mhdf_FileHandle file_handle, const char *tag_name, hid_t *id_type, mhdf_Status *status) |
static hid_t | get_tag_type (FileHandle *file_ptr, const char *tag_path, mhdf_Status *status) |
static int | store_tag_val_in_attrib (hid_t tag_id, const char *attrib_name, hid_t type_id, const void *value, hsize_t value_size, mhdf_Status *status) |
static hid_t | create_tag_common (mhdf_FileHandle file_handle, const char *tag_name, enum mhdf_TagDataType tag_type, int size, int storage, const void *default_value, int default_value_size_in, const void *global_value, int global_value_size_in, hid_t hdf_type, hid_t hdf_base_type, mhdf_Status *status) |
hid_t | mhdf_getTagDataType (mhdf_FileHandle file_handle, const char *tag_name, mhdf_Status *status) |
Get handle to HDF5 type object for tag data. More... | |
void | mhdf_createTag (mhdf_FileHandle file_handle, const char *tag_name, enum mhdf_TagDataType tag_type, int size, int storage, const void *default_value, const void *global_value, hid_t hdf_type, hid_t hdf_base_type, mhdf_Status *status) |
Add a tag to the file. More... | |
void | mhdf_createVarLenTag (mhdf_FileHandle file_handle, const char *tag_name, enum mhdf_TagDataType tag_type, int storage, const void *default_value, int default_value_length, const void *global_value, int global_value_length, hid_t hdf_type, hid_t hdf_base_type, mhdf_Status *status) |
Add variable-length tag to file. More... | |
int | mhdf_getNumberTags (mhdf_FileHandle file_handle, mhdf_Status *status) |
Get the number of tags in the file. More... | |
char ** | mhdf_getTagNames (mhdf_FileHandle file_handle, int *num_names_out, mhdf_Status *status) |
Get the name for each tag defined in the file. More... | |
static int | get_attrib_array_length_handle (hid_t attrib_id) |
static int | get_attrib_array_length_name (hid_t file, const char *path) |
void | mhdf_getTagInfo (mhdf_FileHandle file_handle, const char *tag_name, enum mhdf_TagDataType *class_out, int *size_out, int *tstt_storage_out, int *have_default_out, int *have_global_out, int *have_sparse_out, mhdf_Status *status) |
Get the description of a specified tag. More... | |
static int | read_tag_attrib_data (hid_t tag_id, const char *attrib_name, hid_t type_id, void *data, int is_var_len, mhdf_Status *status) |
void | mhdf_getTagValues (mhdf_FileHandle file_handle, const char *tag_name, hid_t output_data_type, void *default_value, void *global_value, mhdf_Status *status) |
Get the default and global values of the tag. More... | |
int | mhdf_haveDenseTag (mhdf_FileHandle file_handle, const char *tag_name, const char *type_handle, mhdf_Status *status) |
Check if the file contains dense tag data for the specified tag and element group. More... | |
hid_t | mhdf_createDenseTagData (mhdf_FileHandle file_handle, const char *tag_name, const char *type_handle, long num_values, mhdf_Status *status) |
Create an object to hold dense tag values for a given element group. More... | |
hid_t | mhdf_openDenseTagData (mhdf_FileHandle file_handle, const char *tag_name, const char *type_handle, long *num_values_out, mhdf_Status *status) |
Open the object containing dense tag values for a given element group. More... | |
void | mhdf_createSparseTagData (mhdf_FileHandle file_handle, const char *tag_name, long num_values, hid_t handles_out[2], mhdf_Status *status) |
Create file objects to store sparse tag data. More... | |
void | mhdf_createVarLenTagData (mhdf_FileHandle file_handle, const char *tag_name, long num_entities, long num_values, hid_t handles_out[3], mhdf_Status *status) |
Create file objects to store (sparse) variable-length tag data. More... | |
void | mhdf_openSparseTagData (mhdf_FileHandle file_handle, const char *tag_name, long *num_entity_out, long *num_values_out, hid_t handles_out[3], mhdf_Status *status) |
Create file objects to read sparse tag data. More... | |
void | mhdf_writeSparseTagEntities (hid_t table_id, long offset, long count, hid_t int_type, const void *id_list, mhdf_Status *status) |
Write Global ID list for sparse tag data. More... | |
void | mhdf_writeSparseTagEntitiesWithOpt (hid_t table_id, long offset, long count, hid_t int_type, const void *id_list, hid_t io_prop, mhdf_Status *status) |
void | mhdf_writeTagValues (hid_t table_id, long offset, long count, hid_t tag_type, const void *tag_data, mhdf_Status *status) |
Write tag values. More... | |
void | mhdf_writeTagValuesWithOpt (hid_t table_id, long offset, long count, hid_t tag_type, const void *tag_data, hid_t io_prop, mhdf_Status *status) |
void | mhdf_writeSparseTagIndices (hid_t table_id, long offset, long count, hid_t int_type, const void *indices, mhdf_Status *status) |
Write sparse tag end indices for variable-length tag data. More... | |
void | mhdf_writeSparseTagIndicesWithOpt (hid_t table_id, long offset, long count, hid_t int_type, const void *indices, hid_t io_prop, mhdf_Status *status) |
void | mhdf_readSparseTagEntities (hid_t table_id, long offset, long count, hid_t int_type, void *id_list, mhdf_Status *status) |
Read Global ID list for sparse tag data. More... | |
void | mhdf_readSparseTagEntitiesWithOpt (hid_t table_id, long offset, long count, hid_t int_type, void *id_list, hid_t io_prop, mhdf_Status *status) |
void | mhdf_readTagValues (hid_t table_id, long offset, long count, hid_t tag_type, void *tag_data, mhdf_Status *status) |
Read tag values. More... | |
void | mhdf_readTagValuesWithOpt (hid_t table_id, long offset, long count, hid_t tag_type, void *tag_data, hid_t io_prop, mhdf_Status *status) |
void | mhdf_readSparseTagIndices (hid_t table_id, long offset, long count, hid_t int_type, void *indices, mhdf_Status *status) |
Read sparse tag end indices for variable-length tag data. More... | |
void | mhdf_readSparseTagIndicesWithOpt (hid_t table_id, long offset, long count, hid_t int_type, void *indices, hid_t io_prop, mhdf_Status *status) |
|
static |
Definition at line 235 of file tags.c.
References struct_FileHandle::hdf_handle, mhdf_BITFIELD, mhdf_BOOLEAN, mhdf_check_valid_file(), mhdf_create_scalar_attrib(), mhdf_ENTITY_ID, mhdf_FLOAT, mhdf_INTEGER, mhdf_name_to_path_copy(), mhdf_OPAQUE, mhdf_setFail(), mhdf_setOkay(), size, store_tag_val_in_attrib(), TAG_DEFAULT_ATTRIB, TAG_GLOBAL_ATTRIB, TAG_GROUP, TAG_HANDLE_TYPE_ATTRIB, TAG_TYPE_ATTRIB, and TAG_TYPE_NAME.
Referenced by mhdf_createTag(), and mhdf_createVarLenTag().
|
static |
|
static |
Definition at line 793 of file tags.c.
References get_attrib_array_length_handle().
Referenced by mhdf_getTagInfo(), and read_tag_attrib_data().
|
static |
Definition at line 106 of file tags.c.
References struct_FileHandle::hdf_handle, struct_FileHandle::id_type, mhdf_check_valid_file(), mhdf_name_to_path_copy(), mhdf_setFail(), mhdf_setOkay(), and TAG_GROUP.
Referenced by mhdf_createSparseTagData(), mhdf_createVarLenTagData(), mhdf_getTagInfo(), mhdf_getTagValues(), and mhdf_openSparseTagData().
|
static |
Definition at line 149 of file tags.c.
References struct_FileHandle::hdf_handle, mhdf_setFail(), TAG_GROUP, and TAG_TYPE_NAME.
Referenced by mhdf_createDenseTagData(), and mhdf_getTagDataType().
hid_t mhdf_createDenseTagData | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
const char * | elem_group, | ||
long | num_values, | ||
mhdf_Status * | status | ||
) |
Create an object to hold dense tag values for a given element group.
file_handle | The file. |
tag_name | The tag. |
elem_group | The element group handle, or the return value of mhdf_node_type_handle or mhdf_set_type_handle for nodes or sets respectively. |
num_values | The number of tag values to be written. Must be The same as the number of elements in the group. Specified here to allow tag values to be written before node coordinates, element connectivity or meshsets. |
status | Passed back status of API call. |
Definition at line 1268 of file tags.c.
References API_BEGIN, API_END_H, DENSE_TAG_SUBGROUP, get_tag_type(), struct_FileHandle::hdf_handle, mhdf_check_valid_file(), mhdf_create_table(), mhdf_elem_group_from_handle(), mhdf_malloc(), mhdf_name_to_path(), mhdf_node_type_handle(), mhdf_set_type_handle(), mhdf_setFail(), mhdf_setOkay(), NODE_GROUP, SET_GROUP, and size.
Referenced by moab::WriteHDF5::create_tag().
void mhdf_createSparseTagData | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
long | num_values, | ||
hid_t | entities_and_values_out[2], | ||
mhdf_Status * | status | ||
) |
Create file objects to store sparse tag data.
Create the file objects to store all sparse data for a given tag in. The sparse data is stored in a pair of objects. The first is a vector of global IDs. The second is a vector of tag values for each entity specified in the list of global IDs.
file_handle | The file. |
tag_name | The tag. |
num_values | The number of tag values to be written. |
entities_and_values_out | The handles to the file objects. The first is the vector of global IDs. The second is the list of corresponding tag values. |
status | Passed back status of API call. |
Definition at line 1402 of file tags.c.
References API_BEGIN, API_END_H, get_tag(), mhdf_create_table(), mhdf_setFail(), mhdf_setOkay(), SPARSE_ENTITY_NAME, SPARSE_VALUES_NAME, and TAG_TYPE_NAME.
Referenced by moab::WriteHDF5::create_tag().
void mhdf_createTag | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
enum mhdf_TagDataType | tag_type, | ||
int | size, | ||
int | storage, | ||
const void * | default_value, | ||
const void * | global_value, | ||
hid_t | hdf_type, | ||
hid_t | mhdf_base_type, | ||
mhdf_Status * | status | ||
) |
Add a tag to the file.
Add a new tag to the file. This function must be called to define the tag characteristics before values for the tag can be written.
file_handle | The file |
tag_name | The tag name |
tag_type | The tag type. |
size | If tag_type == mhdf_BITFIELD, the number of bits. If tag_type == mhdf_OPAQUE, the size of the opaque type in bytes. Otherwise the length of the array of tag_type entities associated with each mesh entity, or 1 for a scalar value. |
storage | MOAB storage type (dense, sparse, etc.) |
default_value | Default value for tag, or NULL if none. |
global_value | Global value for tag, or NULL if none. |
hdf_type | If non-zero, assumed to be a user-specified type for opaque data. Ignored if tag_type is not mhdf_OPAQUE. |
hdf_base_type | Ignored if hdf_type is non-zero. If hdf_type is zero and this type is non-zero, it is used either as the type or as the base type for an array type for default_value and global_value, respectively. Typically used to specify the input data type for mhdf_ENTITY_ID tags. |
Definition at line 570 of file tags.c.
References API_BEGIN, API_END, create_tag_common(), and size.
Referenced by moab::WriteHDF5::create_tag().
void mhdf_createVarLenTag | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
enum mhdf_TagDataType | tag_type, | ||
int | storage, | ||
const void * | default_value, | ||
int | default_value_length, | ||
const void * | global_value, | ||
int | global_value_length, | ||
hid_t | hdf_type, | ||
hid_t | hdf_base_type, | ||
mhdf_Status * | status | ||
) |
Add variable-length tag to file.
Add a new tag to the file. This function must be called to define the tag characteristics before values for the tag can be written. Use this function if the tag values are not fixed-length.
file_handle | The file |
tag_name | The tag name |
tag_type | The tag type. |
storage | MOAB storage type (dense, sparse, etc.) |
default_value | Default value for tag, or NULL if none. |
default_value_length | Length of default value. |
global_value | Global value for tag, or NULL if none. |
global_value_length | Length of global value. |
hdf_type | If non-zero, assumed to be a user-specified type for opaque data. Ignored if tag_type is not mhdf_OPAQUE. |
hdf_base_type | Ignored if hdf_type is non-zero. If hdf_type is zero and this type is non-zero, it is used either as the type or as the base type for an array type for default_value and global_value, respectively. Typically used to specify the input data type for mhdf_ENTITY_ID tags. |
Definition at line 589 of file tags.c.
References API_BEGIN, API_END, create_tag_common(), mhdf_create_scalar_attrib(), and TAG_VARLEN_ATTRIB.
Referenced by moab::WriteHDF5::create_tag().
void mhdf_createVarLenTagData | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
long | num_entities, | ||
long | num_values, | ||
hid_t | entities_and_values_out[3], | ||
mhdf_Status * | status | ||
) |
Create file objects to store (sparse) variable-length tag data.
Create the file objects to store all sparse data for a given tag in. The sparse data is stored in a pair of objects. The first is a vector of global IDs. The second is a vector of tag values for each entity specified in the list of global IDs.
file_handle | The file. |
tag_name | The tag. |
num_entities | The number of entities for which tag values are to be stored |
num_values | The total number of scalar values to be written (the total number of bytes of data for all tags for opaque data.) |
entities_and_values_out | The handles to the file objects. The first is the vector of global IDs. The second is the list of corresponding tag values. The third is the handle to the index table. |
status | Passed back status of API call. |
Definition at line 1450 of file tags.c.
References API_BEGIN, API_END_H, get_tag(), mhdf_create_table(), MHDF_INDEX_TYPE, mhdf_setFail(), mhdf_setOkay(), SPARSE_ENTITY_NAME, SPARSE_VALUES_NAME, TAG_TYPE_NAME, and TAG_VAR_INDICES.
Referenced by moab::WriteHDF5::create_tag().
hid_t mhdf_getNativeType | ( | hid_t | input_type, |
int | size, | ||
mhdf_Status * | status | ||
) |
Make type native-endian.
MOAB, a Mesh-Oriented datABase, is a software component for creating, storing and accessing finite element mesh data.
Copyright 2004 Sandia Corporation. Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains certain rights in this software.
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
Definition at line 30 of file tags.c.
References mhdf_getNativeType(), mhdf_setFail(), mhdf_setOkay(), and size.
Referenced by mhdf_getNativeType().
int mhdf_getNumberTags | ( | mhdf_FileHandle | file_handle, |
mhdf_Status * | status | ||
) |
Get the number of tags in the file.
file_handle | The file. |
status | Passed back status of API call. |
Definition at line 615 of file tags.c.
References API_BEGIN, API_END, struct_FileHandle::hdf_handle, mhdf_check_valid_file(), mhdf_setFail(), mhdf_setOkay(), and TAG_GROUP.
hid_t mhdf_getTagDataType | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
mhdf_Status * | status | ||
) |
Get handle to HDF5 type object for tag data.
Definition at line 537 of file tags.c.
References API_BEGIN, API_END, get_tag_type(), mhdf_check_valid_file(), mhdf_name_to_path_copy(), and mhdf_setFail().
void mhdf_getTagInfo | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
enum mhdf_TagDataType * | class_out, | ||
int * | size_out, | ||
int * | tstt_storage_out, | ||
int * | have_default_out, | ||
int * | have_global_out, | ||
int * | have_sparse_out, | ||
mhdf_Status * | status | ||
) |
Get the description of a specified tag.
Get everything about a tag except the actual values.
file_handle | The file. |
tag_name | The name of the tag to retrieve the data for. |
class_out | The TSTT class of the tag data. |
size_out | Depends on value of class_out:
|
tstt_storage_out | The value of the TSTT enum for storage (dense, sparse, etc.) |
have_default_out | Non-zero if file contains a default value for the tag. Length of default value if variable-lenth tag. |
have_global_out | Non-zero if the file contains a global/mesh value for the tag. |
have_sparse_out | Non-zero if the file contains a sparse data table for this tag. |
Definition at line 806 of file tags.c.
References API_BEGIN, API_END, get_attrib_array_length_name(), get_tag(), mhdf_BITFIELD, mhdf_BOOLEAN, mhdf_ENTITY_ID, mhdf_find_attribute(), mhdf_FLOAT, mhdf_INTEGER, mhdf_is_in_group(), mhdf_OPAQUE, mhdf_read_scalar_attrib(), mhdf_setFail(), mhdf_setOkay(), size, SPARSE_ENTITY_NAME, TAG_DEFAULT_ATTRIB, TAG_GLOBAL_ATTRIB, TAG_HANDLE_TYPE_ATTRIB, TAG_TYPE_ATTRIB, TAG_TYPE_NAME, and TAG_VARLEN_ATTRIB.
Referenced by get_tag_desc(), and main().
char** mhdf_getTagNames | ( | mhdf_FileHandle | file_handle, |
int * | num_names_out, | ||
mhdf_Status * | status | ||
) |
Get the name for each tag defined in the file.
file_handle | The file. |
num_names_out | The length of the returned array of strings. |
status | Passed back status of API call. |
malloc
. The caller should release this memory by calling free
for each string and the array. Definition at line 655 of file tags.c.
References API_BEGIN, API_END, struct_FileHandle::hdf_handle, mhdf_check_valid_file(), mhdf_malloc(), mhdf_path_to_name(), mhdf_setFail(), mhdf_setOkay(), size, and TAG_GROUP.
Referenced by mhdf_getFileSummary().
void mhdf_getTagValues | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
hid_t | output_data_type, | ||
void * | default_value, | ||
void * | global_value, | ||
mhdf_Status * | status | ||
) |
Get the default and global values of the tag.
file_handle | The file. |
tag_name | The tag name. |
output_data_type | The HDF5 type for the memory into which the tag data is to be written. If zero, then the value(s) will be read as opaque data. |
default_value | Memory location at which to write the default value of the tag. |
global_value | If the tag has a global value, the memory location at which to write that value. |
status | Passed back status of API call. |
Definition at line 1135 of file tags.c.
References API_BEGIN, API_END, get_tag(), mhdf_find_attribute(), mhdf_setFail(), mhdf_setOkay(), read_tag_attrib_data(), TAG_DEFAULT_ATTRIB, TAG_GLOBAL_ATTRIB, and TAG_VARLEN_ATTRIB.
Referenced by moab::ReadHDF5::create_tag(), and get_tag_desc().
int mhdf_haveDenseTag | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
const char * | elem_group, | ||
mhdf_Status * | status | ||
) |
Check if the file contains dense tag data for the specified tag and element group.
Check if there is dense tag data for a given element type for the specified tag.
file_handle | The file. |
tag_name | The tag. |
elem_group | The element group handle, or the return value of mhdf_node_type_handle or mhdf_set_type_handle for nodes or sets respectively. |
status | Passed back status of API call. |
Definition at line 1188 of file tags.c.
References API_BEGIN, API_END, DENSE_TAG_SUBGROUP, struct_FileHandle::hdf_handle, mhdf_check_valid_file(), mhdf_elem_group_from_handle(), mhdf_is_in_group(), mhdf_name_to_path_copy(), mhdf_node_type_handle(), mhdf_set_type_handle(), mhdf_setFail(), mhdf_setOkay(), NODE_GROUP, SET_GROUP, and TAG_GROUP_NAME.
Referenced by main(), and mhdf_getFileSummary().
hid_t mhdf_openDenseTagData | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
const char * | elem_group, | ||
long * | num_values_out, | ||
mhdf_Status * | status | ||
) |
Open the object containing dense tag values for a given element group.
file_handle | The file. |
tag_name | The tag. |
elem_group | The element group handle, or the return value of mhdf_node_type_handle or mhdf_set_type_handle for nodes or sets respectively. |
num_values_out | The number of tag values to be written. Must be The same as the number of elements in the group. |
status | Passed back status of API call. |
Definition at line 1339 of file tags.c.
References API_BEGIN, API_END_H, DENSE_TAG_SUBGROUP, struct_FileHandle::hdf_handle, mhdf_check_valid_file(), mhdf_elem_group_from_handle(), mhdf_malloc(), mhdf_name_to_path(), mhdf_node_type_handle(), mhdf_open_table(), mhdf_set_type_handle(), mhdf_setFail(), mhdf_setOkay(), NODE_GROUP, SET_GROUP, and size.
Referenced by check_valid_tag(), main(), mhdf_getFileSummary(), moab::ReadHDF5::read_tag(), moab::ReadHDF5::read_tag_values_all(), moab::ReadHDF5::read_tag_values_partial(), moab::ReadHDF5::search_tag_values(), and moab::WriteHDF5::write_dense_tag().
void mhdf_openSparseTagData | ( | mhdf_FileHandle | file_handle, |
const char * | tag_name, | ||
long * | num_entity_out, | ||
long * | num_values_out, | ||
hid_t | entities_and_values_out[3], | ||
mhdf_Status * | status | ||
) |
Create file objects to read sparse tag data.
Open the file objects containing all sparse data for a given tag in. The sparse data is stored in a pair of objects. The first is a vector of global IDs. The second is a vector of tag values for each entity specified in the list of global IDs. For variable-length tags, a third table containing end offsets for each tag value is returned in the third position of the output hid_t array (see mhdf_readSparseTagIndices.)
file_handle | The file. |
tag_name | The tag. |
num_entity_out | The number of entities for which there are tag values. |
num_values_out | The number of data values. For fixed-length tags, this is the same as num_entity_out. For variable-length tags, it is the total number of values in the data table. |
entities_and_values_out | The handles to the pair of file objects. The first is the vector of global IDs. The second is the list of corresponding tag values. The third is the handle to the index table, iff the tag is variable-length. If the tag is fixed-length, this value is not set. |
status | Passed back status of API call. |
Definition at line 1511 of file tags.c.
References API_BEGIN, API_END_H, get_tag(), mhdf_find_attribute(), mhdf_open_table(), mhdf_setFail(), mhdf_setOkay(), SPARSE_ENTITY_NAME, SPARSE_VALUES_NAME, TAG_VAR_INDICES, and TAG_VARLEN_ATTRIB.
Referenced by check_valid_tag(), check_valid_var_len_tag(), moab::ReadHDF5::get_tagged_entities(), main(), mhdf_getFileSummary(), moab::ReadHDF5::read_tag(), moab::ReadHDF5::read_tag_values_all(), moab::ReadHDF5::read_tag_values_partial(), moab::ReadHDF5::search_tag_values(), moab::WriteHDF5::write_sparse_tag(), and moab::WriteHDF5::write_var_len_tag().
void mhdf_readSparseTagEntities | ( | hid_t | id_handle, |
long | offset, | ||
long | count, | ||
hid_t | hdf_integer_type, | ||
void * | id_list, | ||
mhdf_Status * | status | ||
) |
Read Global ID list for sparse tag data.
id_handle | The first handle passed back from either mhdf_createSparseTagData or mhdf_openSparseTagData. |
offset | The offset at which to begin reading. |
count | The number of global IDs to read. |
hdf_integer_type | The type of the integer data in id_list . Typically H5T_NATIVE_INT or N5T_NATIVE_LONG as defined in H5Tpublic.h. The HDF class of this type object must be H5T_INTEGER |
id_list | The memory location at which to store the global IDs. |
status | Passed back status of API call. |
Definition at line 1660 of file tags.c.
References API_BEGIN, API_END, and mhdf_read_data().
Referenced by check_valid_tag(), check_valid_var_len_tag(), and main().
void mhdf_readSparseTagEntitiesWithOpt | ( | hid_t | table_id, |
long | offset, | ||
long | count, | ||
hid_t | int_type, | ||
void * | id_list, | ||
hid_t | io_prop, | ||
mhdf_Status * | status | ||
) |
Definition at line 1671 of file tags.c.
References API_BEGIN, API_END, and mhdf_read_data().
Referenced by moab::ReadHDF5::get_tagged_entities(), and moab::ReadHDF5::search_tag_values().
void mhdf_readSparseTagIndices | ( | hid_t | tag_handle, |
long | offset, | ||
long | count, | ||
hid_t | hdf_integer_type, | ||
void * | end_indices, | ||
mhdf_Status * | status | ||
) |
Read sparse tag end indices for variable-length tag data.
Read sparse tag end indices for variable-length tag data. Each value in the list is the last index (zero-based) into the tag data for the corresponding entity.
tag_handle | handle to the data object to read from. |
offset | The offset into the table at which to begin reading |
count | The number of values to read. |
hdf_integer_type | The type of the values pointed to by end_indices (must be an integer type). |
end_indices | Memory in which to store the data read from the table. |
status | Output: API result. |
Definition at line 1701 of file tags.c.
References API_BEGIN, API_END, and mhdf_read_data().
Referenced by check_valid_var_len_tag().
void mhdf_readSparseTagIndicesWithOpt | ( | hid_t | table_id, |
long | offset, | ||
long | count, | ||
hid_t | int_type, | ||
void * | indices, | ||
hid_t | io_prop, | ||
mhdf_Status * | status | ||
) |
void mhdf_readTagValues | ( | hid_t | value_handle, |
long | offset, | ||
long | count, | ||
hid_t | hdf_type, | ||
void * | memory, | ||
mhdf_Status * | status | ||
) |
Read tag values.
value_handle | The second handle passed back from either mhdf_createSparseTagData or mhdf_openSparseTagData; or the handle returned by mhdf_createDenseTagData or mhdf_openDenseTagData. |
offset | The offset at which to begin reading. |
count | The number of tag values to read. |
hdf_type | The type of the data in memory. If this is specified, it must be possible for the HDF library to convert between this type and the type the tag data is stored as. If zero, the values will be read as opaque data. |
memory | Memory location at which to store tag values. |
status | Passed back status of API call. |
Definition at line 1684 of file tags.c.
References mhdf_readTagValuesWithOpt().
Referenced by check_valid_tag(), check_valid_var_len_tag(), and mhdf_getFileSummary().
void mhdf_readTagValuesWithOpt | ( | hid_t | table_id, |
long | offset, | ||
long | count, | ||
hid_t | tag_type, | ||
void * | tag_data, | ||
hid_t | io_prop, | ||
mhdf_Status * | status | ||
) |
Definition at line 1688 of file tags.c.
References API_BEGIN, API_END, and mhdf_read_data().
Referenced by mhdf_readTagValues(), moab::ReadHDF5::read_tag_values_all(), and moab::ReadHDF5::search_tag_values().
void mhdf_writeSparseTagEntities | ( | hid_t | id_handle, |
long | offset, | ||
long | count, | ||
hid_t | hdf_integer_type, | ||
const void * | id_list, | ||
mhdf_Status * | status | ||
) |
Write Global ID list for sparse tag data.
id_handle | The first handle passed back from either mhdf_createSparseTagData or mhdf_openSparseTagData. |
offset | The offset at which to begin writing. |
count | The number of global IDs to write. |
hdf_integer_type | The type of the integer data in id_list . Typically H5T_NATIVE_INT or N5T_NATIVE_LONG as defined in H5Tpublic.h. The HDF class of this type object must be H5T_INTEGER |
id_list | The list of global IDs to write. |
status | Passed back status of API call. |
Definition at line 1589 of file tags.c.
References API_BEGIN, API_END, and mhdf_write_data().
void mhdf_writeSparseTagEntitiesWithOpt | ( | hid_t | table_id, |
long | offset, | ||
long | count, | ||
hid_t | int_type, | ||
const void * | id_list, | ||
hid_t | io_prop, | ||
mhdf_Status * | status | ||
) |
Definition at line 1600 of file tags.c.
References API_BEGIN, API_END, and mhdf_write_data().
Referenced by moab::WriteHDF5::write_sparse_ids().
void mhdf_writeSparseTagIndices | ( | hid_t | tag_handle, |
long | offset, | ||
long | count, | ||
hid_t | hdf_integer_type, | ||
const void * | end_indices, | ||
mhdf_Status * | status | ||
) |
Write sparse tag end indices for variable-length tag data.
Write sparse tag end indices for variable-length tag data. Each value in the list is the last index (zero-based) into the tag data for the corresponding entity.
tag_handle | handle to the data object to write to. |
offset | The offset into the table at which to begin writting |
count | The number of values to write. |
hdf_integer_type | The type of the values pointed to by end_indices (must be an integer type). |
end_indices | The values to store in the table. |
status | Output: API result. |
Definition at line 1636 of file tags.c.
References API_BEGIN, API_END, and mhdf_write_data().
void mhdf_writeSparseTagIndicesWithOpt | ( | hid_t | table_id, |
long | offset, | ||
long | count, | ||
hid_t | int_type, | ||
const void * | indices, | ||
hid_t | io_prop, | ||
mhdf_Status * | status | ||
) |
Definition at line 1647 of file tags.c.
References API_BEGIN, API_END, and mhdf_write_data().
Referenced by moab::WriteHDF5::write_var_len_indices().
void mhdf_writeTagValues | ( | hid_t | value_handle, |
long | offset, | ||
long | count, | ||
hid_t | hdf_tag_data_type, | ||
const void * | tag_data, | ||
mhdf_Status * | status | ||
) |
Write tag values.
value_handle | The second handle passed back from either mhdf_createSparseTagData or mhdf_openSparseTagData; or the handle returned by mhdf_createDenseTagData or mhdf_openDenseTagData. |
offset | The offset at which to begin writing. |
count | The number of tag values to write. |
hdf_tag_data_type | The type of the data in memory. It must be possible for the HDF library to convert between this type and the type the tag data is stored as. |
tag_data | The list of tag values to write. |
status | Passed back status of API call. |
Definition at line 1613 of file tags.c.
References mhdf_writeTagValuesWithOpt().
void mhdf_writeTagValuesWithOpt | ( | hid_t | table_id, |
long | offset, | ||
long | count, | ||
hid_t | tag_type, | ||
const void * | tag_data, | ||
hid_t | io_prop, | ||
mhdf_Status * | status | ||
) |
Definition at line 1623 of file tags.c.
References API_BEGIN, API_END, and mhdf_write_data().
Referenced by mhdf_writeTagValues(), moab::WriteHDF5::write_tag_values(), and moab::WriteHDF5::write_var_len_data().
|
static |
Definition at line 1075 of file tags.c.
References get_attrib_array_length_name(), mhdf_find_attribute(), mhdf_read_scalar_attrib(), and mhdf_setFail().
Referenced by mhdf_getTagValues().
|
static |
Helper function to write default and mesh values for tag
tag_id | The file object upon which to attach the attribute |
attrib_name | The name of the attribute object |
type_id | The data type of the attribute data |
value | Pointer to attribute data |
value_size | Size of attribute data, as multiple of type indicated by type_id. Should be 1 except for variable-length tag data. |
Definition at line 199 of file tags.c.
References mhdf_create_scalar_attrib(), and mhdf_setFail().
Referenced by create_tag_common().