public function RecursiveDirectoryIterator::current in Database Sanitize 7
Return an instance of SplFileInfo with support for relative paths.
Return value
SplFileInfo File information
Overrides RecursiveDirectoryIterator::current
1 method overrides RecursiveDirectoryIterator::current()
- RecursiveDirectoryIterator::current in vendor/
symfony/ finder/ Iterator/ RecursiveDirectoryIterator.php - Return an instance of SplFileInfo with support for relative paths.
File
- vendor/
symfony/ finder/ Iterator/ RecursiveDirectoryIterator.php, line 65
Class
- RecursiveDirectoryIterator
- Extends the \RecursiveDirectoryIterator to support relative paths.
Namespace
Symfony\Component\Finder\IteratorCode
public function current() {
// the logic here avoids redoing the same work in all iterations
if (null === ($subPathname = $this->subPath)) {
$subPathname = $this->subPath = (string) $this
->getSubPath();
}
if ('' !== $subPathname) {
$subPathname .= $this->directorySeparator;
}
$subPathname .= $this
->getFilename();
return new SplFileInfo($this->rootPath . $this->directorySeparator . $subPathname, $this->subPath, $subPathname);
}