|
CP2K 2.4 (Revision 12889)
|
a wrapper for basic fortran types. More...
Classes | |
| struct | val_p_type |
| pointer to a val, to create arrays of pointers More... | |
| struct | val_type |
| a type to have a wrapper that stores any basic fortran type More... | |
Functions | |
| subroutine, public | val_create (val, l_val, l_vals, l_vals_ptr, i_val, i_vals, i_vals_ptr, r_val, r_vals, r_vals_ptr, c_val, c_vals, c_vals_ptr, lc_val, lc_vals, lc_vals_ptr, enum, error) |
| creates a keyword value | |
| subroutine, public | val_release (val, error) |
| releases the given val | |
| subroutine, public | val_retain (val, error) |
| retains the given val | |
| subroutine, public | val_get (val, has_l, has_i, has_r, has_lc, has_c, l_val, l_vals, i_val, i_vals, r_val, r_vals, c_val, c_vals, len_c, type_of_var, enum, error) |
| returns the stored values | |
| subroutine, public | val_write (val, unit_nr, unit, unit_str, fmt, error) |
| writes out the valuse stored in the val | |
| subroutine, public | val_write_internal (val, string, unit, error) |
| Write values to an internal file, i.e. string variable. | |
| subroutine, public | val_duplicate (val_in, val_out, error) |
| creates a copy of the given value | |
Variables | |
| LOGICAL, parameter, private | debug_this_module = .TRUE. |
| CHARACTER(len=*), parameter, private | moduleN = 'input_val_types' |
| INTEGER, save, private | last_val_id = 0 |
| INTEGER, parameter, public | no_t = 0 |
| INTEGER, parameter, public | logical_t = 1 |
| INTEGER, parameter, public | integer_t = 2 |
| INTEGER, parameter, public | real_t = 3 |
| INTEGER, parameter, public | char_t = 4 |
| INTEGER, parameter, public | enum_t = 5 |
| INTEGER, parameter, public | lchar_t = 6 |
a wrapper for basic fortran types.
| subroutine,public input_val_types::val_create | ( | TYPE(val_type),pointer | val, |
| LOGICAL,intent(in),optional | l_val, | ||
| LOGICAL,dimension(:),intent(in),optional | l_vals, | ||
| LOGICAL,dimension(:),optional,pointer | l_vals_ptr, | ||
| INTEGER,intent(in),optional | i_val, | ||
| INTEGER,dimension(:),intent(in),optional | i_vals, | ||
| INTEGER,dimension(:),optional,pointer | i_vals_ptr, | ||
| REAL(KIND=DP),intent(in),optional | r_val, | ||
| REAL(KIND=DP),dimension(:),intent(in),optional | r_vals, | ||
| REAL(KIND=DP),dimension(:),optional,pointer | r_vals_ptr, | ||
| CHARACTER(LEN=*),intent(in),optional | c_val, | ||
| CHARACTER(LEN=*),dimension(:),intent(in),optional | c_vals, | ||
| CHARACTER(LEN=DEFAULT_STRING_LENGTH),dimension(:),optional,pointer | c_vals_ptr, | ||
| CHARACTER(LEN=*),intent(in),optional | lc_val, | ||
| CHARACTER(LEN=*),dimension(:),intent(in),optional | lc_vals, | ||
| CHARACTER(LEN=DEFAULT_STRING_LENGTH),dimension(:),optional,pointer | lc_vals_ptr, | ||
| TYPE(enumeration_type),optional,pointer | enum, | ||
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
creates a keyword value
| val | the object to be created |
| l_val,i_val,r_val,c_val,lc_val,: | a logical,integer,real,string, long string to be stored in the val |
| l_vals,i_vals,r_vals,c_vals,: | an array of logicals, integers, reals, characters, long strings to be stored in val |
| l_vals_ptr,i_vals_ptr,r_vals_ptr,c_vals_ptr,: | an array of logicals, ... to be stored in val, val will get the ownership of the pointer |
| enum | the enumaration type this value is using |
| error | variable to control error logging, stopping,... see module cp_error_handling |
Definition at line 92 of file input_val_types.f90.
References char_t, CPAssert, CPPostcondition, kinds::default_string_length, enum_t, error, integer_t, last_val_id, lchar_t, logical_t, no_t, and real_t.
Referenced by input_cp2k_restarts::dump_csvr_energy_info(), input_keyword_types::keyword_create(), input_cp2k_restarts::meta_hills_val_set_ds(), input_cp2k_restarts::meta_hills_val_set_dt(), input_cp2k_restarts::meta_hills_val_set_ss(), input_cp2k_restarts::meta_hills_val_set_ww(), input_cp2k_restarts::section_coord_val_set(), input_cp2k_restarts::section_neb_coord_val_set(), input_cp2k_restarts::section_rng_val_set(), input_cp2k_restarts::section_velocity_val_set(), input_cp2k_restarts::update_dipoles_section(), input_cp2k_restarts::update_quadrupoles_section(), and input_parsing::val_create_parsing().
Here is the caller graph for this function:| subroutine,public input_val_types::val_duplicate | ( | TYPE(val_type),pointer | val_in, |
| TYPE(val_type),pointer | val_out, | ||
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
creates a copy of the given value
| val_in | the value to copy |
| val_out | the value tha will be created |
| error | variable to control error logging, stopping,... see module cp_error_handling |
Definition at line 792 of file input_val_types.f90.
References CPPostcondition, and last_val_id.
| subroutine,public input_val_types::val_get | ( | TYPE(val_type),pointer | val, |
| LOGICAL,intent(out),optional | has_l, | ||
| LOGICAL,intent(out),optional | has_i, | ||
| LOGICAL,intent(out),optional | has_r, | ||
| LOGICAL,intent(out),optional | has_lc, | ||
| LOGICAL,intent(out),optional | has_c, | ||
| LOGICAL,intent(out),optional | l_val, | ||
| LOGICAL,dimension(:),optional,pointer | l_vals, | ||
| INTEGER,intent(out),optional | i_val, | ||
| INTEGER,dimension(:),optional,pointer | i_vals, | ||
| REAL(KIND=DP),intent(out),optional | r_val, | ||
| REAL(KIND=DP),dimension(:),optional,pointer | r_vals, | ||
| CHARACTER(LEN=*),intent(out),optional | c_val, | ||
| CHARACTER(LEN=DEFAULT_STRING_LENGTH),dimension(:),optional,pointer | c_vals, | ||
| INTEGER,intent(out),optional | len_c, | ||
| INTEGER,intent(out),optional | type_of_var, | ||
| TYPE(enumeration_type),optional,pointer | enum, | ||
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
returns the stored values
| val | the object from which you want to extract the values |
| l_val,i_val,r_val,c_val,: | gets a logical, integer, real, char from the val |
| logical_vals | gets an array of logicals, integers, reals, chars from the val |
| len_c | len_trim of c_val (if it was a lc_val, of type lchar_t it might be longet than default_string_length) |
| error | variable to control error logging, stopping,... see module cp_error_handling |
Definition at line 376 of file input_val_types.f90.
References CPAssert, kinds::default_string_length, input_enumeration_types::enum_i2c(), error, and lchar_t.
Referenced by force_fields_all::force_field_pack_charges(), md_vel_utils::initialize_cascade(), md_vel_utils::initialize_velocities(), external_potential_types::read_all_potential(), atoms_input::read_atoms_input(), atom_types::read_basis_set(), basis_set_types::read_geminal_basis_set(), external_potential_types::read_gth_potential(), atom_types::read_gth_potential(), basis_set_types::read_gto_basis_set(), atoms_input::read_shell_coord_input(), and val_write_internal().
Here is the call graph for this function:
Here is the caller graph for this function:| subroutine,public input_val_types::val_release | ( | TYPE(val_type),pointer | val, |
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
releases the given val
| val | the val to release |
| error | variable to control error logging, stopping,... see module cp_error_handling |
Definition at line 293 of file input_val_types.f90.
References CPPostconditionNoFail, CPPreconditionNoFail, and no_t.
Referenced by input_keyword_types::keyword_create(), and input_keyword_types::keyword_release().
Here is the caller graph for this function:| subroutine,public input_val_types::val_retain | ( | TYPE(val_type),pointer | val, |
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
retains the given val
| val | the val to retain |
| error | variable to control error logging, stopping,... see module cp_error_handling |
Definition at line 341 of file input_val_types.f90.
References CPPreconditionNoFail.
Referenced by input_keyword_types::keyword_create().
Here is the caller graph for this function:| subroutine,public input_val_types::val_write | ( | TYPE(val_type),pointer | val, |
| INTEGER,intent(in) | unit_nr, | ||
| TYPE(cp_unit_type),optional,pointer | unit, | ||
| CHARACTER(len=*),intent(in),optional | unit_str, | ||
| CHARACTER(len=*),intent(in),optional | fmt, | ||
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
writes out the valuse stored in the val
| val | the val to write |
| unit_nr | the number of the unit to write to |
| unit | the unit of mesure in wich the output should be written (overrides unit_str) |
| unit_str | the unit of mesure in wich the output should be written |
| error | variable to control error logging, stopping,... see module cp_error_handling |
Definition at line 528 of file input_val_types.f90.
References char_t, cp_units::cp_unit_create(), CPAssert, cp_parser_types::default_continuation_character, input_enumeration_types::enum_i2c(), enum_t, integer_t, lchar_t, logical_t, no_t, and real_t.
Referenced by input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), and input_parsing::section_vals_parse().
Here is the call graph for this function:
Here is the caller graph for this function:| subroutine,public input_val_types::val_write_internal | ( | TYPE(val_type),pointer | val, |
| CHARACTER(LEN=*),intent(out) | string, | ||
| TYPE(cp_unit_type),optional,pointer | unit, | ||
| TYPE(cp_error_type),intent(inout) | error | ||
| ) |
Write values to an internal file, i.e. string variable.
Definition at line 691 of file input_val_types.f90.
References char_t, CPAssert, input_enumeration_types::enum_i2c(), enum_t, integer_t, lchar_t, logical_t, real_t, and val_get().
Referenced by input_keyword_types::write_keyword_xml().
Here is the call graph for this function:
Here is the caller graph for this function:| INTEGER,parameter,public input_val_types::char_t = 4 |
Definition at line 43 of file input_val_types.f90.
Referenced by input_cp2k_free_energy::create_ac_section(), input_cp2k_atom::create_atom_section(), input_cp2k_mm::create_BEND_section(), input_cp2k_mm::create_BMHFT_section(), input_cp2k_mm::create_BMHFTD_section(), input_cp2k_mm::create_BOND_section(), input_cp2k_mm::create_Buck4r_section(), input_cp2k_mm::create_Buckmorse_section(), input_cp2k_mm::create_charge_section(), input_cp2k_constraints::create_collective_section(), input_cp2k_colvar::create_colvar_comb_section(), input_cp2k_colvar::create_colvar_cond_dist_section(), input_cp2k_colvar::create_colvar_coord_section(), input_cp2k_colvar::create_colvar_gyr_section(), input_cp2k_colvar::create_colvar_pop_section(), input_cp2k_colvar::create_colvar_u_section(), input_cp2k_mm::create_damping_section(), input_cp2k_dft::create_dft_section(), input_cp2k_dft::create_dftb_parameter_section(), input_cp2k_mm::create_dipole_section(), input_cp2k_mm::create_EAM_section(), input_cp2k_subsys::create_exclude_list_section(), input_cp2k_force_eval::create_ext_pot_section(), input_cp2k_dft::create_ext_pot_section(), input_cp2k::create_ext_restart_section(), input_cp2k_constraints::create_fixed_atom_section(), input_cp2k_constraints::create_g3x3_section(), input_cp2k_constraints::create_g4x6_section(), input_cp2k_mm::create_GENPOT_section(), input_cp2k::create_global_section(), input_cp2k_mm::create_Goodwin_section(), input_cp2k_constraints::create_hbonds_section(), input_cp2k_mm::create_IMPROPER_section(), input_cp2k_mm::create_ipbv_section(), input_cp2k_subsys::create_kind_section(), input_cp2k_xc::create_libxc_section(), input_cp2k_mm::create_LJ_section(), input_cp2k_mixed::create_mix_section(), input_cp2k_resp::create_nonperiodic_sys_section(), input_cp2k_mm::create_OPBEND_section(), input_optimize_basis::create_optimize_basis_section(), input_optimize_input::create_optimize_input_section(), input_cp2k_qmmm::create_qmmm_force_mixing_section(), input_cp2k_qmmm::create_qmmm_link_section(), input_cp2k_qmmm::create_qmmm_mm_kinds(), input_cp2k_qmmm::create_qmmm_qm_kinds(), input_cp2k_mm::create_quadrupole_section(), input_cp2k_thermostats::create_region_section(), input_cp2k_dft::create_scptb_control_section(), input_cp2k_mm::create_Siepmann_section(), input_cp2k_mm::create_Tersoff_section(), input_cp2k_mm::create_TORSION_section(), input_cp2k_xc::create_vdw_potential_section(), input_cp2k_constraints::create_vsite_section(), input_cp2k_mm::create_Williams_section(), input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), input_cp2k_colvar::keywords_colvar_path(), val_create(), input_parsing::val_create_parsing(), val_write(), val_write_internal(), and input_keyword_types::write_keyword_xml().
| LOGICAL,parameter,private input_val_types::debug_this_module = .TRUE. |
Definition at line 33 of file input_val_types.f90.
| INTEGER,parameter,public input_val_types::enum_t = 5 |
Definition at line 43 of file input_val_types.f90.
Referenced by input_cp2k_eip::create_eip_section(), input_cp2k_poisson::create_ewald_section(), input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), input_keyword_types::keyword_typo_match(), val_create(), input_parsing::val_create_parsing(), val_write(), val_write_internal(), and input_keyword_types::write_keyword_xml().
| INTEGER,parameter,public input_val_types::integer_t = 2 |
Definition at line 43 of file input_val_types.f90.
Referenced by cp_result_types::cp_result_value_copy(), cp_result_types::cp_result_value_init(), cp_result_types::cp_result_value_release(), cp_result_methods::cp_results_mp_bcast(), input_cp2k_motion::create_avgs_restart_section(), input_cp2k_properties_dft::create_current_section(), input_cp2k_properties_dft::create_epr_section(), input_cp2k_motion::create_fp_section(), input_cp2k_motion::create_helium_section(), input_cp2k_vib::create_involved_atoms_section(), input_cp2k_motion::create_mc_section(), input_cp2k_vib::create_mode_selective_section(), input_cp2k_properties_dft::create_nmr_section(), input_cp2k_properties_dft::create_restraint_A(), input_cp2k_properties_dft::create_spin_spin_section(), input_cp2k_motion::create_thermal_region_section(), cp_result_methods::get_nreps(), input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), val_create(), input_parsing::val_create_parsing(), val_write(), val_write_internal(), and input_keyword_types::write_keyword_xml().
| INTEGER,save,private input_val_types::last_val_id = 0 |
Definition at line 36 of file input_val_types.f90.
Referenced by val_create(), and val_duplicate().
| INTEGER,parameter,public input_val_types::lchar_t = 6 |
Definition at line 43 of file input_val_types.f90.
Referenced by input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), input_parsing::section_vals_parse(), input_section_types::section_vals_val_set(), input_section_types::section_vals_write(), val_create(), input_parsing::val_create_parsing(), val_get(), val_write(), val_write_internal(), and input_keyword_types::write_keyword_xml().
| INTEGER,parameter,public input_val_types::logical_t = 1 |
Definition at line 43 of file input_val_types.f90.
Referenced by input_cp2k_check::handle_defaults_restart(), input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), val_create(), input_parsing::val_create_parsing(), val_write(), val_write_internal(), and input_keyword_types::write_keyword_xml().
| CHARACTER(len=*),parameter,private input_val_types::moduleN = 'input_val_types' |
Definition at line 34 of file input_val_types.f90.
| INTEGER,parameter,public input_val_types::no_t = 0 |
Definition at line 43 of file input_val_types.f90.
Referenced by input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), val_create(), input_parsing::val_create_parsing(), val_release(), val_write(), and input_keyword_types::write_keyword_xml().
| INTEGER,parameter,public input_val_types::real_t = 3 |
Definition at line 43 of file input_val_types.f90.
Referenced by input_cp2k_barostats::create_barostat_section(), input_cp2k_hfx::create_hf_potential_section(), input_cp2k_mp2::create_mp2_potential(), input_cp2k_mp2::create_wfc_gpw(), input_keyword_types::keyword_create(), input_keyword_types::keyword_describe(), input_keyword_types::keyword_describe_html(), val_create(), input_parsing::val_create_parsing(), val_write(), val_write_internal(), and input_keyword_types::write_keyword_xml().
1.7.3