|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Interface for filter plug-ins. Filter plug-ins remove items from
a result list based on whether or not they meet certain criteria.
Implementing this interface allows
the plug-in to be dynamically loaded by the Search and Whatever
application. Plug-ins will be loaded with the SearchController
they correspond to, as determined by the values returned by the
getResultClass
method. For more information on developing
plug-ins, refer to the
Search and Whatever home page, [Developers] link.
PluginIfc.getResultClass()
Field Summary | |
static java.lang.String |
CLASS_NAME
|
static int |
EXCLUDE
Constant for exclude operations. |
static int |
INCLUDE
Constant for include operations. |
Fields inherited from interface com.usefullittlethings.saw.model.PluginIfc |
BLOCK, LINEAR, SINGLE_BLOCK, UNSUPPORTED |
Method Summary | |
void |
begin()
This method of the plug-in will be invoked immediately before a search is performed, allowing the plug-in the "prepare" itself to perform a search. |
void |
end()
This method of the plug-in will be invoked immediately after a search has completed, allowing the plug-in the perform any post-search clean-up activities.. |
java.lang.Object |
exclude(int pattern,
java.lang.Object target)
Given a search pattern and a target, the plug-in must decide whether or not to exclude the target or the target contents. |
int |
getOperation()
Returns the operation type currently assigned to this filter (include/exclude). |
java.lang.Object |
include(int pattern,
java.lang.Object target)
Given a search pattern and a target, the plug-in must decide whether or not to include the target or the target contents. |
void |
setBase(java.lang.Object base)
This method is invoked at the beginning of each search to indicate the base reference point for the search. |
void |
setOperation(int type)
Sets the operation type for this filter to INCLUDE or EXCLUDE. |
Methods inherited from interface com.usefullittlethings.saw.model.PluginIfc |
addObserver, clone, configure, configure, deleteObserver, getAuthor, getEmail, getName, getResultClass, getShortName, getState, getUI, getUnixName, getWebsite, hasUI, isEnabled, reset, setEnabled, supportCommandLine, supports, toXMLString |
Field Detail |
public static final java.lang.String CLASS_NAME
public static final int INCLUDE
public static final int EXCLUDE
Method Detail |
public void setBase(java.lang.Object base)
base
- The base reference point for the current search operationpublic java.lang.Object include(int pattern, java.lang.Object target) throws FilterInvocationException
pattern
- The search pattern that is being applied to this search
operation (LINEAR, BLOCK, SINGLE_BLOCK, etc.)target
- The object or object set that is to be filtered
FilterInvocationException
public java.lang.Object exclude(int pattern, java.lang.Object target) throws FilterInvocationException
pattern
- The search pattern that is being applied to this search
operation (LINEAR, BLOCK, SINGLE_BLOCK, etc.)target
- The object or object set that is to be filtered
FilterInvocationException
public int getOperation()
public void setOperation(int type)
type
- The type of operation to perform with this filter (INCLUDE or
EXCLUDE)public void begin() throws FilterInvocationException
FilterInvocationException
public void end() throws FilterInvocationException
FilterInvocationException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |