HDF5 C++ API Reference Manual

 

 

 

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

Generated on Tue Aug 14 13:56:59 2007 by  doxygen 1.3.9.1