public function testEmptyStringFromString() { $s = Entitlement::fromString(""); $this->assertTrue($s->isEmpty()); }
/** * OPTIONAL|NON-STANDARD. A space-separated list of strings representing * the entitlements associated with this token, in the format described in * Section 3.3 of OAuth 2.0 [RFC6749]. * * @return fkooman\OAuth\Common\Entitlement */ public function getEntitlement() { if (null === $this->getKeyValue('x-entitlement')) { return new Entitlement(); } return Entitlement::fromString($this->getKeyValue('x-entitlement')); }