for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace mav3rick177\RapidPagination\Base\Query;
/**
* Class UnionAll
*/
class UnionAll extends SelectOrUnionAll implements \IteratorAggregate
{
* @var Select
protected $mainQuery;
protected $supportQuery;
* UnionAll constructor.
*
* @param Select $select
public function __construct(Select $select)
$this->mainQuery = $select;
$this->supportQuery = $select->inverse();
}
* @return Select
public function mainQuery()
return $this->mainQuery;
public function supportQuery()
return $this->supportQuery;
* Clone Select.
public function __clone()
$this->mainQuery = clone $this->mainQuery;
$this->supportQuery = clone $this->supportQuery;
* Retrieve an external iterator.
* @return \ArrayIterator|Select[]
public function getIterator()
return new \ArrayIterator([$this->mainQuery, $this->supportQuery]);