/var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/authorization/src/Policy
NameSizeModeActions
Exception/-0755rm
BeforePolicyInterface.php14870644editdlrm
MapResolver.php37270644editdlrm
OrmResolver.php55300644editdlrm
RequestPolicyInterface.php11870644editdlrm
ResolverCollection.php25700644editdlrm
ResolverInterface.php12260644editdlrm
Result.php14670644editdlrm
ResultInterface.php9850644editdlrm
Edit: /var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/authorization/src/Policy/ResolverCollection.php (2570B)
ServicePolicy::class * ]) * ]); * * $service = new AuthorizationService($collection); * ``` */ class ResolverCollection implements ResolverInterface { /** * Policy resolver instances. * * @var \Authorization\Policy\ResolverInterface[] */ protected $resolvers = []; /** * Constructor. Takes an array of policy resolver instances. * * @param \Authorization\Policy\ResolverInterface[] $resolvers An array of policy resolver instances. */ public function __construct(array $resolvers = []) { foreach ($resolvers as $resolver) { $this->add($resolver); } } /** * Adds a resolver to the collection. * * @param \Authorization\Policy\ResolverInterface $resolver Resolver instance. * @return $this */ public function add(ResolverInterface $resolver) { $this->resolvers[] = $resolver; return $this; } /** * @inheritDoc */ public function getPolicy($resource) { foreach ($this->resolvers as $resolver) { try { return $resolver->getPolicy($resource); } catch (MissingPolicyException $e) { } } throw new MissingPolicyException($resource); } }