src/wcmf/lib/persistence/impl/RemoteCapablePersistenceFacade.php
protected function getRegisteredObject(ObjectId $umi, $buildDepth, $varName) {
    if ($buildDepth == 0) {
      $buildDepth=BuildDepth::SINGLE;
    }
    $umiStr = $umi->toString();
    $objects = $this->session->get($varName);
    if (isset($objects[$umiStr]) && isset($objects[$umiStr][$buildDepth])) {
      return $objects[$umiStr][$buildDepth];
    }
    // check if an object with larger build depth was stored already
    if ($buildDepth == BuildDepth::SINGLE) {
      $existingDepths = array_keys($objects[$umiStr]);
      foreach($existingDepths as $depth) {
        if ($depth > 0 || $depth == BuildDepth::INFINITE) {
          return $objects[$umiStr][$depth];
        }
      }
    }
    return null;
  }
protected function getRegisteredObject(ObjectId $umi, $buildDepth, $varName) {
    if ($buildDepth == 0) {
      $buildDepth=BuildDepth::SINGLE;
    }
    $umiStr = $umi->toString();
    $objects = $this->session->get($varName);
    if (isset($objects[$umiStr]) && isset($objects[$umiStr][$buildDepth])) {
      return $objects[$umiStr][$buildDepth];
    }
    // check if an object with larger build depth was stored already
    if ($buildDepth == BuildDepth::SINGLE) {
      $existingDepths = array_keys($objects[$umiStr]);
      foreach($existingDepths as $depth) {
        if ($depth > 0 || $depth == BuildDepth::INFINITE) {
          return $objects[$umiStr][$depth];
        }
      }
    }
    return null;
  }
protected function getRegisteredObject ( ObjectId $ umi , $ buildDepth , $ varName ) { if ( $ buildDepth == 0 ) { $ buildDepth = BuildDepth :: SINGLE ; } $ umiStr = $ umi -> toString ( ) ; $ objects = $ this -> session -> get ( $ varName ) ; if ( isset ( $ objects [ $ umiStr ] ) && isset ( $ objects [ $ umiStr ] [ $ buildDepth ] ) ) { return $ objects [ $ umiStr ] [ $ buildDepth ] ; } // check if an object with larger build depth was stored already if ( $ buildDepth == BuildDepth :: SINGLE ) { $ existingDepths = array_keys ( $ objects [ $ umiStr ] ) ; foreach ( $ existingDepths as $ depth ) { if ( $ depth > 0 || $ depth == BuildDepth :: INFINITE ) { return $ objects [ $ umiStr ] [ $ depth ] ; } } } return null ; }
Get a object from the given session variable.
@param $umi The universal model id (oid with server prefix)
@param $buildDepth The requested build depth.
@param $varName The session variable name
@return The object or null if not found.
Get a object from the given session variable .