//-------------------------------------------------------------------------- // Function: CompType::getMemberArrayType ///\brief Returns the array datatype of the specified member in this /// compound datatype. ///\param member_num - IN: Zero-based index of the member ///\return ArrayType instance ///\exception H5::DataTypeIException // Programmer Binh-Minh Ribler - Jul, 2005 //-------------------------------------------------------------------------- ArrayType CompType::getMemberArrayType( unsigned member_num ) const { try { ArrayType arraytype(p_get_member_type(member_num)); return(arraytype); } catch (DataTypeIException E) { throw DataTypeIException("CompType::getMemberArrayType", E.getDetailMsg()); } }
//-------------------------------------------------------------------------- // Function: AbstractDs::getArrayType ///\brief Returns the array datatype of this abstract dataset which /// can be a dataset or an attribute. ///\return ArrayType instance ///\exception H5::DataTypeIException // Programmer Binh-Minh Ribler - Jul, 2005 //-------------------------------------------------------------------------- ArrayType AbstractDs::getArrayType() const { // Gets the id of the datatype used by this dataset or attribute using // p_get_type. p_get_type calls either H5Dget_type or H5Aget_type // depending on which object invokes getArrayType. Then, create and // return the ArrayType object try { ArrayType arraytype(p_get_type()); return(arraytype); } catch (DataSetIException E) { throw DataTypeIException("DataSet::getArrayType", E.getDetailMsg()); } catch (AttributeIException E) { throw DataTypeIException("Attribute::getArrayType", E.getDetailMsg()); } }