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) | :: | CompType | |||
character(len=*), | intent(in) | :: | CompName | |||
logical, | intent(out) | :: | IsNotOK | |||
character(len=*), | intent(in) | :: | CallString |
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.
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 ValidateComponent(CompType,CompName,IsNotOK,CallString)
! SUBROUTINE INFORMATION:
! AUTHOR Linda Lawrie
! DATE WRITTEN October 2002
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! This subroutine can be called to validate the component type-name pairs that
! are so much a part of the EnergyPlus input. The main drawback to this validation
! has been that the "GetInput" routine may not have been called and/or exists in
! another module from the one with the list. This means that validation must be
! done later, perhaps after simulation has already started or perhaps raises an
! array bound error instead.
! METHODOLOGY EMPLOYED:
! Uses existing routines in InputProcessor. GetObjectItemNum uses the "standard"
! convention of the Name of the item/object being the first Alpha Argument.
! REFERENCES:
! na
! USE STATEMENTS:
USE InputProcessor, ONLY: GetObjectItemNum
USE DataInterfaces, ONLY: ShowSevereError, ShowContinueError
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
CHARACTER(len=*), INTENT(IN) :: CompType ! Component Type (e.g. Chiller:Electric)
CHARACTER(len=*), INTENT(IN) :: CompName ! Component Name (e.g. Big Chiller)
LOGICAL, INTENT(OUT) :: IsNotOK ! .true. if this component pair is invalid
CHARACTER(len=*), INTENT(IN) :: CallString ! Context of this pair -- for error message
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: ItemNum
IsNotOK=.false.
ItemNum=GetObjectItemNum(CompType,CompName)
IF (ItemNum < 0) THEN
CALL ShowSevereError('During '//TRIM(CallString)//' Input, Invalid Component Type input='//TRIM(CompType))
CALL ShowContinueError('Component name='//TRIM(CompName))
IsNotOK=.true.
ELSEIF (ItemNum == 0) THEN
CALL ShowSevereError('During '//TRIM(CallString)//' Input, Invalid Component Name input='//TRIM(CompName))
CALL ShowContinueError('Component type='//TRIM(CompType))
IsNotOK=.true.
ENDIF
RETURN
END SUBROUTINE ValidateComponent