|
ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
|
Friend helper to mutate PARAM private members in unit tests. More...
#include <td_test_utils.h>
Public Member Functions | |
| TestParameters (Parameter ¶meter) | |
| ~TestParameters () | |
| void | set_output (const std::string &directory, bool append, const std::string &band_directory) |
| TestParameters (Parameter &target) | |
| ~TestParameters () noexcept | |
| TestParameters (const TestParameters &)=delete | |
| TestParameters & | operator= (const TestParameters &)=delete |
| TestParameters (TestParameters &&)=delete | |
| TestParameters & | operator= (TestParameters &&)=delete |
Static Public Member Functions | |
| static void | reset () |
| static void | set_nspin (const int nspin) |
| static void | set_nelec (const double nelec) |
| static void | set_two_fermi (const bool two_fermi) |
| static Input_para & | input () |
| static System_para & | sys () |
| static void | reset () |
| static void | use_cpu_single () |
| static void | set_global_dir (ModuleIO::ReadInput &readinput, const Input_para &inp, System_para &sys) |
| static void | set_globalv (ModuleIO::ReadInput &readinput, const Input_para &inp, System_para &sys) |
| static Input_para & | input () |
| static System_para & | sys () |
| static Input_para & | input () |
| static System_para & | sys () |
| static MD_para & | mdp () |
| static Input_para & | input (Parameter ¶m) |
| static System_para & | sys (Parameter ¶m) |
| static Input_para & | input (Parameter ¶m) |
| static System_para & | sys (Parameter ¶m) |
| static Input_para & | input () |
| static System_para & | sys () |
| static Input_para & | input () |
| static System_para & | sys () |
| static Input_para & | input () |
| static System_para & | sys () |
| static Input_para & | input () |
| static System_para & | sys () |
| static void | init (int npol, bool gamma_only_local, int nlocal, int nspin) |
| static void | gamma_only (const bool enabled) |
| static void | set_relax (const std::string &out_level, const double relax_bfgs_rmax, const double relax_bfgs_rmin, const double relax_bfgs_init, const std::string &fixed_axes) |
Private Attributes | |
| Parameter & | parameter_ |
| bool | append_ = false |
| std::string | directory_ |
| std::string | band_directory_ |
| Parameter & | target_ |
| Input_para | input_ |
| System_para | system_ |
Friend helper to mutate PARAM private members in unit tests.
Install isolated spinor test settings and restore the supplied parameter object's state.
Friend helper to mutate Parameter private members in unit tests.
Friend helper to invoke ReadInput private setters in unit tests.
FixedWeights: elecstate::ElecState::fixed_weights()
CalEBand: elecstate::ElecState::cal_eband()
CalculateWeights: elecstate::ElecState::calculate_weights()
Parameter grants friend access to TestParameters so the test can modify input/sys fields without #define private public. The class must stay at global scope to match the friend declaration in parameter.h; an anonymous-namespace class would not be the friend.
ReadInput grants friend access to TestParameters so the test can drive its private setup routines without #define private public. The class must stay at global scope to match the friend declaration in read_input.h; an anonymous-namespace class would not be the friend.
Parameter grants friend access to TestParameters so the test can modify input/sys fields of a local Parameter instance without #define private public. The class must stay at global scope to match the friend declaration in parameter.h; an anonymous-namespace class would not be the friend.
Save and restore only the global settings consumed by band output.
|
inlineexplicit |
|
inlinenoexcept |
|
explicit |
|
noexcept |
|
delete |
|
delete |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
delete |
|
delete |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inline |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |