diff --git a/src/core.F90 b/src/core.F90 index ca208f7d..f1a9faf8 100644 --- a/src/core.F90 +++ b/src/core.F90 @@ -45,6 +45,8 @@ module tuvx_core procedure :: get_grid_warehouse ! Returns a profile from the warehouse procedure :: get_profile + ! Returns the profile warehouse + procedure :: get_profile_warehouse ! Returns an updater for use TUV-x data procedure, private :: get_grid_updater, get_profile_updater, & get_radiator_updater @@ -344,6 +346,23 @@ function get_profile( this, profile_name, units ) result( profile ) end function get_profile +!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + + function get_profile_warehouse( this ) result( profile_warehouse ) + ! Returns a copy of a profile from the warehouse + + use musica_assert, only : assert_msg + use tuvx_profile, only : profile_t + + class(core_t), intent(in) :: this + class(profile_warehouse_t), pointer :: profile_warehouse + + call assert_msg( 423051914, associated( this%profile_warehouse_ ), & + "Profiles not available" ) + profile_warehouse => this%profile_warehouse_ + + end function get_profile_warehouse + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! function get_grid_updater( this, grid, found ) result( updater )