56 class KRATOS_API(HDF5_APPLICATION)
File
62 enum class DataTransferMode
113 bool HasPath(
const std::string& rPath)
const;
121 bool IsGroup(
const std::string& rPath)
const;
129 bool IsDataSet(
const std::string& rPath)
const;
139 const std::string& rObjectPath,
140 const std::string& rName)
const;
151 template<
class TDataType>
152 bool HasAttributeType(
153 const std::string& rObjectPath,
154 const std::string& rName)
const;
163 std::vector<hsize_t> GetAttributeDimensions(
164 const std::string& rObjectPath,
165 const std::string& rName)
const;
173 void DeleteAttribute(
174 const std::string& rObjectPath,
175 const std::string& rName);
183 std::vector<std::string> GetAttributeNames(
const std::string& rObjectPath)
const;
198 std::vector<std::string> GetLinkNames(
const std::string& rGroupPath)
const;
206 std::vector<std::string> GetGroupNames(
const std::string& rGroupPath)
const;
214 std::vector<std::string> GetDataSetNames(
const std::string& rGroupPath)
const;
225 void AddPath(
const std::string& rPath);
235 template<
class TDataType>
237 const std::string& rObjectPath,
238 const std::string& rName,
239 const TDataType& rValue);
248 const std::string& rObjectPath,
262 template<
class TDataType>
264 const std::string& rPath,
265 const TDataType& rData,
279 template<
class TDataType>
280 void WriteDataSetIndependent(
281 const std::string& rPath,
282 const TDataType& rData,
300 bool HasIntDataType(
const std::string& rPath)
const;
309 bool HasFloatDataType(
const std::string& rPath)
const;
319 template<
class TDataType>
320 bool HasDataType(
const std::string& rPath)
const;
334 unsigned GetFileSize()
const;
336 std::string GetFileName()
const;
338 int GetEchoLevel()
const;
345 unsigned GetPID()
const;
348 unsigned GetTotalProcesses()
const;
358 template<
class TDataType>
360 const std::string& rObjectPath,
361 const std::string& rName,
362 TDataType& rValue)
const;
370 Parameters ReadAttribute(
const std::string& rObjectPath)
const;
385 template<
class TDataType>
387 const std::string& rPath,
389 const unsigned StartIndex,
390 const unsigned BlockSize)
const;
403 template<
class TDataType>
404 void ReadDataSetIndependent(
405 const std::string& rPath,
407 const unsigned StartIndex,
408 const unsigned BlockSize)
const;
410 unsigned GetOpenObjectsCount()
const;
419 std::string mFileName;
431 const std::string& rDriver,
432 hid_t FileAccessPropertyListId)
const;
434 hid_t GetFileId()
const;
436 hid_t OpenExistingDataSet(
const std::string& rPath);
438 template<
class TDataType, DataTransferMode TDataTransferMode>
439 void WriteDataSetImpl(
440 const std::string& rPath,
441 const TDataType& rData,
444 template<
class TDataType, DataTransferMode TDataTransferMode>
445 void ReadDataSetImpl(
446 const std::string& rPath,
448 const unsigned StartIndex,
449 const unsigned BlockSize)
const;
463 bool IsPath(
const std::string& rPath);
466 std::vector<std::string>
Split(
const std::string& rPath,
char Delimiter);
PeriodicInterfaceProcess & operator=(const PeriodicInterfaceProcess &)=delete
Serial (do-nothing) version of a wrapper class for MPI communication.
Definition: data_communicator.h:318
A base class for reading and writing an HDF5 file.
Definition: hdf5_file.h:57
File & operator=(const File &rOther)=delete
File(const File &rOther)=delete
KRATOS_CLASS_POINTER_DEFINITION(File)
Pointer definition.
Definition: amatrix_interface.h:41
This class provides to Kratos a data structure for I/O based on the standard of JSON.
Definition: kratos_parameters.h:59
def Flush(a)
Definition: DEM_procedures.py:13
bool IsPath(const std::string &rPath)
Check if string is a valid path.
Definition: hdf5_file.cpp:66
std::vector< hsize_t > GetDataDimensions(const Vector< array_1d< double, 3 >> &rData)
std::vector< std::string > Split(const std::string &rPath, char Delimiter)
Return vector of non-empty substrings separated by a delimiter.
void SetEchoLevel(const int EchoLevel)
Definition: add_custom_io_to_python.cpp:344
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
Stores information about a dataset written to HDF5.
Definition: hdf5_file.h:44
std::size_t TotalSize
Definition: hdf5_file.h:47
std::size_t BlockSize
Definition: hdf5_file.h:46
std::size_t StartIndex
Definition: hdf5_file.h:45