ESMF_LocStreamGetBounds Subroutine

public subroutine ESMF_LocStreamGetBounds(locstream, keywordEnforcer, localDE, exclusiveLBound, exclusiveUBound, exclusiveCount, computationalLBound, computationalUBound, computationalCount, rc)

Arguments

Type IntentOptional Attributes Name
type(ESMF_LocStream), intent(in) :: locstream
type(ESMF_KeywordEnforcer), optional :: keywordEnforcer
integer, intent(in), optional :: localDE
integer, intent(out), optional :: exclusiveLBound
integer, intent(out), optional :: exclusiveUBound
integer, intent(out), optional :: exclusiveCount
integer, intent(out), optional :: computationalLBound
integer, intent(out), optional :: computationalUBound
integer, intent(out), optional :: computationalCount
integer, intent(out), optional :: rc

Calls

proc~~esmf_locstreamgetbounds~~CallsGraph proc~esmf_locstreamgetbounds ESMF_LocStreamGetBounds c_esmc_locstreamgetelbnd c_esmc_locstreamgetelbnd proc~esmf_locstreamgetbounds->c_esmc_locstreamgetelbnd c_esmc_locstreamgeteubnd c_esmc_locstreamgeteubnd proc~esmf_locstreamgetbounds->c_esmc_locstreamgeteubnd proc~esmf_imerr ESMF_IMErr proc~esmf_locstreamgetbounds->proc~esmf_imerr proc~esmf_locstreamgetinit ESMF_LocStreamGetInit proc~esmf_locstreamgetbounds->proc~esmf_locstreamgetinit proc~esmf_logfounderror ESMF_LogFoundError proc~esmf_locstreamgetbounds->proc~esmf_logfounderror proc~esmf_imerr->proc~esmf_logfounderror proc~esmf_initcheckdeep ESMF_InitCheckDeep proc~esmf_imerr->proc~esmf_initcheckdeep 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~~esmf_locstreamgetbounds~~CalledByGraph proc~esmf_locstreamgetbounds ESMF_LocStreamGetBounds proc~esmf_geomgetplocalde ESMF_GeomGetPLocalDe proc~esmf_geomgetplocalde->proc~esmf_locstreamgetbounds proc~esmf_pointlistcreatefrmlocstream ESMF_PointListCreateFrmLocStream proc~esmf_pointlistcreatefrmlocstream->proc~esmf_locstreamgetbounds interface~esmf_pointlistcreate ESMF_PointListCreate proc~esmf_pointlistcreatefrmlocstream->interface~esmf_pointlistcreate proc~f_esmf_locstreamgetbounds f_esmf_locstreamgetbounds proc~f_esmf_locstreamgetbounds->proc~esmf_locstreamgetbounds proc~test_regridgridtolocstreamregdist test_regridGridToLocStreamRegDist proc~test_regridgridtolocstreamregdist->proc~esmf_locstreamgetbounds proc~test_regridnearestlocstreamtogrid test_regridNearestLocStreamToGrid proc~test_regridnearestlocstreamtogrid->proc~esmf_locstreamgetbounds program~esmf_locstreamcreateutest ESMF_LocStreamCreateUTest program~esmf_locstreamcreateutest->proc~esmf_locstreamgetbounds interface~esmf_pointlistcreate->proc~esmf_pointlistcreatefrmlocstream proc~esmf_fieldgetgballocbounds ESMF_FieldGetGBAllocBounds proc~esmf_fieldgetgballocbounds->proc~esmf_geomgetplocalde proc~esmf_fieldvalidate ESMF_FieldValidate proc~esmf_fieldvalidate->proc~esmf_geomgetplocalde proc~esmf_gridgetfieldbounds ESMF_GridGetFieldBounds proc~esmf_gridgetfieldbounds->proc~esmf_fieldgetgballocbounds proc~esmf_locstreamgetfieldbounds ESMF_LocStreamGetFieldBounds proc~esmf_locstreamgetfieldbounds->proc~esmf_fieldgetgballocbounds proc~esmf_meshgetfieldbounds ESMF_MeshGetFieldBounds proc~esmf_meshgetfieldbounds->proc~esmf_fieldgetgballocbounds proc~esmf_statevalidate ESMF_StateValidate proc~esmf_statevalidate->proc~esmf_fieldvalidate proc~esmf_xgridgetfieldbounds ESMF_XGridGetFieldBounds proc~esmf_xgridgetfieldbounds->proc~esmf_fieldgetgballocbounds proc~getpointlistonfieldloc getPointListOnFieldLoc proc~getpointlistonfieldloc->interface~esmf_pointlistcreate proc~test7d4_generic test7d4_generic proc~test7d4_generic->proc~esmf_fieldvalidate proc~test_mesh_create_gt_1localde test_mesh_create_gt_1localde proc~test_mesh_create_gt_1localde->proc~esmf_fieldvalidate proc~test_pointlist_from_grid_nomask test_pointlist_from_grid_nomask proc~test_pointlist_from_grid_nomask->interface~esmf_pointlistcreate proc~test_pointlist_from_grid_wmask test_pointlist_from_grid_wmask proc~test_pointlist_from_grid_wmask->interface~esmf_pointlistcreate proc~test_pointlist_from_inputs test_pointlist_from_inputs proc~test_pointlist_from_inputs->interface~esmf_pointlistcreate proc~test_pointlist_from_locstream_nomask test_pointlist_from_locStream_nomask proc~test_pointlist_from_locstream_nomask->interface~esmf_pointlistcreate proc~test_pointlist_from_locstream_wmask test_pointlist_from_locStream_wmask proc~test_pointlist_from_locstream_wmask->interface~esmf_pointlistcreate proc~test_pointlist_from_mesh_elems_nomask test_pointlist_from_mesh_elems_nomask proc~test_pointlist_from_mesh_elems_nomask->interface~esmf_pointlistcreate proc~test_pointlist_from_mesh_elems_wmask test_pointlist_from_mesh_elems_wmask proc~test_pointlist_from_mesh_elems_wmask->interface~esmf_pointlistcreate proc~test_pointlist_from_mesh_nodes_nomask test_pointlist_from_mesh_nodes_nomask proc~test_pointlist_from_mesh_nodes_nomask->interface~esmf_pointlistcreate proc~test_pointlist_from_mesh_nodes_nomask_empty_proc test_pointlist_from_mesh_nodes_nomask_empty_proc proc~test_pointlist_from_mesh_nodes_nomask_empty_proc->interface~esmf_pointlistcreate proc~test_pointlist_from_mesh_nodes_wmask test_pointlist_from_mesh_nodes_wmask proc~test_pointlist_from_mesh_nodes_wmask->interface~esmf_pointlistcreate program~esmf_meshutest ESMF_MeshUTest program~esmf_meshutest->proc~esmf_fieldvalidate

Source Code

      subroutine ESMF_LocStreamGetBounds(locstream, keywordEnforcer,   &
          localDE, exclusiveLBound, exclusiveUBound, exclusiveCount,   &
          computationalLBound, computationalUBound, computationalCount,&
          rc)
!
! !ARGUMENTS:
      type(ESMF_LocStream),   intent(in) :: locstream
type(ESMF_KeywordEnforcer), optional:: keywordEnforcer ! must use keywords below
      integer,                intent(in),  optional :: localDE
      integer,                intent(out), optional :: exclusiveLBound
      integer,                intent(out), optional :: exclusiveUBound
      integer,                intent(out), optional :: exclusiveCount
      integer,                intent(out), optional :: computationalLBound
      integer,                intent(out), optional :: computationalUBound
      integer,                intent(out), optional :: computationalCount
      integer, intent(out), optional :: rc
!
! !DESCRIPTION:
!    This method gets the bounds of a localDE for a locstream.
!
!     The arguments are:
!     \begin{description}
!     \item[{locstream}]
!          LocStream to get the information from.
!     \item[{localDE}]
!         The local DE for which information is requested. {\tt [0,..,localDECount-1]}.
!         For {\tt localDECount==1} the {\tt localDE} argument may be omitted,
!          in which case it will default to {\tt localDE=0}.
!     \item[{[exclusiveLBound]}]
!          Upon return this holds the lower bounds of the exclusive region.
!     \item[{[exclusiveUBound]}]
!          Upon return this holds the upper bounds of the exclusive region.
!     \item[{[exclusiveCount]}]
 !          Upon return this holds the number of items in the exclusive region
!     \newline
!          (i.e. {\tt exclusiveUBound-exclusiveLBound+1}). {\tt exclusiveCount}.
!     \item[{[computationalLBound]}]
!          Upon return this holds the lower bounds of the computational region.
!     \item[{[computationalUBound]}]
!          Upon return this holds the upper bounds of the computational region.
!     \item[{[computationalCount]}]
!          Upon return this holds the number of items in the computational region
!     \newline
!          (i.e. {\tt computationalUBound-computationalLBound+1}). {\tt computationalCount}.
!     \item[{[rc]}]
!          Return code; equals {\tt ESMF\_SUCCESS} if there are no errors.
!   \end{description}
!
!EOP

 integer :: localrc
 integer :: tmpLBnd, tmpUBnd
 type(ESMF_LocStreamType), pointer :: lstypep

 ! Initialize return code 
 localrc = ESMF_RC_NOT_IMPL 
 if (present(rc)) rc = ESMF_RC_NOT_IMPL 

 ! Check init status of arguments 
 ESMF_INIT_CHECK_DEEP(ESMF_LocStreamGetInit, locstream, rc) 

 ! Get locstream type object
 lstypep=>locstream%lstypep

 ! Get exclusiveLBound
 if (present(exclusiveLBound)) then
    call c_ESMC_locstreamgetelbnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             exclusiveLBound, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return
 endif 

 ! Get exclusiveUBound
 if (present(exclusiveUBound)) then
    call c_ESMC_locstreamgeteubnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
              exclusiveUBound, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return
 endif 

 ! Get exclusiveCount
 if (present(exclusiveCount)) then
    call c_ESMC_locstreamgetelbnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             tmpLBnd, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return

    call c_ESMC_locstreamgeteubnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             tmpUBnd, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return

    exclusiveCount=tmpUBnd-tmpLBnd+1
 endif 

 ! For now computational bounds are the same as exclusive bounds

 ! Get computationalLBound
 if (present(computationalLBound)) then
    call c_ESMC_locstreamgetelbnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             computationalLBound, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return
 endif 

 ! Get computationalUBound
 if (present(computationalUBound)) then
    call c_ESMC_locstreamgeteubnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             computationalUBound, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return
 endif 

 ! Get computationalCount
 if (present(computationalCount)) then
    call c_ESMC_locstreamgetelbnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             tmpLBnd, localrc)
     if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return

    call c_ESMC_locstreamgeteubnd(lstypep%distgrid, localDE, lstypep%indexflag, & 
             tmpUBnd, localrc)
    if (ESMF_LogFoundError(localrc, ESMF_ERR_PASSTHRU, & 
            ESMF_CONTEXT, rcToReturn=rc)) return

    computationalCount=tmpUBnd-tmpLBnd+1
 endif 

 ! Return successfully 
 if (present(rc)) rc = ESMF_SUCCESS 

end subroutine ESMF_LocStreamGetBounds