for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the Patron package.
*
* (c) Olivier Laviale <[email protected]>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Patron;
class Template implements \IteratorAggregate
{
/**
* @var string|null
public $file;
* @var Node[]
public $nodes;
* @param Node[] $nodes
* @param array $options
public function __construct(array $nodes, array $options = [])
$this->nodes = $nodes;
if (isset($options['file']))
$this->file = $options['file'];
}
* @return Node[]|\ArrayIterator
public function getIterator()
return new \ArrayIterator($this->nodes);