CheckError Function

public function CheckError(checkpoint, line, file, rcValue, msg, rcToReturn)

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: checkpoint
integer, intent(in) :: line
character(len=*), intent(in) :: file
integer, intent(in) :: rcValue
character(len=*), intent(in) :: msg
integer, intent(out) :: rcToReturn

Return Value logical


Calls

proc~~checkerror~~CallsGraph proc~checkerror CheckError proc~esmf_logfounderror ESMF_LogFoundError proc~checkerror->proc~esmf_logfounderror esmf_breakpoint esmf_breakpoint proc~esmf_logfounderror->esmf_breakpoint proc~esmf_logrc2msg ESMF_LogRc2Msg proc~esmf_logfounderror->proc~esmf_logrc2msg proc~esmf_logwrite ESMF_LogWrite proc~esmf_logfounderror->proc~esmf_logwrite c_esmc_loggeterrormsg c_esmc_loggeterrormsg proc~esmf_logrc2msg->c_esmc_loggeterrormsg c_esmc_vmwtime c_esmc_vmwtime proc~esmf_logwrite->c_esmc_vmwtime proc~esmf_logclose ESMF_LogClose proc~esmf_logwrite->proc~esmf_logclose proc~esmf_logflush ESMF_LogFlush proc~esmf_logwrite->proc~esmf_logflush proc~esmf_logopenfile ESMF_LogOpenFile proc~esmf_logwrite->proc~esmf_logopenfile proc~esmf_utiliounitflush ESMF_UtilIOUnitFlush proc~esmf_logwrite->proc~esmf_utiliounitflush proc~esmf_utilstring2array ESMF_UtilString2Array proc~esmf_logwrite->proc~esmf_utilstring2array proc~esmf_logclose->proc~esmf_logflush proc~esmf_logflush->proc~esmf_utiliounitflush proc~esmf_utilarray2string ESMF_UtilArray2String proc~esmf_logflush->proc~esmf_utilarray2string proc~esmf_logopenfile->proc~esmf_utiliounitflush proc~esmf_utiliounitget ESMF_UtilIOUnitGet proc~esmf_logopenfile->proc~esmf_utiliounitget

Called by

proc~~checkerror~~CalledByGraph proc~checkerror CheckError proc~array_redist_test array_redist_test proc~array_redist_test->proc~checkerror proc~compare_redist_array compare_redist_array proc~array_redist_test->proc~compare_redist_array proc~create_array create_array proc~array_redist_test->proc~create_array proc~create_distribution create_distribution proc~array_redist_test->proc~create_distribution proc~populate_array_value populate_array_value proc~array_redist_test->proc~populate_array_value proc~populate_redist_array populate_redist_array proc~array_redist_test->proc~populate_redist_array proc~check_field check_field proc~check_field->proc~checkerror proc~compare_redist_array->proc~checkerror proc~create_array->proc~checkerror proc~create_distribution->proc~checkerror proc~create_grid_from_distgrid create_grid_from_distgrid proc~create_grid_from_distgrid->proc~checkerror proc~field_redist_test field_redist_test proc~field_redist_test->proc~checkerror proc~field_redist_test->proc~create_distribution proc~field_redist_test->proc~create_grid_from_distgrid proc~field_regrid_test field_regrid_test proc~field_regrid_test->proc~checkerror proc~field_regrid_test->proc~check_field proc~field_regrid_test->proc~create_distribution proc~field_regrid_test->proc~create_grid_from_distgrid proc~populate_field populate_field proc~field_regrid_test->proc~populate_field proc~parse_descriptor_string parse_descriptor_string proc~parse_descriptor_string->proc~checkerror proc~populate_array_value->proc~checkerror proc~populate_field->proc~checkerror proc~populate_redist_array->proc~checkerror proc~read_descriptor_files read_descriptor_files proc~read_descriptor_files->proc~checkerror program~esmf_test_harness esmf_test_harness program~esmf_test_harness->proc~checkerror proc~read_testharness_specifier Read_TestHarness_Specifier program~esmf_test_harness->proc~read_testharness_specifier proc~runtests RunTests program~esmf_test_harness->proc~runtests proc~read_testharness_specifier->proc~parse_descriptor_string proc~read_testharness_specifier->proc~read_descriptor_files proc~runtests->proc~array_redist_test proc~runtests->proc~field_redist_test proc~runtests->proc~field_regrid_test

Source Code

  logical function CheckError (checkpoint, line, file, rcValue, msg, rcToReturn)
    logical,          intent(in)  :: checkpoint
    integer,          intent(in)  :: line
    character(len=*), intent(in)  :: file
    character(len=*), intent(in)  :: msg
    integer,          intent(in)  :: rcValue
    integer,          intent(out) :: rcToReturn

    if (checkpoint) then
      print '("checkpoint at line ", I5, " in file ", A)', line, file
    end if

    rcToReturn = ESMF_SUCCESS

    CheckError = ESMF_LogFoundError (rcValue, msg=msg, rcToReturn=rcToReturn)

    if (CheckError) then
      print '("error detected at line ", I5, " in file ", A, " - return code = ", I8)', &
        line, file, rcToReturn
      print '("     ", A)', msg
    end if

    return
  !-----------------------------------------------------------------------------
  end function CheckError