32 if (DIRECTORY_SEPARATOR != substr(
$path, -1)) {
33 $path .= DIRECTORY_SEPARATOR;
42 if (!is_dir($this->path) || filemtime($this->path) >
$timestamp) {
46 foreach ($this as $resource) {
61 foreach ($this as $resource) {
62 $content[] = $resource->getContent();
65 return implode(
"\n", $content);
75 return is_dir($this->path)
77 : new \EmptyIterator();
96 return new FileResource(parent::current()->getPathname());
112 parent::__construct($iterator);
119 $file = $this->current();
120 $name =
$file->getBasename();
122 if (
$file->isDir()) {
123 return '.' != $name[0];
126 return null === $this->pattern || 0 < preg_match($this->pattern, $name);
131 return new self(new \RecursiveDirectoryIterator($this->current()->getPathname(), \RecursiveDirectoryIterator::FOLLOW_SYMLINKS),
$this->pattern);
A resource is something formulae can be loaded from.
isFresh($timestamp)
Checks if a timestamp represents the latest resource.
__toString()
Returns a unique string for the current resource.
getContent()
Returns the combined content of all inner resources.
__construct(\RecursiveDirectoryIterator $iterator, $pattern=null)
A resource is something formulae can be loaded from.
Filters files by a basename pattern.
Create styles array
The data for the language used.
foreach($mandatory_scripts as $file) $timestamp
__construct($path, $pattern=null)
Constructor.
A resource is something formulae can be loaded from.
if(!file_exists("$old.txt")) if($old===$new) if(file_exists("$new.txt")) $file
An iterator that converts file objects into file resources.