Converts the given object into an array containing the identity of the domain object.
public convertObjectToIdentityArray ( object $object ) : array | ||
$object | object | The object to be converted |
return | array | The identity array in the format array('__identity' => '...') |
/** * @test * @expectedException \Neos\Flow\Persistence\Exception\UnknownObjectException */ public function convertObjectToIdentityArrayThrowsExceptionIfIdentityForTheGivenObjectCantBeDetermined() { $someObject = new \stdClass(); $this->abstractPersistenceManager->expects($this->once())->method('getIdentifierByObject')->with($someObject)->will($this->returnValue(null)); $this->abstractPersistenceManager->convertObjectToIdentityArray($someObject); }