protected function createInstallOneOfRule(array $packages, $reason, $job)
    {
        $literals = array();
        foreach ($packages as $package) {
            $literals[] = $package->id;
        }

        return new Rule($literals, $reason, $job['packageName'], $job);
    }
protected function createInstallOneOfRule(array $packages, $reason, $job)
    {
        $literals = array();
        foreach ($packages as $package) {
            $literals[] = $package->id;
        }

        return new Rule($literals, $reason, $job['packageName'], $job);
    }
protected function createInstallOneOfRule ( array $ packages , $ reason , $ job ) { $ literals = array ( ) ; foreach ( $ packages as $ package ) { $ literals [ ] = $ package -> id ; } return new Rule ( $ literals , $ reason , $ job [ 'packageName' ] , $ job ) ; }
Creates a rule to install at least one of a set of packages

The rule is (A|B|C) with A, B and C different packages. If the given
set of packages is empty an impossible rule is generated.

@param  array $packages The set of packages to choose from
@param  int   $reason   A RULE_* constant describing the reason for
generating this rule
@param  array $job      The job this rule was created from
@return Rule  The generated rule
Creates a rule to install at least one of a set of packages