mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2026-03-17 19:28:06 +00:00
The `chill.role` tag has been renamed to `chill_main.provide_role` to prevent any confusion and make the namespaces more consistent. During this process, the class RoleProvidersCompilerPass was deleted, simplifying the role provision process by injecting tagged services directly into the RoleProvider. The change is also reflected in multiple YAML service configurations and explained in the MIGRATION.md file.
46 lines
988 B
PHP
46 lines
988 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
/*
|
|
* Chill is a software for social workers
|
|
*
|
|
* For the full copyright and license information, please view
|
|
* the LICENSE file that was distributed with this source code.
|
|
*/
|
|
|
|
namespace Chill\MainBundle\Security;
|
|
|
|
/**
|
|
* Declare role.
|
|
*
|
|
* The role are added to the configuration at compile time.
|
|
*
|
|
* The implemented object must be declared as a service and tagged as
|
|
*
|
|
* <pre>
|
|
* my_role_declaration:
|
|
* # ...
|
|
* tags:
|
|
* - { name: chill_main.provide_role }
|
|
* </pre>
|
|
*
|
|
* This tag is also automatically added using dependency injection autoconfiguration.
|
|
*/
|
|
interface ProvideRoleInterface
|
|
{
|
|
/**
|
|
* Return an array of role provided by the object.
|
|
*
|
|
* @return string[] array of roles (as string)
|
|
*/
|
|
public function getRoles(): array;
|
|
|
|
/**
|
|
* Return roles which doesn't need.
|
|
*
|
|
* @return string[] array of roles without scopes
|
|
*/
|
|
public function getRolesWithoutScope(): array;
|
|
}
|