public function serialize($value): string
    {
        $id = $this->entityManager->getClassMetadata($this->className)->getIdentifierValues($value);

        return (string) reset($id);
    }
public function serialize($value): string
    {
        $id = $this->entityManager->getClassMetadata($this->className)->getIdentifierValues($value);

        return (string) reset($id);
    }
public function serialize ( $ value ) : string { $ id = $ this -> entityManager -> getClassMetadata ( $ this -> className ) -> getIdentifierValues ( $ value ) ; return ( string ) reset ( $ id ) ; }
Serializes an internal value to include in a response.

@param mixed $value

@return string
Serializes an internal value to include in a response .