public function getAll(array $targets, array $subjects): array
    {
        $acls = [];
        if ($this->strategy instanceof MultiStrategy) {
            $acls = $this->strategy->loadAll($targets, $subjects, $this);
        } else {
            foreach ($targets as $target) {
                $acls[(string)$target] = $this->strategy->load($target, $subjects, $this);
            }
        }
        $missing = array_diff(array_map(function ($a) {
            return (string) $a;
        }, $targets), array_keys($acls));
        // Check every requested target was found
        if (!empty($missing)) {
            throw new Exception\Unloadable("Unable to load ACL for " . implode(", ", $missing));
        }
        return $acls;
    }
public function getAll(array $targets, array $subjects): array
    {
        $acls = [];
        if ($this->strategy instanceof MultiStrategy) {
            $acls = $this->strategy->loadAll($targets, $subjects, $this);
        } else {
            foreach ($targets as $target) {
                $acls[(string)$target] = $this->strategy->load($target, $subjects, $this);
            }
        }
        $missing = array_diff(array_map(function ($a) {
            return (string) $a;
        }, $targets), array_keys($acls));
        // Check every requested target was found
        if (!empty($missing)) {
            throw new Exception\Unloadable("Unable to load ACL for " . implode(", ", $missing));
        }
        return $acls;
    }
public function getAll ( array $ targets , array $ subjects ) : array { $ acls = [ ] ; if ( $ this -> strategy instanceof MultiStrategy ) { $ acls = $ this -> strategy -> loadAll ( $ targets , $ subjects , $ this ) ; } else { foreach ( $ targets as $ target ) { $ acls [ ( string ) $ target ] = $ this -> strategy -> load ( $ target , $ subjects , $ this ) ; } } $ missing = array_diff ( array_map ( function ( $ a ) { return ( string ) $ a ; } , $ targets ) , array_keys ( $ acls ) ) ; // Check every requested target was found if ( ! empty ( $ missing ) ) { throw new Exception \ Unloadable ( "Unable to load ACL for " . implode ( ", " , $ missing ) ) ; } return $ acls ; }
Gets access control lists for several Targets.

@since 2.1.0
@param \Caridea\Acl\Target[] $targets The `Target` whose ACL will be loaded
@param \Caridea\Acl\Subject[] $subjects An array of `Subject`s
@return array<string,\Caridea\Acl\Acl> The loaded ACLs
@throws \Caridea\Acl\Exception\Unloadable If the target provided is invalid
@throws \InvalidArgumentException If the `targets` or `subjects` argument contains invalid values
Gets access control lists for several Targets .