MAPL_GenericRunCouplers Subroutine

public subroutine MAPL_GenericRunCouplers(STATE, CHILD, CLOCK, RC)

Arguments

Type IntentOptional Attributes Name
type(MAPL_MetaComp), intent(inout) :: STATE
integer, intent(in) :: CHILD
type(ESMF_Clock), intent(inout) :: CLOCK
integer, intent(out), optional :: RC

Calls

proc~~mapl_genericruncouplers~~CallsGraph proc~mapl_genericruncouplers MAPL_GenericRunCouplers ESMF_CplCompRun ESMF_CplCompRun proc~mapl_genericruncouplers->ESMF_CplCompRun none~get_child_export_state MAPL_MetaComp%get_child_export_state proc~mapl_genericruncouplers->none~get_child_export_state none~get_child_import_state MAPL_MetaComp%get_child_import_state proc~mapl_genericruncouplers->none~get_child_import_state none~get_num_children~3 CompositeComponent%get_num_children proc~mapl_genericruncouplers->none~get_num_children~3 proc~mapl_return MAPL_Return proc~mapl_genericruncouplers->proc~mapl_return proc~mapl_verify MAPL_Verify proc~mapl_genericruncouplers->proc~mapl_verify none~get_export_state MaplGenericComponent%get_export_state none~get_child_export_state->none~get_export_state none~get_ith_child MAPL_MetaComp%get_ith_child none~get_child_export_state->none~get_ith_child none~get_import_state MaplGenericComponent%get_import_state none~get_child_import_state->none~get_import_state none~get_child_import_state->none~get_ith_child none~get_num_children~5 ConcreteComposite%get_num_children none~get_num_children~3->none~get_num_children~5 at at proc~mapl_return->at insert insert proc~mapl_return->insert proc~mapl_throw_exception MAPL_throw_exception proc~mapl_return->proc~mapl_throw_exception proc~mapl_verify->proc~mapl_throw_exception none~is_threading_active MaplGenericComponent%is_threading_active none~get_export_state->none~is_threading_active proc~get_current_thread get_current_thread none~get_export_state->proc~get_current_thread none~get_import_state->none~is_threading_active none~get_import_state->proc~get_current_thread none~get_child~26 MAPL_MetaComp%get_child none~get_ith_child->none~get_child~26 none~get_child_by_index CompositeComponent%get_child_by_index none~get_child~26->none~get_child_by_index none~get_child_by_name CompositeComponent%get_child_by_name none~get_child~26->none~get_child_by_name

Source Code

   subroutine MAPL_GenericRunCouplers( STATE, CHILD, CLOCK, RC )

      !ARGUMENTS:
      type (MAPL_MetaComp),    intent(INOUT) :: STATE
      integer,                 intent(IN   ) :: CHILD  ! Child Id
      type(ESMF_Clock),        intent(INOUT) :: CLOCK  ! The clock
      integer, optional,       intent(  OUT) :: RC     ! Error code
      !EOPI

      ! ErrLog Variables
      character(len=ESMF_MAXSTR), parameter :: IAm="MAPL_GenericRunCouplers"
      integer                               :: status
      integer                               :: userRC
      integer                               :: J
      type(ESMF_State), pointer :: child_import_state
      type(ESMF_State), pointer :: child_export_state

      do J=1,STATE%get_num_children()
         if(STATE%CCcreated(CHILD,J)) then
            child_export_state => STATE%get_child_export_state(child)
            child_import_state => STATE%get_child_import_state(j)
            call ESMF_CplCompRun (STATE%CCS(CHILD,J), &
                 importState=child_export_state, &
                 exportState=child_import_state, &
                 clock=CLOCK, userRC=userRC, _RC )
            _VERIFY(userRC)
         endif
      enddo

      _RETURN(ESMF_SUCCESS)

   end subroutine MAPL_GenericRunCouplers