MPQC  3.0.0-alpha
mpqc::File Struct Reference

Top-level file object that holds groups. More...

#include <mpqc/file.hpp>

Inheritance diagram for mpqc::File:
mpqc::detail::File::Object

Classes

struct  Dataset
 Array-like collection of data. More...
 
struct  Dataspace
 A subset of File::Dataset. More...
 
struct  Driver
 Base file driver. More...
 
struct  Group
 Directory-like container that holds datasets and other groups. More...
 
struct  POSIXDriver
 POSIX I/O file driver, the default. More...
 

Public Types

typedef detail::File::Object Object
 
typedef detail::File::Attribute Attribute
 
typedef detail::File::Properties Properties
 

Public Member Functions

 File ()
 Constructs a null file object. More...
 
 File (const std::string &name, const Driver &driver=POSIXDriver())
 Create or open File. More...
 
Group group (const std::string &name="/")
 Creates or opens a file group. More...
 
- Public Member Functions inherited from mpqc::detail::File::Object
 Object ()
 Default constructor with an invalid handle.
 
 Object (const Object &o)
 Copy constructor.
 
 Object (const Object &parent, hid_t id, void(*close)(hid_t), bool increment)
 
void operator= (const Object &o)
 
hid_t id () const
 
const Objectparent () const
 
hid_t file () const
 
 operator bool () const
 

Additional Inherited Members

- Static Public Member Functions inherited from mpqc::detail::File::Object
static std::string filename (hid_t id)
 
- Protected Member Functions inherited from mpqc::detail::File::Object
template<class F >
void update (hid_t id, F close, bool increment)
 
- Protected Attributes inherited from mpqc::detail::File::Object
std::auto_ptr< Objectparent_
 
hid_t id_
 
void(* close_ )(hid_t)
 

Detailed Description

Top-level file object that holds groups.

All I/O is done through Dataspace objects which belong to group. The file storage and access properties are determined by the Driver. File objects are copyable, referenced-counted using HDF5 Identifier API

Constructor & Destructor Documentation

◆ File() [1/2]

mpqc::File::File ( )
inline

Constructs a null file object.

Creating objects with this file as parent will fail

◆ File() [2/2]

mpqc::File::File ( const std::string &  name,
const Driver driver = POSIXDriver() 
)
inlineexplicit

Create or open File.

File may be opened multiple times: if an open file by that name already exists, that existing instance will be used.

Parameters
[in]namefile name
[in]driverFile driver, determining how file is created.
Warning
NOT threadsafe

The list of opened files is stored internally in a static set


The documentation for this struct was generated from the following file:

Generated at Sun Jan 26 2020 23:24:02 for MPQC 3.0.0-alpha using the documentation package Doxygen 1.8.16.