initialize_user.F90 Source File


This file depends on

sourcefile~~initialize_user.f90~~EfferentGraph sourcefile~initialize_user.f90 initialize_user.F90 sourcefile~componentdriver.f90 ComponentDriver.F90 sourcefile~initialize_user.f90->sourcefile~componentdriver.f90 sourcefile~componentdriverptrvector.f90 ComponentDriverPtrVector.F90 sourcefile~initialize_user.f90->sourcefile~componentdriverptrvector.f90 sourcefile~couplerphases.f90 CouplerPhases.F90 sourcefile~initialize_user.f90->sourcefile~couplerphases.f90 sourcefile~errorhandling.f90 ErrorHandling.F90 sourcefile~initialize_user.f90->sourcefile~errorhandling.f90 sourcefile~outermetacomponent.f90 OuterMetaComponent.F90 sourcefile~initialize_user.f90->sourcefile~outermetacomponent.f90 sourcefile~componentdriver.f90->sourcefile~errorhandling.f90 sourcefile~maplshared.f90 MaplShared.F90 sourcefile~componentdriver.f90->sourcefile~maplshared.f90 sourcefile~multistate.f90 MultiState.F90 sourcefile~componentdriver.f90->sourcefile~multistate.f90 sourcefile~componentdriverptrvector.f90->sourcefile~componentdriver.f90 sourcefile~mapl_throw.f90 MAPL_Throw.F90 sourcefile~errorhandling.f90->sourcefile~mapl_throw.f90 sourcefile~componentdrivervector.f90 ComponentDriverVector.F90 sourcefile~outermetacomponent.f90->sourcefile~componentdrivervector.f90 sourcefile~componentspec.f90 ComponentSpec.F90 sourcefile~outermetacomponent.f90->sourcefile~componentspec.f90 sourcefile~esmf_interfaces.f90 ESMF_Interfaces.F90 sourcefile~outermetacomponent.f90->sourcefile~esmf_interfaces.f90 sourcefile~griddedcomponentdriver.f90 GriddedComponentDriver.F90 sourcefile~outermetacomponent.f90->sourcefile~griddedcomponentdriver.f90 sourcefile~griddedcomponentdrivermap.f90 GriddedComponentDriverMap.F90 sourcefile~outermetacomponent.f90->sourcefile~griddedcomponentdrivermap.f90 sourcefile~innermetacomponent.f90 InnerMetaComponent.F90 sourcefile~outermetacomponent.f90->sourcefile~innermetacomponent.f90 sourcefile~keywordenforcer.f90 KeywordEnforcer.F90 sourcefile~outermetacomponent.f90->sourcefile~keywordenforcer.f90 sourcefile~methodphasesmap.f90 MethodPhasesMap.F90 sourcefile~outermetacomponent.f90->sourcefile~methodphasesmap.f90 sourcefile~pflogger_stub.f90 pflogger_stub.F90 sourcefile~outermetacomponent.f90->sourcefile~pflogger_stub.f90 sourcefile~stateregistry.f90 StateRegistry.F90 sourcefile~outermetacomponent.f90->sourcefile~stateregistry.f90 sourcefile~usersetservices.f90 UserSetServices.F90 sourcefile~outermetacomponent.f90->sourcefile~usersetservices.f90 sourcefile~verticalgrid.f90 VerticalGrid.F90 sourcefile~outermetacomponent.f90->sourcefile~verticalgrid.f90

Source Code

#include "MAPL_Generic.h"

submodule (mapl3g_OuterMetaComponent) initialize_user_smod
   use mapl3g_GenericPhases
   use mapl3g_ComponentDriver
   use mapl3g_ComponentDriverPtrVector
   use mapl3g_CouplerPhases, only: GENERIC_COUPLER_INITIALIZE
   use mapl_ErrorHandling
   implicit none

contains

   module recursive subroutine initialize_user(this, unusable, rc)
      class(OuterMetaComponent), intent(inout) :: this
      ! optional arguments
      class(KE), optional, intent(in) :: unusable
      integer, optional, intent(out) :: rc

      integer :: status
      character(*), parameter :: PHASE_NAME = 'GENERIC::INIT_USER'
      type(ComponentDriverPtrVector) :: export_Couplers
      type(ComponentDriverPtr) :: drvr
      integer :: i

      export_couplers = this%registry%get_export_couplers()
      do i = 1, export_couplers%size()
         drvr = export_couplers%of(i)
         call drvr%ptr%initialize(phase_idx=GENERIC_COUPLER_INITIALIZE, _RC)
      end do

      call this%run_custom(ESMF_METHOD_INITIALIZE, PHASE_NAME, _RC)
      call recurse(this, phase_idx=GENERIC_INIT_USER, _RC)

      _RETURN(ESMF_SUCCESS)
      _UNUSED_DUMMY(unusable)
   end subroutine initialize_user

end submodule initialize_user_smod