public function getMultipleByName(array $permissions): array
    {
        if ($this->permissions === null) {
            $this->getAll();
        }

        $results = [];

        foreach ($permissions as $permission) {
            if (isset($this->names[$permission])) {
                $results[] = $this->permissions[$this->names[$permission]];
            }
        }

        return $results;
    }
public function getMultipleByName(array $permissions): array
    {
        if ($this->permissions === null) {
            $this->getAll();
        }

        $results = [];

        foreach ($permissions as $permission) {
            if (isset($this->names[$permission])) {
                $results[] = $this->permissions[$this->names[$permission]];
            }
        }

        return $results;
    }
public function getMultipleByName ( array $ permissions ) : array { if ( $ this -> permissions === null ) { $ this -> getAll ( ) ; } $ results = [ ] ; foreach ( $ permissions as $ permission ) { if ( isset ( $ this -> names [ $ permission ] ) ) { $ results [ ] = $ this -> permissions [ $ this -> names [ $ permission ] ] ; } } return $ results ; }
Get a permissions by their name

@param string[] $permissions
@return IPermission[]
Get a permissions by their name