Tobscure\JsonApi\SerializerInterface::getId PHP Méthode

getId() public méthode

Get the id.
public getId ( mixed $model ) : string
$model mixed
Résultat string
    public function getId($model);

Usage Example

Exemple #1
0
 /**
  * Get the resource ID.
  *
  * @return string
  */
 public function getId()
 {
     if (!is_object($this->data) && !is_array($this->data)) {
         return (string) $this->data;
     }
     return (string) $this->serializer->getId($this->data);
 }