phing-util

# Class: SourceFileScanner Source Location: /util/SourceFileScanner.php
### Class Overview
Utility class that collects the functionality of the various scanDir methods that have been scattered in several tasks before. | ### Methods __construct restrict restrictAsFiles
### Class Details [line 31] Utility class that collects the functionality of the various scanDir methods that have been scattered in several tasks before. The only method returns an array of source files. The array is a subset of the files given as a parameter and holds only those that are newer than their corresponding target files. [ Top ] ### Class Methods ### constructor __construct [line 42]
`SourceFileScanner __construct( task $task)`
#### Parameters:
task | $task | The task we should log messages through
[ Top ] ### method restrict [line 60]
`void restrict( files &$files, srcDir $srcDir, destDir $destDir, FilenameMapper $mapper, [force $force = false])`
Restrict the given set of files to those that are newer than their corresponding target files. #### Parameters:
files | &$files | the original set of files
srcDir | $srcDir | all files are relative to this directory
destDir | $destDir | target files live here. if null file names returned by the mapper are assumed to be absolute.
FilenameMapper | $mapper | knows how to construct a target file names from source file names.
force | $force | Boolean that determines if the files should be forced to be copied.
[ Top ] ### method restrictAsFiles [line 150]
`void restrictAsFiles( &$files, &$srcDir, &$destDir, &$mapper)`
Convenience layer on top of restrict that returns the source files as PhingFile objects (containing absolute paths if srcDir is absolute). #### Parameters:
| &$files |
| &$srcDir |
| &$destDir |
| &$mapper |
[ Top ] Documentation generated on Mon, 19 Oct 2009 10:52:03 +0200 by phpDocumentor 1.4.3