Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

HDF5Portable.H

Go to the documentation of this file.
00001 
00002 /* _______              __
00003   / ___/ /  ___  __ _  / /  ___
00004  / /__/ _ \/ _ \/  ' \/ _ \/ _ \
00005  \___/_//_/\___/_/_/_/_.__/\___/ 
00006 */
00007 //
00008 // This software is copyright (C) by the Lawrence Berkeley
00009 // National Laboratory.  Permission is granted to reproduce
00010 // this software for non-commercial purposes provided that
00011 // this notice is left intact.
00012 // 
00013 // It is acknowledged that the U.S. Government has rights to
00014 // this software under Contract DE-AC03-765F00098 between
00015 // the U.S.  Department of Energy and the University of
00016 // California.
00017 //
00018 // This software is provided as a professional and academic
00019 // contribution for joint exchange. Thus it is experimental,
00020 // is provided ``as is'', with no warranties of any kind
00021 // whatsoever, no support, no promise of updates, or printed
00022 // documentation. By using this software, you acknowledge
00023 // that the Lawrence Berkeley National Laboratory and
00024 // Regents of the University of California shall have no
00025 // liability with respect to the infringement of other
00026 // copyrights by any part of this software.
00027 //
00028 //  ANAG, LBNL
00029 
00030 
00031 #ifndef HDF5PORTABLE_H
00032 #define HDF5PORTABLE_H
00033 
00034 #include "Vector.H"
00035 #include <hdf5.h>
00036 #include "Box.H"
00037 #include "Interval.H"
00038 
00039 template <class T>
00040 void dataTypes(Vector<hid_t>& a_types, const T& a_dummySpecializationArg);
00041 
00042 template <class T>
00043 void dataSize(const T& item, Vector<int>& a_sizes, 
00044               const Box& box, const Interval& comps);
00045 
00046 template <class T>
00047 void write(const T& item, Vector<void*>& a_allocatedBuffers, 
00048            const Box& box, const Interval& comps);
00049 
00050 template <class T>
00051 void read(T& item, Vector<void*>& a_allocatedBuffers, const Box& box, 
00052           const Interval& comps);
00053 
00054 template <class T>
00055 const char* name(const T& a_dummySpecializationArg);
00056 
00057 // These are the default template declarations for the HDF5 I/O
00058 // tempalte functions needed by T objects for binary IO.  The default
00059 // implementations use the linearOut/linearIn/size functions of the
00060 // T tempalte classes to procide non-portable binary IO.
00061 //     A user can add their own template specializations for
00062 // portable binary IO abilities. 
00063 //
00064 //  To use this header, a user includes this file first, then
00065 //  decalres their template specializations, then includes the HDF5.H
00066 //  header file.
00067 // 
00068 //
00069 //
00070 //  http://hdf.ncsa.uiuc.edu/HDF5/
00071 //
00072 // available datatypes in HDF5 
00073 //
00074 //            Example
00075 //                                                  Corresponding C Type
00076 //            H5T_NATIVE_CHAR
00077 //                                                  char
00078 //            H5T_NATIVE_UCHAR
00079 //                                                  unsigned char
00080 //            H5T_NATIVE_SHORT
00081 //                                                  short
00082 //            H5T_NATIVE_USHORT
00083 //                                                  unsigned short
00084 //            H5T_NATIVE_INT
00085 //                                                  int
00086 //            H5T_NATIVE_UINT
00087 //                                                  unsigned
00088 //            H5T_NATIVE_LONG
00089 //                                                  long
00090 //            H5T_NATIVE_ULONG
00091 //                                                  unsigned long
00092 //            H5T_NATIVE_FLOAT
00093 //                                                  float
00094 //            H5T_NATIVE_DOUBLE
00095 //                                                  double
00096 //
00097 // and some special ones defined for Chombo:
00098 //
00099 //            H5T_NATIVE_REAL                       Real
00100 //
00101 //            box_id                                Box
00102 //
00103 //            intvext_id                            IntVect
00104 #endif

Generated on Tue Jul 2 10:42:20 2002 for Chombo by doxygen1.2.16