C# Class NAnt.Core.DirectoryScanner

Inheritance: ICloneable
ファイルを表示 Open project: skolima/NAnt Class Usage Examples

Public Methods

Method Description
Clone ( ) : object

Creates a shallow copy of the DirectoryScanner.

DirectoryScanner ( ) : System

Initializes a new instance of the DirectoryScanner.

On unix, patterns are matching case-sensitively; otherwise, they are matched case-insensitively.

DirectoryScanner ( bool caseSensitive ) : System

Initializes a new instance of the DirectoryScanner specifying whether patterns are to be match case-sensitively.

Scan ( ) : void

Uses Includes and Excludes search criteria (relative to BaseDirectory or absolute), to search for filesystem objects.

Private Methods

Method Description
CleanPath ( string nantPath ) : StringBuilder
CleanPath ( string baseDirectory, string nantPath ) : string
ConvertPatterns ( StringCollection nantPatterns, ArrayList regexPatterns, StringCollection nonRegexFiles, bool addSearchDirectories ) : void

Parses specified NAnt search patterns for search directories and corresponding regex patterns.

IsPathIncluded ( string path, ArrayList includedPatterns, ArrayList excludedPatterns ) : bool
ParseSearchDirectoryAndPattern ( bool isInclude, string originalNAntPattern, string &searchDirectory, bool &recursive, bool &isRegex, string &regexPattern ) : void

Given a NAnt search pattern returns a search directory and an regex search pattern.

Reset ( ) : void
ScanDirectory ( string path, bool recursive ) : void

Searches a directory recursively for files and directories matching the search criteria.

TestRegex ( string path, RegexEntry entry ) : bool
ToRegexPattern ( string nantPattern ) : string

Converts search pattern to a regular expression pattern.

Method Details

Clone() public method

Creates a shallow copy of the DirectoryScanner.
public Clone ( ) : object
return object

DirectoryScanner() public method

Initializes a new instance of the DirectoryScanner.
On unix, patterns are matching case-sensitively; otherwise, they are matched case-insensitively.
public DirectoryScanner ( ) : System
return System

DirectoryScanner() public method

Initializes a new instance of the DirectoryScanner specifying whether patterns are to be match case-sensitively.
public DirectoryScanner ( bool caseSensitive ) : System
caseSensitive bool Specifies whether patterns are to be matched case-sensititely.
return System

Scan() public method

Uses Includes and Excludes search criteria (relative to BaseDirectory or absolute), to search for filesystem objects.
public Scan ( ) : void
return void