ESMF_LogErrMod Module



Variables

Type Visibility Attributes Name Initial
character(len=8), private, parameter :: ESMF_LogMsgString(6) = (/'INFO    ', 'WARNING ', 'ERROR   ', 'TRACE   ', 'DEBUG   ', 'JSON    '/)
integer, private, SAVE :: ESMF_LogTableCount = 0
integer, private, parameter :: ESMF_LogTableMax = 1000
integer, private :: i_ac
type(ESMF_Log), private, SAVE, target :: ESMF_LogDefault
type(ESMF_LogKind_Flag), public, parameter :: ESMF_LOGKIND_MULTI = ESMF_LogKind_Flag(2)
type(ESMF_LogKind_Flag), public, parameter :: ESMF_LOGKIND_MULTI_ON_ERROR = ESMF_LogKind_Flag(3)
type(ESMF_LogKind_Flag), public, parameter :: ESMF_LOGKIND_NONE = ESMF_LogKind_Flag(4)
type(ESMF_LogKind_Flag), public, parameter :: ESMF_LOGKIND_SINGLE = ESMF_LogKind_Flag(1)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_ALL(6) = (/ESMF_LOGMSG_INFO, ESMF_LOGMSG_WARNING, ESMF_LOGMSG_ERROR, ESMF_LOGMSG_TRACE, ESMF_LOGMSG_DEBUG, ESMF_LOGMSG_JSON/)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_DEBUG = ESMF_LogMsg_Flag(5)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_ERROR = ESMF_LogMsg_Flag(3)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_INFO = ESMF_LogMsg_Flag(1)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_JSON = ESMF_LogMsg_Flag(6)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_NONE(0) = (/(ESMF_LogMsg_Flag(0), i_ac=1, 0)/)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_NOTRACE(5) = (/ESMF_LOGMSG_INFO, ESMF_LOGMSG_WARNING, ESMF_LOGMSG_ERROR, ESMF_LOGMSG_DEBUG, ESMF_LOGMSG_JSON/)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_TRACE = ESMF_LogMsg_Flag(4)
type(ESMF_LogMsg_Flag), public, parameter :: ESMF_LOGMSG_WARNING = ESMF_LogMsg_Flag(2)
type(ESMF_LogPrivate), private, SAVE, target :: ESMF_LogTable(ESMF_LogTableMax)

Interfaces

private interface ESMF_LogOpen

  • private interface ESMF_LogOpen()

    Arguments

    None
  • private subroutine ESMF_LogOpenDefault(filename, keywordEnforcer, appendflag, logkindflag, rc)

    Arguments

    Type IntentOptional Attributes Name
    character(len=*), intent(in) :: filename
    type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
    logical, intent(in), optional :: appendflag
    type(ESMF_LogKind_Flag), intent(in), optional :: logkindflag
    integer, intent(out), optional :: rc

private interface operator (/=)

  • private impure elemental function ESMF_LogNE(log1, log2)

    Arguments

    Type IntentOptional Attributes Name
    type(ESMF_Log), intent(in) :: log1
    type(ESMF_Log), intent(in) :: log2

    Return Value logical

  • private impure elemental function ESMF_lltne(lt1, lt2)

    Arguments

    Type IntentOptional Attributes Name
    type(ESMF_LogKind_Flag), intent(in) :: lt1
    type(ESMF_LogKind_Flag), intent(in) :: lt2

    Return Value logical

private interface operator (==)

  • private impure elemental function ESMF_LogEQ(log1, log2)

    Arguments

    Type IntentOptional Attributes Name
    type(ESMF_Log), intent(in) :: log1
    type(ESMF_Log), intent(in) :: log2

    Return Value logical

  • private impure elemental function ESMF_lmteq(mt1, mt2)

    Arguments

    Type IntentOptional Attributes Name
    type(ESMF_LogMsg_Flag), intent(in) :: mt1
    type(ESMF_LogMsg_Flag), intent(in) :: mt2

    Return Value logical

  • private impure elemental function ESMF_llteq(lt1, lt2)

    Arguments

    Type IntentOptional Attributes Name
    type(ESMF_LogKind_Flag), intent(in) :: lt1
    type(ESMF_LogKind_Flag), intent(in) :: lt2

    Return Value logical

private interface operator (>)


Derived Types

type, public, sequence  ::  ESMF_Log

Components

Type Visibility Attributes Name Initial
integer(kind=ESMF_KIND_I8), private :: isInit = 76838410
integer, private :: logTableIndex = 0

type, private, sequence  ::  ESMF_LogEntry

Components

Type Visibility Attributes Name Initial
character(len=1), private, pointer :: msg(:)
character(len=16), private :: lt
character(len=32), private :: method
character(len=8), private :: d
character(len=ESMF_MAXPATHLEN), private :: file
integer(kind=ESMF_KIND_I8), private :: isInit = 76838410
integer, private :: h
integer, private :: indentCount
integer, private :: line
integer, private :: m
integer, private :: ms
integer, private :: s
logical, private :: fileflag
logical, private :: highResTimestampFlag
logical, private :: lineflag
logical, private :: methodflag
logical, private :: noprefix
real(kind=ESMF_KIND_R8), private :: highResTimestamp

type, public, sequence  ::  ESMF_LogKind_Flag

Components

Type Visibility Attributes Name Initial
integer, public :: ftype

type, public, sequence  ::  ESMF_LogMsg_Flag

Components

Type Visibility Attributes Name Initial
integer, public :: mtype

type, private, sequence  ::  ESMF_LogPrivate

Components

Type Visibility Attributes Name Initial
character(len=ESMF_MAXPATHLEN), private :: nameLogErrFile
character(len=ESMF_MAXSTR), private :: petNumLabel
integer(kind=ESMF_KIND_I8), private :: isInit = 76838410
integer, private, pointer :: errorMask(:) => null()
integer, private :: errorMaskCount = 0
integer, private :: fIndex
integer, private :: indentCount = 0
integer, private :: maxElements
integer, private :: petNumber
integer, private :: unitNumber
logical, private :: appendFlag = .true.
logical, private :: deferredOpenFlag = .false.
logical, private :: highResTimestampFlag = .false.
logical, private :: noprefix = .false.
logical, private :: pad
logical, private :: stopprogram
logical, private :: traceFlag = .false.
type(ESMF_LogEntry), private, dimension(:), pointer :: LOG_ENTRY => null()
type(ESMF_LogKind_Flag), private :: logkindflag
type(ESMF_LogMsg_Flag), private, pointer :: logmsgAbort(:) => null()
type(ESMF_LogMsg_Flag), private, pointer :: logmsgList(:) => null()
type(ESMF_Logical), private :: FileIsOpen = ESMF_FALSE
type(ESMF_Logical), private :: dirty
type(ESMF_Logical), private :: flushImmediately
type(ESMF_Logical), private :: flushed

Functions

private function ESMF_LogEntryGetInit(s)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogEntry), intent(in), optional :: s

Return Value integer(kind=ESMF_KIND_I8)

public function ESMF_LogGetInit(s)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(in), optional :: s

Return Value integer(kind=ESMF_KIND_I8)

private function ESMF_LogPrivateGetInit(s)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogPrivate), intent(in), optional :: s

Return Value integer(kind=ESMF_KIND_I8)

private impure elemental function ESMF_LogEQ(log1, log2)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(in) :: log1
type(ESMF_Log), intent(in) :: log2

Return Value logical

public function ESMF_LogFoundAllocError(statusToCheck, keywordEnforcer, msg, line, file, method, rcToReturn, log)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: statusToCheck
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
character(len=*), intent(in), optional :: msg
integer, intent(in), optional :: line
character(len=*), intent(in), optional :: file
character(len=*), intent(in), optional :: method
integer, intent(inout), optional :: rcToReturn
type(ESMF_Log), intent(inout), optional :: log

Return Value logical

public function ESMF_LogFoundDeallocError(statusToCheck, keywordEnforcer, msg, line, file, method, rcToReturn, log)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: statusToCheck
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
character(len=*), intent(in), optional :: msg
integer, intent(in), optional :: line
character(len=*), intent(in), optional :: file
character(len=*), intent(in), optional :: method
integer, intent(inout), optional :: rcToReturn
type(ESMF_Log), intent(inout), optional :: log

Return Value logical

public recursive function ESMF_LogFoundError(rcToCheck, keywordEnforcer, msg, line, file, method, rcToReturn, log) result(LogFoundError)

Arguments

Type IntentOptional Attributes Name
integer, intent(in), optional :: rcToCheck
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
character(len=*), intent(in), optional :: msg
integer, intent(in), optional :: line
character(len=*), intent(in), optional :: file
character(len=*), intent(in), optional :: method
integer, intent(inout), optional :: rcToReturn
type(ESMF_Log), intent(inout), optional :: log

Return Value logical

public function ESMF_LogFoundNetCDFError(ncerrToCheck, keywordEnforcer, msg, line, file, method, rcToReturn, log)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: ncerrToCheck
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
character(len=*), intent(in), optional :: msg
integer, intent(in), optional :: line
character(len=*), intent(in), optional :: file
character(len=*), intent(in), optional :: method
integer, intent(inout), optional :: rcToReturn
type(ESMF_Log), intent(inout), optional :: log

Return Value logical

private impure elemental function ESMF_LogNE(log1, log2)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(in) :: log1
type(ESMF_Log), intent(in) :: log2

Return Value logical

private impure elemental function ESMF_llteq(lt1, lt2)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogKind_Flag), intent(in) :: lt1
type(ESMF_LogKind_Flag), intent(in) :: lt2

Return Value logical

private impure elemental function ESMF_lltne(lt1, lt2)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogKind_Flag), intent(in) :: lt1
type(ESMF_LogKind_Flag), intent(in) :: lt2

Return Value logical

private impure elemental function ESMF_lmteq(mt1, mt2)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogMsg_Flag), intent(in) :: mt1
type(ESMF_LogMsg_Flag), intent(in) :: mt2

Return Value logical

private function ESMF_lmtgt(mt1, mt2)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogMsg_Flag), intent(in) :: mt1
type(ESMF_LogMsg_Flag), intent(in) :: mt2

Return Value logical


Subroutines

public subroutine ESMF_LogClose(log, keywordEnforcer, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(inout), optional :: log
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
integer, intent(out), optional :: rc

private subroutine ESMF_LogEntryCopy(logEntryIn, logEntryOut, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogEntry), intent(inout) :: logEntryIn
type(ESMF_LogEntry), intent(out) :: logEntryOut
integer, intent(out), optional :: rc

private subroutine ESMF_LogEntryInit(s)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogEntry) :: s

private subroutine ESMF_LogEntryValidate(s, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogEntry), intent(inout) :: s
integer, intent(out), optional :: rc

public subroutine ESMF_LogFinalize(rc)

Arguments

Type IntentOptional Attributes Name
integer, intent(out), optional :: rc

public subroutine ESMF_LogFlush(log, keywordEnforcer, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(inout), optional :: log
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
integer, intent(out), optional :: rc

public subroutine ESMF_LogGet(log, keywordEnforcer, flush, logmsgAbort, logkindflag, maxElements, trace, fileName, highResTimestampFlag, indentCount, noPrefix, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(in), optional :: log
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
logical, intent(out), optional :: flush
type(ESMF_LogMsg_Flag), optional, pointer :: logmsgAbort(:)
type(ESMF_LogKind_Flag), intent(out), optional :: logkindflag
integer, intent(out), optional :: maxElements
logical, intent(out), optional :: trace
character(len=*), intent(out), optional :: fileName
logical, intent(out), optional :: highResTimestampFlag
integer, intent(out), optional :: indentCount
logical, intent(out), optional :: noPrefix
integer, intent(out), optional :: rc

public subroutine ESMF_LogInit(s)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log) :: s

public subroutine ESMF_LogInitialize(filename, logappendflag, logkindflag, rc)

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: filename
logical, intent(in), optional :: logappendflag
type(ESMF_LogKind_Flag), intent(in), optional :: logkindflag
integer, intent(out), optional :: rc

public subroutine ESMF_LogOpen(log, filename, keywordEnforcer, appendFlag, logkindFlag, noPrefix, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(inout) :: log
character(len=*), intent(in) :: filename
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
logical, intent(in), optional :: appendFlag
type(ESMF_LogKind_Flag), intent(in), optional :: logkindFlag
logical, intent(in), optional :: noPrefix
integer, intent(out), optional :: rc

private subroutine ESMF_LogOpenDefault(filename, keywordEnforcer, appendflag, logkindflag, rc)

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: filename
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
logical, intent(in), optional :: appendflag
type(ESMF_LogKind_Flag), intent(in), optional :: logkindflag
integer, intent(out), optional :: rc

private subroutine ESMF_LogOpenFile(alog, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogPrivate), intent(inout) :: alog
integer, intent(out) :: rc

private subroutine ESMF_LogPrivateInit(s)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogPrivate) :: s

private subroutine ESMF_LogPrivateValidate(s, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LogPrivate), intent(inout) :: s
integer, intent(out), optional :: rc

public subroutine ESMF_LogRc2Msg(rcToCheck, msg, msglen)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: rcToCheck
character(len=*), intent(out) :: msg
integer, intent(out) :: msglen

public subroutine ESMF_LogSet(log, keywordEnforcer, flush, logmsgAbort, maxElements, logmsgList, errorMask, trace, highResTimestampFlag, indentCount, noPrefix, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(inout), optional :: log
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
logical, intent(in), optional :: flush
type(ESMF_LogMsg_Flag), intent(in), optional :: logmsgAbort(:)
integer, intent(in), optional :: maxElements
type(ESMF_LogMsg_Flag), intent(in), optional :: logmsgList(:)
integer, intent(in), optional :: errorMask(:)
logical, intent(in), optional :: trace
logical, intent(in), optional :: highResTimestampFlag
integer, intent(in), optional :: indentCount
logical, intent(in), optional :: noPrefix
integer, intent(out), optional :: rc

public subroutine ESMF_LogSetError(rcToCheck, keywordEnforcer, msg, line, file, method, rcToReturn, log)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: rcToCheck
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
character(len=*), intent(in), optional :: msg
integer, intent(in), optional :: line
character(len=*), intent(in), optional :: file
character(len=*), intent(in), optional :: method
integer, intent(out), optional :: rcToReturn
type(ESMF_Log), intent(inout), optional :: log

public subroutine ESMF_LogValidate(s, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_Log), intent(inout) :: s
integer, intent(out), optional :: rc

public recursive subroutine ESMF_LogWrite(msg, logmsgFlag, logmsgList, keywordEnforcer, line, file, method, log, rc)

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: msg
type(ESMF_LogMsg_Flag), intent(in), optional :: logmsgFlag
type(ESMF_LogMsg_Flag), intent(in), optional :: logmsgList
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
integer, intent(in), optional :: line
character(len=*), intent(in), optional :: file
character(len=*), intent(in), optional :: method
type(ESMF_Log), intent(inout), optional :: log
integer, intent(out), optional :: rc