Nodes of different colours represent the following:
Solid arrows point from a parent (sub)module to the submodule which is descended from it. Dashed arrows point from a module being used to the module or program unit using it. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | cDataTypeName | |||
character(len=*), | intent(in) | :: | cUniqueIDName | |||
character(len=*), | intent(in) | :: | cUnits | |||
real(kind=r64), | intent(in), | TARGET | :: | rValue |
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
SUBROUTINE SetupEMSRealInternalVariable(cDataTypeName, cUniqueIDName, cUnits, rValue )
! SUBROUTINE INFORMATION:
! AUTHOR Brent Griffith
! DATE WRITTEN May 2009
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Setup internal data source and make available to EMS
! METHODOLOGY EMPLOYED:
! <description>
! REFERENCES:
! na
! USE STATEMENTS:
USE InputProcessor, ONLY: SameString
USE DataPrecisionGlobals
USE DataRuntimeLanguage
USE DataInterfaces, ONLY :ShowSevereError, ShowContinueError
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
CHARACTER(len=*), INTENT(IN) :: cDataTypeName
CHARACTER(len=*), INTENT(IN) :: cUniqueIDName
CHARACTER(len=*), INTENT(IN) :: cUnits
REAL(r64), TARGET, INTENT(IN) :: rValue
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS:
! na
! DERIVED TYPE DEFINITIONS:
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: InternalVarAvailNum ! loop index
LOGICAL :: FoundInternalDataType
LOGICAL :: FoundDuplicate
TYPE(InternalVarsAvailableType), DIMENSION(:), ALLOCATABLE :: tmpEMSInternalVarsAvailable
FoundInternalDataType = .FALSE.
FoundDuplicate = .FALSE.
DO InternalVarAvailNum = 1, numEMSInternalVarsAvailable
IF ((SameString(cDataTypeName, EMSInternalVarsAvailable(InternalVarAvailNum)%DataTypeName )) &
.AND. (SameString(cUniqueIDName, EMSInternalVarsAvailable(InternalVarAvailNum)%UniqueIDName)) ) THEN
FoundDuplicate = .TRUE.
EXIT
ENDIF
ENDDO
IF (FoundDuplicate) THEN
CALL ShowSevereError('Duplicate internal variable was sent to SetupEMSInternalVariable.')
CALL ShowContinueError('Internal variable type = '//TRIM(cDataTypeName)//' ; name = '//TRIM(cUniqueIDName) )
CALL ShowContinueError('Called from SetupEMSRealInternalVariable.')
ELSE
! add new internal data variable
IF (numEMSInternalVarsAvailable == 0) THEN
ALLOCATE(EMSInternalVarsAvailable(varsAvailableAllocInc))
numEMSInternalVarsAvailable = 1
maxEMSInternalVarsAvailable = varsAvailableAllocInc
ELSE
IF (numEMSInternalVarsAvailable+1 > maxEMSInternalVarsAvailable) THEN
ALLOCATE(tmpEMSInternalVarsAvailable(maxEMSInternalVarsAvailable+varsAvailableAllocInc))
tmpEMSInternalVarsAvailable(1:numEMSInternalVarsAvailable) = EMSInternalVarsAvailable(1:numEMSInternalVarsAvailable)
DEALLOCATE(EMSInternalVarsAvailable)
ALLOCATE(EMSInternalVarsAvailable(maxEMSInternalVarsAvailable+varsAvailableAllocInc))
EMSInternalVarsAvailable(1:numEMSInternalVarsAvailable) = tmpEMSInternalVarsAvailable(1:numEMSInternalVarsAvailable)
DEALLOCATE(tmpEMSInternalVarsAvailable)
maxEMSInternalVarsAvailable=maxEMSInternalVarsAvailable+varsAvailableAllocInc
ENDIF
numEMSInternalVarsAvailable = numEMSInternalVarsAvailable + 1
ENDIF
InternalVarAvailNum = numEMSInternalVarsAvailable
EMSInternalVarsAvailable(InternalVarAvailNum)%DataTypeName = cDataTypeName
EMSInternalVarsAvailable(InternalVarAvailNum)%UniqueIDName = cUniqueIDName
EMSInternalVarsAvailable(InternalVarAvailNum)%Units = cUnits
EMSInternalVarsAvailable(InternalVarAvailNum)%RealValue => rValue
EMSInternalVarsAvailable(InternalVarAvailNum)%PntrVarTypeUsed = PntrReal
ENDIF
RETURN
END SUBROUTINE SetupEMSRealInternalVariable