Quantum 3xplorer (Q3)
Loading...
Searching...
No Matches
factory.hpp
Go to the documentation of this file.
1
#pragma once
2
3
/**
4
* Factory for planewave Kohn-Sham quantum system checkpoint managers.
5
*
6
* Supported formats: "q3" (Q3 native binary, default).
7
*/
8
9
#include <memory>
10
#include <stdexcept>
11
#include <string>
12
13
#include "
io/quantum_system/kohn_sham/planewave/checkpoint/init.hpp
"
14
#include "
io/quantum_system/kohn_sham/planewave/checkpoint/q3.hpp
"
15
16
namespace
q3
{
17
18
inline
std::unique_ptr<KohnShamQuantumSystemCheckpoint>
19
create_quantum_system_checkpoint
(
const
std::string& format =
"q3"
) {
20
if
(format ==
"q3"
) {
21
return
std::make_unique<Q3PlanewaveKohnShamQuantumSystemCheckpoint>();
22
}
23
throw
std::runtime_error(
"Unknown quantum system checkpoint format: "
+ format);
24
}
25
26
}
// namespace q3
init.hpp
q3
Definition
q3_core_api.hpp:33
q3::create_quantum_system_checkpoint
std::unique_ptr< KohnShamQuantumSystemCheckpoint > create_quantum_system_checkpoint(const std::string &format="q3")
Definition
factory.hpp:19
q3.hpp
src
io
quantum_system
kohn_sham
planewave
checkpoint
factory.hpp
Generated by
1.9.8