HDF5 C++ API  1.8.18
 All Classes Namespaces Functions Variables Typedefs Friends Pages
H5FloatType.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 files COPYING and Copyright.html. COPYING can be found at the root *
10  * of the source code distribution tree; Copyright.html can be found at the *
11  * root level of an installed copy of the electronic HDF5 document set and *
12  * is linked from the top-level documents page. It can also be found at *
13  * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have *
14  * access to either file, you may request a copy from help@hdfgroup.org. *
15  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
16 
17 #ifndef __H5FloatType_H
18 #define __H5FloatType_H
19 
20 namespace H5 {
21 
23 class H5_DLLCPP FloatType : public AtomType {
24  public:
25  // Creates a floating-point type using a predefined type.
26  FloatType( const PredType& pred_type );
27 
28  // Gets the floating-point datatype of the specified dataset.
29  FloatType( const DataSet& dataset );
30 
31  // Retrieves the exponent bias of a floating-point type.
32  size_t getEbias() const;
33 
34  // Sets the exponent bias of a floating-point type.
35  void setEbias( size_t ebias ) const;
36 
37  // Retrieves floating point datatype bit field information.
38  void getFields( size_t& spos, size_t& epos, size_t& esize, size_t& mpos, size_t& msize ) const;
39 
40  // Sets locations and sizes of floating point bit fields.
41  void setFields( size_t spos, size_t epos, size_t esize, size_t mpos, size_t msize ) const;
42 
43  // Retrieves the internal padding type for unused bits in floating-point datatypes.
44  H5T_pad_t getInpad( H5std_string& pad_string ) const;
45 
46  // Fills unused internal floating point bits.
47  void setInpad( H5T_pad_t inpad ) const;
48 
49  // Retrieves mantissa normalization of a floating-point datatype.
50  H5T_norm_t getNorm( H5std_string& norm_string ) const;
51 
52  // Sets the mantissa normalization of a floating-point datatype.
53  void setNorm( H5T_norm_t norm ) const;
54 
56  virtual H5std_string fromClass () const { return("FloatType"); }
57 
58  // Default constructor
59  FloatType();
60 
61  // Creates a floating-point datatype using an existing id.
62  FloatType( const hid_t existing_id );
63 
64  // Copy constructor: makes a copy of the original FloatType object.
65  FloatType( const FloatType& original );
66 
67  // Noop destructor.
68  virtual ~FloatType();
69 };
70 }
71 #endif // __H5FloatType_H
Class PredType holds the definition of all the HDF5 predefined datatypes.
Definition: H5PredType.h:29
AtomType is a base class, inherited by IntType, FloatType, StrType, and PredType. ...
Definition: H5AtomType.h:29
Class DataSet operates on HDF5 datasets.
Definition: H5DataSet.h:29
virtual H5std_string fromClass() const
Returns this class name.
Definition: H5FloatType.h:56
Class FloatType operates on HDF5 floating point datatype.
Definition: H5FloatType.h:23


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