Base class for binary archives.
More...
|
static std::string | generatePath (const std::string &name, const std::string &extension, int block=-1) |
|
static std::string | generatePath (const std::string &name, int block=-1) |
|
|
void | open (const std::string &name, const std::string &extension, ios_base::openmode mode, int block=-1) |
|
Base class for binary archives.
The BinaryArchive is the blas class from which input and output binary archives are derived from.
Definition at line 36 of file binary_archive.hpp.
◆ BinaryArchive()
bitpit::BinaryArchive::BinaryArchive |
( |
| ) |
|
◆ ~BinaryArchive()
bitpit::BinaryArchive::~BinaryArchive |
( |
| ) |
|
◆ generatePath() [1/2]
std::string bitpit::BinaryArchive::generatePath |
( |
const std::string & | name, |
|
|
const std::string & | extension, |
|
|
int | block = -1 ) |
|
static |
Generates the path of the archive with the specified properties.
- Parameters
-
name | is the name of the file |
extension | is the extension of the file |
block | is the parallel block thefile belongs to, a negative value mean that the file is serial |
- Returns
- The path of the archive with the specified properties.
Definition at line 65 of file binary_archive.cpp.
◆ generatePath() [2/2]
std::string bitpit::BinaryArchive::generatePath |
( |
const std::string & | name, |
|
|
int | block = -1 ) |
|
static |
Generates the path of the archive with the specified properties.
- Parameters
-
name | is the name of the file |
block | is the parallel block thefile belongs to, a negative value mean that the file is serial |
- Returns
- The path of the archive with the specified properties.
Definition at line 51 of file binary_archive.cpp.
◆ getHeader()
std::string bitpit::BinaryArchive::getHeader |
( |
| ) |
const |
Gets the header associated to the archive.
- Returns
- The header associated to the archive.
Definition at line 131 of file binary_archive.cpp.
◆ getPath()
std::string bitpit::BinaryArchive::getPath |
( |
| ) |
const |
Gets the path of the archive.
- Returns
- The path of the archive.
Definition at line 141 of file binary_archive.cpp.
◆ getVersion()
int bitpit::BinaryArchive::getVersion |
( |
| ) |
const |
Gets the version associated to the archive.
- Returns
- The version associated to the archive.
Definition at line 121 of file binary_archive.cpp.
◆ open()
void bitpit::BinaryArchive::open |
( |
const std::string & | name, |
|
|
const std::string & | extension, |
|
|
ios_base::openmode | mode, |
|
|
int | block = -1 ) |
|
protected |
Opens the specified file, associating it with the stream object, so that input/output operations are performed on its content.
- Parameters
-
name | is the name of the file |
extension | is the extension of the file |
mode | specifies the opening mode |
block | is the parallel block thefile belongs to, a negative value mean that the file is serial |
Definition at line 102 of file binary_archive.cpp.
◆ EXTENSION_DEFAULT
const std::string bitpit::BinaryArchive::EXTENSION_DEFAULT = "dat" |
|
static |
◆ HEADER_SIZE
BITPIT_PUBLIC_API const int bitpit::BinaryArchive::HEADER_SIZE = 1024 |
|
static |
◆ m_header
std::string bitpit::BinaryArchive::m_header |
|
protected |
◆ m_path
std::string bitpit::BinaryArchive::m_path |
|
protected |
◆ m_version
int bitpit::BinaryArchive::m_version |
|
protected |
◆ VERSION_UNDEFINED
BITPIT_PUBLIC_API const int bitpit::BinaryArchive::VERSION_UNDEFINED = - std::numeric_limits<int>::max() |
|
static |
The documentation for this class was generated from the following files:
---
layout: doxygen_footer
---