mapRoles() 공개 메소드

Map data for a set of roles.
public mapRoles ( array $data ) : eZ\Publish\SPI\Persistence\User\Role[]
$data array
리턴 eZ\Publish\SPI\Persistence\User\Role[]
예제 #1
0
 /**
  * Loads all roles.
  *
  * @return \eZ\Publish\SPI\Persistence\User\Role[]
  */
 public function loadRoles()
 {
     $data = $this->roleGateway->loadRoles();
     $roles = $this->mapper->mapRoles($data);
     foreach ($roles as $role) {
         foreach ($role->policies as $policy) {
             $this->limitationConverter->toSPI($policy);
         }
     }
     return $roles;
 }