2017 © Pedro Peláez
 

package fileitr

Bunch of fileiterators

image

thapp/fileitr

Bunch of fileiterators

  • Tuesday, April 12, 2016
  • by iwyg
  • Repository
  • 1 Watchers
  • 0 Stars
  • 4 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

Filesystem itererators

Author Source Code Software License, (*1)

Build Status Code Coverage HHVM, (*2)

Requirements

php >= 5.6

Installation

> composer require thapp/fileitr

Usage

PatternIterator

PatternIterator is used to recursively iterate over directories and files using a regular expression as filter., (*3)

<?php
use Thapp\Fileitr\PatternIterator;

// iterates over a maximum directory depth of 2, searching for files with a '.php' suffix
$itr = new PatternIterator($path, '/\.(php)$/', 2, -1, $flags);

// iterates over a maximum directory depth of 1, and limits overall files to 3.
$itr = new PatternIterator($path, '/\.(php)$/', 1, 3, $flags);

RecursiveDirectoryIterator

The RecursiveDirectoryIterator extends \RecursiveDirectoryIterator., (*4)

Key differences:, (*5)

  • ability to limit overall file count.
  • will ouput a custom FileInfo Object including relative path, and relative pathname
  • only accepts CURRENT_AS_FILEINFO, not CURRENT_AS_SELF nor CURRENT_AS_PATHNAME

The Versions

12/04 2016

dev-master

9999999-dev

Bunch of fileiterators

  Sources   Download

MIT

The Requires

  • php ^5.6 || ^7.0

 

The Development Requires

by Avatar iwyg

12/04 2016

v0.1.1

0.1.1.0

Bunch of fileiterators

  Sources   Download

MIT

The Requires

  • php ^5.6 || ^7.0

 

The Development Requires

by Avatar iwyg

12/04 2016

v0.1.0

0.1.0.0

Bunch of fileiterators

  Sources   Download

MIT

The Requires

  • php ^5.6 || ^7.0

 

The Development Requires

by Avatar iwyg