Moodle  2.2.1
http://www.collinsharper.com
SimpleCollector Class Reference
Inheritance diagram for SimpleCollector:

Public Member Functions

 _removeTrailingSlash ($path)
 collect (&$test, $path)
 _handle (&$test, $file)
 _isHidden ($filename)

Detailed Description

Definition at line 19 of file collector.php.


Member Function Documentation

_handle ( &$  test,
file 
)

This method determines what should be done with a given file and adds it via GroupTest::addTestFile() if necessary.

This method should be overriden to provide custom matching criteria, such as pattern matching, recursive matching, etc. For an example, see SimplePatternCollector::_handle().

Parameters:
object$testGroup test with GroupTest::addTestFile() method.
string$filenameA filename as generated by collect()
See also:
collect() protected

Reimplemented in SimplePatternCollector.

Definition at line 68 of file collector.php.

Here is the caller graph for this function:

_isHidden ( filename)

Tests for hidden files so as to skip them. Currently only tests for Unix hidden files.

Parameters:
string$filenamePlain filename.
Returns:
boolean True if hidden file. private

Definition at line 82 of file collector.php.

Here is the caller graph for this function:

_removeTrailingSlash ( path)

Strips off any kind of slash at the end so as to normalise the path.

Parameters:
string$pathPath to normalise.
Returns:
string Path without trailing slash.

Definition at line 26 of file collector.php.

Here is the caller graph for this function:

collect ( &$  test,
path 
)

Scans the directory and adds what it can.

Parameters:
object$testGroup test with GroupTest::addTestFile() method.
string$pathDirectory to scan.
See also:
_attemptToAdd()

Definition at line 42 of file collector.php.

Here is the call graph for this function:


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations