Package org.craftercms.core.service
Interface ItemFilter
-
- All Known Implementing Classes:
CompositeItemFilter,ExcludeByUrlItemFilter,IncludeByUrlItemFilter
public interface ItemFilterInterface for item filters. Used byContentStoreServices to filter the items returned to the user of the API.- Author:
- Sumer Jabri, Alfonso Vásquez
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanaccepts(Item item, List<Item> acceptedItems, List<Item> rejectedItems, boolean runningBeforeProcessing)Return true if the given item is accepted by the filter.booleanrunAfterProcessing()Returns true if the filter should be executed after all items are processed (basically, after allItemProcessorare called).booleanrunBeforeProcessing()Returns true if the filter should be executed before any item is processed (basically, before anyItemProcessoris called).
-
-
-
Method Detail
-
runBeforeProcessing
boolean runBeforeProcessing()
Returns true if the filter should be executed before any item is processed (basically, before anyItemProcessoris called).
-
runAfterProcessing
boolean runAfterProcessing()
Returns true if the filter should be executed after all items are processed (basically, after allItemProcessorare called).
-
accepts
boolean accepts(Item item, List<Item> acceptedItems, List<Item> rejectedItems, boolean runningBeforeProcessing)
Return true if the given item is accepted by the filter.- Parameters:
item- the item to accept or rejectacceptedItems- the list of the currently accepted itemsrejectedItems- the list of the currently rejected itemsrunningBeforeProcessing- if the filter is running before processing (true) or after processing (false)
-
-