|
@@ 1586-1593 (lines=8) @@
|
| 1583 |
|
* |
| 1584 |
|
* @return object|bool The found entity or FALSE. |
| 1585 |
|
*/ |
| 1586 |
|
public function tryGetByIdHash($idHash, $rootClassName) |
| 1587 |
|
{ |
| 1588 |
|
$stringIdHash = (string) $idHash; |
| 1589 |
|
|
| 1590 |
|
return isset($this->identityMap[$rootClassName][$stringIdHash]) |
| 1591 |
|
? $this->identityMap[$rootClassName][$stringIdHash] |
| 1592 |
|
: false; |
| 1593 |
|
} |
| 1594 |
|
|
| 1595 |
|
/** |
| 1596 |
|
* Checks whether an entity is registered in the identity map of this UnitOfWork. |
|
@@ 2967-2974 (lines=8) @@
|
| 2964 |
|
* @return object|bool Returns the entity with the specified identifier if it exists in |
| 2965 |
|
* this UnitOfWork, FALSE otherwise. |
| 2966 |
|
*/ |
| 2967 |
|
public function tryGetById($id, $rootClassName) |
| 2968 |
|
{ |
| 2969 |
|
$idHash = implode(' ', (array) $id); |
| 2970 |
|
|
| 2971 |
|
return isset($this->identityMap[$rootClassName][$idHash]) |
| 2972 |
|
? $this->identityMap[$rootClassName][$idHash] |
| 2973 |
|
: false; |
| 2974 |
|
} |
| 2975 |
|
|
| 2976 |
|
/** |
| 2977 |
|
* Schedules an entity for dirty-checking at commit-time. |