Neomerx\JsonApi\Contracts\Document\LinkInterface::isTreatAsHref PHP Method

isTreatAsHref() public method

If $subHref is a full URL and must not be concatenated with other URLs.
public isTreatAsHref ( ) : boolean
return boolean
    public function isTreatAsHref();

Usage Example

Beispiel #1
0
 /**
  * @param string|null        $prefix
  * @param LinkInterface|null $link
  *
  * @return array|null|string
  */
 private function getLinkRepresentation($prefix = null, LinkInterface $link = null)
 {
     return $link === null ? null : $this->getUrlRepresentation($link->isTreatAsHref() === true ? $link->getSubHref() : $prefix . $link->getSubHref(), $link->getMeta());
 }