persist/include/persist/core/storage/file_storage.hpp
/**
 * Cross-platform method to open file while creating non-existing
 * directories in the given path.
 *
 * @param path path of the file to open
 * @param mode open mode
 * @returns opened file stream object
 */
Cross-platform method to open file while creating non-existing
directories in the given path.

@param path path of the file to open
@param mode open mode
@returns opened file stream object
Cross - platform method to open file while creating non - existing directories in the given path . @param path path of the file to open @param mode open mode @returns opened file stream object
static std::fstream open(std::string path, std::ios_base::openmode mode) {
  std::fstream file;
  file.open(path.c_str(), std::ios::out | std::ios::app);
  file.close();
  file.open(path.c_str(), mode);
  return file;
}
static std :: fstream open ( std :: string path , std :: ios_base :: openmode mode ) { std :: fstream file ; file . open ( path . c_str ( ) , std :: ios :: out | std :: ios :: app ) ; file . close ( ) ; file . open ( path . c_str ( ) , mode ) ; return file ; }
Cross-platform method to open file while creating non-existing
 directories in the given path.
Cross - platform method to open file while creating non - existing directories in the given path .
// TODO: Use cross-platform solution for creating sub-directories // Creating file if it does not exist