Methods Summary |
---|
public java.lang.String[] | getFiles()
getFilesInternal(mainRoot);
String[] files = new String[fileList.size()];
if(files.length <= 0)
return files;
int len = 0;
if(relativePath())
len = mainRoot.getPath().length() + 1;
for(int i = 0; i < files.length; i++)
{
files[i] = ((File)fileList.get(i)).getPath().substring(len).replace('\\", '/");
}
Arrays.sort(files, String.CASE_INSENSITIVE_ORDER);
return files;
|
public void | getFilesInternal(java.io.File root)
File[] files = root.listFiles();
if(files.length <= 0 && copyEmptyDirs)
fileList.add(root);
for(int i = 0; i < files.length; i++)
{
if(files[i].isDirectory())
{
if(!copySymLinks && !FileUtils.safeIsRealDirectory(files[i]))
continue;
getFilesInternal(files[i]);
}
else
fileList.add(files[i]); // actual file
}
|
protected abstract boolean | relativePath()
|
public void | setCopyEmptyDirs(boolean b)
copyEmptyDirs = b;
|
public void | setCopySymLinks(boolean b)
copySymLinks = b;
|