if (filesets.isEmpty() || srcdirSet || includesSet || excludesSet) {
FileSet set = new FileSet();
set.setDir(getProject().resolveFile(srcdir));
// ensure whitespace is ignored from around the components of the includes
for (Object o : Arrays.asList(includes.split(","))) {
set.appendIncludes(new String[]{((String) o).trim()});
}
// ensure whitespace is ignored from around the components of the excludes
for (Object o : Arrays.asList(excludes.split(","))) {
set.appendExcludes(new String[]{((String) o).trim()});
}