apidoc
[ class tree: apidoc ] [ index: apidoc ] [ all elements ]

Class: FileList

Source Location: /PHP_CodeSniffer-3.1.1/src/Files/FileList.php

Class Overview


Represents a list of files on the file system that are to be checked during the run.


Author(s):

Copyright:

  • 2006-2015 Squiz Pty Ltd (ABN 77 084 670 600)

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 19]
Represents a list of files on the file system that are to be checked during the run.

File objects are created as needed rather than all at once.



[ Top ]


Class Variables

$config =  null

[line 41]

The config data for the run.
  • Access: public

Type:   \PHP_CodeSniffer\Config


[ Top ]

$ignorePatterns = array()

[line 55]

An array of patterns to use for skipping files.
  • Access: protected

Type:   array


[ Top ]

$ruleset =  null

[line 48]

The ruleset used for the run.
  • Access: public

Type:   \PHP_CodeSniffer\Ruleset


[ Top ]



Method Detail

__construct (Constructor)   [line 66]

void __construct( Config $config, Ruleset $ruleset)

Constructs a file list and loads in an array of file paths to process.
  • Access: public

Parameters:

\PHP_CodeSniffer\Config   $config   —  The config data for the run.
\PHP_CodeSniffer\Ruleset   $ruleset   —  The ruleset used for the run.

[ Top ]

addFile   [line 110]

void addFile( string $path, [\PHP_CodeSniffer\Files\File $file = null])

Add a file to the list.

If a file object has already been created, it can be passed here. If it is left NULL, it will be created when accessed.

  • Access: public

Parameters:

string   $path   —  The path to the file being added.
\PHP_CodeSniffer\Files\File   $file   —  The file being added.

[ Top ]

count   [line 239]

integer count( )

Return the number of files in the list.

[ Top ]

current   [line 182]

\PHP_CodeSniffer\Files\File current( )

Get the file that is currently being processed.

[ Top ]

key   [line 199]

void key( )

Return the file path of the current file being processed.

[ Top ]

next   [line 211]

void next( )

Move forward to the next file.

[ Top ]

rewind   [line 170]

void rewind( )

Rewind the iterator to the first file.

[ Top ]

valid   [line 223]

boolean valid( )

Checks if current position is valid.

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:27:28 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.