Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ESMF_FieldBundle), | intent(in) | :: | object | |||
type(ESMF_KeywordEnforcer), | optional | :: | keywordEnforcer | |||
character(len=*), | intent(in), | optional | :: | name | ||
integer, | intent(out), | optional | :: | rc |
function ESMF_NamedAliasFieldBundle(object, keywordEnforcer, name, rc) ! ! !RETURN VALUE: type(ESMF_FieldBundle) :: ESMF_NamedAliasFieldBundle ! ! !ARGUMENTS: type(ESMF_FieldBundle),intent(in) :: object type(ESMF_KeywordEnforcer), optional:: keywordEnforcer ! must use keywords below character(len = *), intent(in), optional :: name integer, intent(out), optional :: rc !EOPI !------------------------------------------------------------------------------ integer :: localrc character(ESMF_MAXSTR) :: nameDefault if (present(rc)) rc = ESMF_SUCCESS ! first create regular alias ESMF_NamedAliasFieldBundle = object ! next mark as namedAlias ESMF_NamedAliasFieldBundle%isNamedAlias = .true. ! finally set name if (present(name)) then ESMF_NamedAliasFieldBundle%name = trim(name) else call ESMF_FieldBundleGet(object, name=nameDefault, rc=localrc) if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & ESMF_CONTEXT, rcToReturn=rc)) return ESMF_NamedAliasFieldBundle%name = trim(nameDefault) endif end function ESMF_NamedAliasFieldBundle