HDF5 C++ API Reference Manual

 

 

Main Page | Namespace List | Class Hierarchy | Compound List | File List | Compound Members | File Members | Examples

H5AbstractDs.h

Go to the documentation of this file.
00001 // C++ informative line for the emacs editor: -*- C++ -*-
00002 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
00003  * Copyright by the Board of Trustees of the University of Illinois.         *
00004  * All rights reserved.                                                      *
00005  *                                                                           *
00006  * This file is part of HDF5.  The full HDF5 copyright notice, including     *
00007  * terms governing use, modification, and redistribution, is contained in    *
00008  * the files COPYING and Copyright.html.  COPYING can be found at the root   *
00009  * of the source code distribution tree; Copyright.html can be found at the  *
00010  * root level of an installed copy of the electronic HDF5 document set and   *
00011  * is linked from the top-level documents page.  It can also be found at     *
00012  * http://hdf.ncsa.uiuc.edu/HDF5/doc/Copyright.html.  If you do not have     *
00013  * access to either file, you may request a copy from hdfhelp@ncsa.uiuc.edu. *
00014  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
00015 
00016 // Class AbstractDs is an abstract base class, from which Attribute and
00017 // DataSet inherit.  It provides the services that are common to both
00018 // Attribute and DataSet.  It also inherits from H5Object and passes down
00019 // the services that H5Object provides.
00020 
00021 #ifndef _AbstractDs_H
00022 #define _AbstractDs_H
00023 
00024 #ifndef H5_NO_NAMESPACE
00025 namespace H5 {
00026 #endif
00027 
00028 class ArrayType;
00029 class CompType;
00030 class EnumType;
00031 class FloatType;
00032 class IntType;
00033 class StrType;
00034 class VarLenType;
00035 class H5_DLLCPP AbstractDs : public H5Object {
00036    public:
00037         // Gets a copy the datatype of that this abstract dataset uses.
00038         // Note that this datatype is a generic one and can only be accessed
00039         // via generic member functions, i.e., member functions belong
00040         // to DataType.  To get specific datatype, i.e. EnumType, FloatType,
00041         // etc..., use the specific functions, that follow, instead.
00042         DataType getDataType() const;
00043 
00044         // Gets a copy of the specific datatype of this abstract dataset.
00045         ArrayType getArrayType() const;
00046         CompType getCompType() const;
00047         EnumType getEnumType() const;
00048         IntType getIntType() const;
00049         FloatType getFloatType() const;
00050         StrType getStrType() const;
00051         VarLenType getVarLenType() const;
00052 
00053         // Gets the dataspace of this abstract dataset - pure virtual.
00054         virtual DataSpace getSpace() const = 0;
00055 
00056         // Gets the class of the datatype that is used by this abstract
00057         // dataset.
00058         H5T_class_t getTypeClass() const;
00059 
00060         // Returns the amount of storage size required for this abstract
00061         // dataset - pure virtual.
00062         virtual hsize_t getStorageSize() const = 0;
00063 
00064         // Copy constructor
00065         AbstractDs( const AbstractDs& original );
00066 
00067         // Destructor
00068         virtual ~AbstractDs();
00069 
00070    protected:
00071         // Default constructor
00072         AbstractDs();
00073 
00074         // Constructor that takes an attribute id or a dataset id.
00075         AbstractDs( const hid_t ds_id );
00076 
00077    private:
00078         // This member function is implemented by DataSet and Attribute
00079         virtual hid_t p_get_type() const = 0;
00080 };
00081 #ifndef H5_NO_NAMESPACE
00082 }
00083 #endif
00084 #endif // _AbstractDs_H

Generated on Thu Apr 20 15:16:40 2006 by doxygen 1.3.2