Public Member Functions | |
ConfigFileRedeemerFilepath (Logger logger, File baseDir) | |
String[] | getFileEndings () |
void | addRedeemedFilePathSnippet (String filePathSnippet) |
void | configure () |
Protected Member Functions | |
boolean | _isNotAConfigFile (File file) |
Redeems files based on (part of) their path name. This class should be used to ignore files under certain directories, or specific files.
One should be careful to use path name snippets that match as accurately as possible, to avoid excluding other files whose path names unexpectedly also match. For better accuracy, you should
^
character prepended to the path name snippet set in addRedeemedFilePathSnippet(String). ^ITS
will exclude all files under /alma/src/MONTHLY-2006-03-ITER-2/ITS
if the base directory in ConfigFileFinder is given as /alma/src/MONTHLY-2006-03-ITER-2
. However it will not exclude files under mymodule/src/alma/mypackage/ITS/blabla
. test
directory in all modules, use the specialized filter ConfigFileRedeemerTestDir which not only checks whether /test/ is on the path name, but also looks for a parallel src
directory with a Makefile and thus minimizes the risk of a false match. alma.acs.config.validators.ConfigFileRedeemerFilepath.ConfigFileRedeemerFilepath | ( | Logger | logger, | |
File | baseDir | |||
) |
boolean alma.acs.config.validators.ConfigFileRedeemerFilepath._isNotAConfigFile | ( | File | file | ) | [protected, virtual] |
Called by isNotAConfigFile(File) only if the file ending matches one of the endings in getFileEndings().
Implements alma.acs.config.validators.ConfigFileRedeemer.
References alma.acs.config.validators.ConfigFileRedeemer.logger.
void alma.acs.config.validators.ConfigFileRedeemerFilepath.addRedeemedFilePathSnippet | ( | String | filePathSnippet | ) |
void alma.acs.config.validators.ConfigFileRedeemerFilepath.configure | ( | ) |
This method may be overridden by a subclass. TODO: read in from file instead of hardcoding the snippets
References alma.acs.config.validators.ConfigFileRedeemerFilepath.addRedeemedFilePathSnippet().
Referenced by alma.acs.config.validators.ConfigFileRedeemerFilepath.ConfigFileRedeemerFilepath().
String [] alma.acs.config.validators.ConfigFileRedeemerFilepath.getFileEndings | ( | ) | [virtual] |
Returns null
so that it gets to redeem any kind of file.
Implements alma.acs.config.validators.ConfigFileRedeemer.