Neos\Flow\Security\Policy\Role::getIdentifier PHP Method

getIdentifier() public method

Returns the fully qualified identifier of this role
public getIdentifier ( ) : string
return string
    public function getIdentifier()
    {
        return $this->identifier;
    }

Usage Example

コード例 #1
0
 /**
  * @test
  */
 public function setRolesWorks()
 {
     $roles = [$this->administratorRole, $this->customerRole];
     $expectedRoles = [$this->administratorRole->getIdentifier() => $this->administratorRole, $this->customerRole->getIdentifier() => $this->customerRole];
     $this->account->setRoles($roles);
     $this->assertSame($expectedRoles, $this->account->getRoles());
 }
All Usage Examples Of Neos\Flow\Security\Policy\Role::getIdentifier