org.apache.tools.ant.util
public class SourceFileScanner extends Object implements ResourceFactory
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.
Field Summary | |
---|---|
protected Task | task |
Constructor Summary | |
---|---|
SourceFileScanner(Task task)
Construct a new SourceFileScanner. |
Method Summary | |
---|---|
Resource | getResource(String name)
Returns resource information for a file at destination. |
String[] | restrict(String[] files, File srcDir, File destDir, FileNameMapper mapper)
Restrict the given set of files to those that are newer than
their corresponding target files.
|
String[] | restrict(String[] files, File srcDir, File destDir, FileNameMapper mapper, long granularity)
Restrict the given set of files to those that are newer than
their corresponding target files.
|
File[] | restrictAsFiles(String[] files, File srcDir, File destDir, FileNameMapper mapper)
Convenience layer on top of restrict that returns the source
files as File objects (containing absolute paths if srcDir is
absolute). |
File[] | restrictAsFiles(String[] files, File srcDir, File destDir, FileNameMapper mapper, long granularity)
Convenience layer on top of restrict that returns the source
files as File objects (containing absolute paths if srcDir is
absolute).
|
Parameters: task The task we should log messages through.
Parameters: name relative path of file at destination.
Returns: data concerning a file whose relative path to destDir is name.
Since: Ant 1.5.2
Parameters: files the original set of files. srcDir all files are relative to this directory. destDir target files live here. if null file names returned by the mapper are assumed to be absolute. mapper knows how to construct a target file names from source file names.
Returns: an array of filenames.
Parameters: files the original set of files. srcDir all files are relative to this directory. destDir target files live here. If null file names returned by the mapper are assumed to be absolute. mapper knows how to construct a target file names from source file names. granularity The number of milliseconds leeway to give before deciding a target is out of date.
Returns: an array of filenames.
Since: Ant 1.6.2
Parameters: files the original set of files. srcDir all files are relative to this directory. destDir target files live here. If null file names returned by the mapper are assumed to be absolute. mapper knows how to construct a target file names from source file names.
Returns: an array of files.
Parameters: files the original set of files. srcDir all files are relative to this directory. destDir target files live here. If null file names returned by the mapper are assumed to be absolute. mapper knows how to construct a target file names from source file names. granularity The number of milliseconds leeway to give before deciding a target is out of date.
Returns: an array of files.
Since: Ant 1.6.2