My Project 1.10.8
H5AbstractDs.h
1// C++ informative line for the emacs editor: -*- C++ -*-
2/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
3 * Copyright by The HDF Group. *
4 * Copyright by the Board of Trustees of the University of Illinois. *
5 * All rights reserved. *
6 * *
7 * This file is part of HDF5. The full HDF5 copyright notice, including *
8 * terms governing use, modification, and redistribution, is contained in *
9 * the COPYING file, which can be found at the root of the source code *
10 * distribution tree, or in https://www.hdfgroup.org/licenses. *
11 * If you do not have access to either file, you may request a copy from *
12 * help@hdfgroup.org. *
13 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
14
15#ifndef H5AbstractDs_H
16#define H5AbstractDs_H
17
18namespace H5 {
19
20class ArrayType;
21class CompType;
22class EnumType;
23class FloatType;
24class IntType;
25class StrType;
26class VarLenType;
27class DataSpace;
28
36class H5_DLLCPP AbstractDs {
37 public:
38 // Gets a copy the datatype of that this abstract dataset uses.
39 // Note that this datatype is a generic one and can only be accessed
40 // via generic member functions, i.e., member functions belong
41 // to DataType. To get specific datatype, i.e. EnumType, FloatType,
42 // etc..., use the specific functions, that follow, instead.
43 DataType getDataType() const;
44
45 // Gets a copy of the specific datatype of this abstract dataset.
46 ArrayType getArrayType() const;
47 CompType getCompType() const;
48 EnumType getEnumType() const;
49 IntType getIntType() const;
50 FloatType getFloatType() const;
51 StrType getStrType() const;
52 VarLenType getVarLenType() const;
53
55 virtual size_t getInMemDataSize() const = 0;
56
58 virtual DataSpace getSpace() const = 0;
59
60 // Gets the class of the datatype that is used by this abstract
61 // dataset.
62 H5T_class_t getTypeClass() const;
63
65 virtual hsize_t getStorageSize() const = 0;
66
67 // Returns this class name - pure virtual.
68 virtual H5std_string fromClass() const = 0;
69
70 // Destructor
71 virtual ~AbstractDs();
72
73 protected:
74 // Default constructor
75 AbstractDs();
76
77 private:
78 // This member function is implemented by DataSet and Attribute - pure virtual.
79 virtual hid_t p_get_type() const = 0;
80
81}; // end of AbstractDs
82} // namespace H5
83
84#endif // H5AbstractDs_H
AbstractDs is an abstract base class, inherited by Attribute and DataSet.
Definition: H5AbstractDs.h:36
virtual H5std_string fromClass() const =0
virtual DataSpace getSpace() const =0
Gets the dataspace of this abstract dataset - pure virtual.
virtual size_t getInMemDataSize() const =0
Gets the size in memory of this abstract dataset.
virtual hsize_t getStorageSize() const =0
Returns the amount of storage size required - pure virtual.
Class ArrayType inherits from DataType and provides wrappers for the HDF5's Array Datatypes.
Definition: H5ArrayType.h:25
CompType is a derivative of a DataType and operates on HDF5 compound datatypes.
Definition: H5CompType.h:25
Class DataSpace inherits from IdComponent and provides wrappers for the HDF5's dataspaces.
Definition: H5DataSpace.h:25
Class DataType provides generic operations on HDF5 datatypes.
Definition: H5DataType.h:28
EnumType is a derivative of a DataType and operates on HDF5 enum datatypes.
Definition: H5EnumType.h:25
FloatType is a derivative of a DataType and operates on HDF5 floating point datatype.
Definition: H5FloatType.h:25
IntType is a derivative of a DataType and operates on HDF5 integer datatype.
Definition: H5IntType.h:25
StrType is a derivative of a DataType and operates on HDF5 string datatype.
Definition: H5StrType.h:25
VarLenType is a derivative of a DataType and operates on HDF5 Variable-length Datatypes.
Definition: H5VarLenType.h:25
Definition: H5AbstractDs.cpp:34


The HDF Group Help Desk:
  Copyright by The HDF Group
and the Board of Trustees of the University of Illinois