public class JoSQLSwingFileFilter extends FileFilter
FileFilter that uses a JoSQL statement to provide the filtering.
The value returned by the accept(File) method is determined by executing the
WHERE clause of a JoSQL statement on each File passed in. This just uses an instance of:
JoSQLFileFilter to do it's job, see that class for details of usage.| 构造器和说明 |
|---|
JoSQLSwingFileFilter(Query q)
Init this file filter with the query already built and parsed.
|
JoSQLSwingFileFilter(String q)
Init this file filter with the query.
|
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
accept(File f)
Apply the WHERE clause of the statement to the
File passed in. |
String |
getDescription()
Return the description for the filter.
|
JoSQLFileFilter |
getJoSQLFileFilter()
Get the file filter being used "under the hoodie" in the
accept(File) method. |
void |
setDescription(String d)
Set the description that should be used.
|
void |
setJoSQLFileFilter(JoSQLFileFilter ff)
Set the JoSQLFileFilter that should be used to handle the
accept(File) method. |
public JoSQLSwingFileFilter(String q) throws QueryParseException
q - The query.QueryParseException - If there is an issue with the parsing of the query,
or if the FROM class is not File.public JoSQLSwingFileFilter(Query q) throws IllegalStateException, QueryParseException
q - The query.IllegalStateException - If the Query object has not been parsed.QueryParseException - If the FROM class is not File.public void setJoSQLFileFilter(JoSQLFileFilter ff)
accept(File) method.ff - The file filter.public void setDescription(String d)
d - The description.public String getDescription()
getDescription 在类中 FileFilterpublic JoSQLFileFilter getJoSQLFileFilter()
accept(File) method.
You should also check that file filter to see if an exception has occurred.public boolean accept(File f)
File passed in.
This is just a wrapper call to: JoSQLFileFilter.accept(File).accept 在类中 FileFilterf - The file to evaluate the WHERE on.true if the WHERE clause evaluates to true.Copyright © 2021. All rights reserved.