set_species_config Subroutine

public subroutine set_species_config(species_config_in, species_element_config_in)

Uses

Set the module level config types Will abort if the module has already been initialised to avoid inconsistencies.

Arguments

Type IntentOptional Attributes Name
type(species_config_type), intent(in), optional :: species_config_in
type(species_element_config_type), intent(in), optional, dimension(:), allocatable :: species_element_config_in

Contents

Source Code


Source Code

  subroutine set_species_config(species_config_in, species_element_config_in)
    use mp, only: mp_abort
    type(species_config_type), intent(in), optional :: species_config_in
    type(species_element_config_type), intent(in), dimension(:), allocatable, optional :: species_element_config_in

    if (initialized) then
       call mp_abort("Trying to set species_config when already initialized.", to_screen = .true.)
    end if
    if (present(species_config_in)) then
       species_config = species_config_in
    end if
    if (present(species_element_config_in)) then
       species_element_config = species_element_config_in
    end if    
  end subroutine set_species_config