public class FilenameSuffixFilter extends Object implements FilenameFilter
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
ignoreCase
Flag to signal that we want to ignore the case.
|
protected String |
suffix
The suffix which files must have to be accepted.
|
| Constructor and Description |
|---|
FilenameSuffixFilter(String suffix)
Construct a case sensitive FilenameSuffixFilter.
|
FilenameSuffixFilter(String suffix,
boolean ignoreCase)
Construct a FilenameSuffixFilter.
|
protected final String suffix
protected final boolean ignoreCase
public FilenameSuffixFilter(String suffix, boolean ignoreCase)
suffix - The suffix which files must have to be accepted.ignoreCase - True if the filter should be case-insensitive.public FilenameSuffixFilter(String suffix)
suffix - The suffix which files must have to be accepted.public boolean accept(File dir, String name)
accept in interface FilenameFilterdir - The directory the file resides in.name - The name of the file.Copyright © 2015 JBoss by Red Hat. All rights reserved.