public class BasicWithExclusionsDescendantFileSource extends Object implements DescendantFileSource
| Constructor and Description |
|---|
BasicWithExclusionsDescendantFileSource(File rootDirectory,
List<String> exclusions) |
BasicWithExclusionsDescendantFileSource(String rootDirectoryPath,
List<String> exclusions) |
| Modifier and Type | Method and Description |
|---|---|
DescendantFileSource |
getDescendant(String relativePath)
Return a DescendantFileSource representing the descendant directory
specified by the relative path.
|
File |
getFile(String path)
Return the File, if it exists, that the given path represents for the
FileSource implementation in use.
|
String |
getRelativePath(File file)
Return the path relative to the root directory that represents the given descendant file.
|
String |
getRelativePath(String filePath)
Return the path relative to the root directory that represents the given descendant file path.
|
File |
getRootDirectory()
Return the root directory represented by this FileLocator as a java.io.File.
|
String |
getRootDirectoryPath()
Return the path of the root directory represented by this FileLocator.
|
boolean |
isDescendant(File file)
Return true if the given File is an existing descendant of the root directory, false otherwise.
|
boolean |
isDescendant(String filePath)
Return true if the given file path is an existing descendant of the root directory, false otherwise.
|
public BasicWithExclusionsDescendantFileSource(String rootDirectoryPath, List<String> exclusions)
public File getFile(String path)
FileSourcegetFile in interface FileSourcepath - the path to the desired File.public DescendantFileSource getDescendant(String relativePath)
DescendantFileSourcegetDescendant in interface DescendantFileSourcerelativePath - the relative path to the descendant directory.public File getRootDirectory()
DescendantFileSourcegetRootDirectory in interface DescendantFileSourcepublic String getRootDirectoryPath()
DescendantFileSourcegetRootDirectoryPath in interface DescendantFileSourcepublic boolean isDescendant(File file)
DescendantFileSourceisDescendant in interface DescendantFileSourcefile - the File to be checked if it is a descendant.public boolean isDescendant(String filePath)
DescendantFileSourceisDescendant in interface DescendantFileSourcefilePath - the file path to be checked if it is a descendant.public String getRelativePath(File file)
DescendantFileSourcegetRelativePath in interface DescendantFileSourcefile - the File for which the relative path is to be determined.public String getRelativePath(String filePath)
DescendantFileSourcegetRelativePath in interface DescendantFileSourcefilePath - the file path for which the relative path is to be determined.Copyright © 1999–2013 UCAR/Unidata. All rights reserved.