Back to index

salome-kernel  6.5.0
hdfi.h
Go to the documentation of this file.
00001 // Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
00004 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License.
00010 //
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 //
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019 //
00020 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00021 //
00022 
00023 /*----------------------------------------------------------------------
00024   SALOME HDFPersist : implementation of HDF persitent ( save/ restore )
00025   File   : hdfi.h
00026   Module : SALOME
00027   ----------------------------------------------------------------------*/
00028 
00029 #ifndef HDFI_H
00030 #define HDFI_H
00031 
00032 #include "HDFtypes.h"
00033 
00034 /* HDF C INTERFACE */
00035 
00036 #ifdef __cplusplus
00037 extern "C" {
00038 #endif
00039 /* File Interface */
00040 extern
00041 hdf_idt HDFfileCreate(char *name);
00042 
00043 extern
00044 hdf_err HDFfileClose(hdf_idt fid);
00045 
00046 extern
00047 hdf_idt HDFfileOpen(char *name,hdf_access_mode access_mode);
00048 
00049 extern
00050 hdf_err HDFfileMount(hdf_idt id,const char *name,hdf_idt fid);
00051 
00052 extern
00053 hdf_err HDFfileUmount(hdf_idt id,const char *name);
00054 
00055 /* Group Interface */
00056 extern
00057 hdf_idt HDFgroupCreate(hdf_idt pid, char *name);
00058 
00059 extern
00060 hdf_idt HDFgroupOpen(hdf_idt pid, char *name);
00061 
00062 extern 
00063 hdf_err HDFgroupClose(hdf_idt id);
00064 
00065 /* DataSet Interface */
00066 extern 
00067 hdf_idt HDFdatasetOpen(hdf_idt pid,char *name);
00068 
00069 extern
00070 hdf_err HDFdatasetClose(hdf_idt id);
00071 
00072 extern
00073 hdf_idt HDFdatasetCreate(hdf_idt pid,char *name, hdf_type type,
00074                          hdf_size *dimd, int ndim, hdf_byte_order order, hdf_idt arrayId);
00075 
00076 extern
00077 hdf_err HDFdatasetWrite(hdf_idt id, void *val);
00078 
00079 extern
00080 hdf_err HDFdatasetRead(hdf_idt id, void *val);
00081 
00082 extern
00083 hdf_type HDFdatasetGetType(hdf_idt id);
00084 
00085 extern
00086 hdf_type HDFarrayGetType(hdf_idt id);
00087 
00088 extern 
00089 hdf_idt HDFarrayGetTypeId(hdf_idt type_id);
00090 
00091 extern 
00092 hdf_err HDFarrayClose(hdf_idt id);
00093 
00094 extern 
00095 int HDFarrayGetnDim(hdf_idt id);
00096 
00097 extern 
00098 hdf_err HDFarrayGetDim(hdf_idt id, hdf_size dim[]);
00099 
00100 
00101 extern 
00102 hdf_idt HDFarrayCreate(hdf_type dataType,int ndim,hdf_size *dim);
00103 
00104 extern 
00105 int HDFdatasetGetnDim(hdf_idt id);
00106 
00107 extern 
00108 hdf_err HDFdatasetGetDim(hdf_idt id,hdf_size dim[]);
00109 
00110 extern
00111 int HDFdatasetGetSize(hdf_idt id);
00112 
00113 extern 
00114 hdf_byte_order HDFdatasetGetOrder(hdf_idt id);
00115 
00116 /* Attribute interface */
00117 extern
00118 hdf_idt HDFattrOpen(hdf_idt pid,char *name);
00119 
00120 extern
00121 hdf_err HDFattrClose(hdf_idt id);
00122 
00123 extern
00124 hdf_idt HDFattrCreate(hdf_idt pid,char *name,hdf_type type, size_t size);
00125 
00126 extern
00127 hdf_err HDFattrWrite(hdf_idt id,void *val);
00128 
00129 extern
00130 hdf_err HDFattrRead(hdf_idt id,void *val);
00131 
00132 extern
00133 hdf_type HDFattrGetType(hdf_idt id);
00134 
00135 extern
00136 hdf_type HDFattrGetSize(hdf_idt id);
00137 
00138 /* HDF Tools */
00139 extern
00140 void HDFerrorModeLock();
00141 
00142 extern
00143 hdf_err
00144 HDFnObjects(hdf_idt fid,const char *path,int *n);
00145 
00146 extern
00147 hdf_err HDFobjectIdentify(hdf_idt fid,const char *path,int i,char *name);
00148 
00149 extern
00150 hdf_err HDFobjectType(hdf_idt id, char *name, hdf_object_type *type);
00151 #ifdef __cplusplus
00152 }
00153 #endif
00154 
00155 #endif /* HDFI_H */