Package com.day.cq.wcm.msm.commons
Class ItemFilterUtil
- java.lang.Object
-
- com.day.cq.wcm.msm.commons.ItemFilterUtil
-
public class ItemFilterUtil extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String[]EMPTY_PROPERTIESstatic java.lang.String[]EXCLUDED_NODE_TYPES_DEFAULTstatic java.lang.String[]EXCLUDED_PARAGRAPH_ITEMS_DEFAULTstatic java.lang.String[]EXCLUDED_PROPERTIES_DEFAULTstatic java.lang.StringPARAMETER_EXCLUDED_NODE_TYPESExcluded node types parameter name to use for your Service Configuration.static java.lang.StringPARAMETER_EXCLUDED_PARAGRAPH_ITEMSExcluded paragraph items parameter name to use for your Service Configuration.static java.lang.StringPARAMETER_EXCLUDED_PROPERTIESExcluded properties parameter name to use for your Service Configuration.
-
Constructor Summary
Constructors Constructor Description ItemFilterUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ItemFilterImplcreateComponentFilter(java.util.Dictionary properties, RolloutManager rolloutManager)Creates an ItemFilterImpl from the given Properties with the namePARAMETER_EXCLUDED_NODE_TYPESandPARAMETER_EXCLUDED_PARAGRAPH_ITEMS
Properties default to empty.static ItemFilterImplcreateComponentFilter(ValueMap config, RolloutManager rolloutManager)Helper method to create a component filter using aValueMapstatic ItemFilterImplcreateFilter(java.lang.String[] nodeTypes, java.lang.String[] nodeNames, java.lang.String[] propertyNames, RolloutManager rolloutManager)Creates an ItemFilterImpl based on a set of patterns that will be used to match NodeTypes, Node names and Property names.static ItemFilterImplcreatePageFilter(java.util.Dictionary properties, RolloutManager rolloutManager)Creates an ItemFilterImpl from the given Properties with the namePARAMETER_EXCLUDED_NODE_TYPESandPARAMETER_EXCLUDED_PROPERTIES
Properties default to empty.static ItemFilterImplcreatePageFilter(ValueMap config, RolloutManager rolloutManager)Helper method to create a page filter using aValueMap
-
-
-
Field Detail
-
EMPTY_PROPERTIES
public static final java.lang.String[] EMPTY_PROPERTIES
-
PARAMETER_EXCLUDED_PROPERTIES
public static final java.lang.String PARAMETER_EXCLUDED_PROPERTIES
Excluded properties parameter name to use for your Service Configuration.- See Also:
- Constant Field Values
-
EXCLUDED_PROPERTIES_DEFAULT
public static final java.lang.String[] EXCLUDED_PROPERTIES_DEFAULT
-
PARAMETER_EXCLUDED_PARAGRAPH_ITEMS
public static final java.lang.String PARAMETER_EXCLUDED_PARAGRAPH_ITEMS
Excluded paragraph items parameter name to use for your Service Configuration.- See Also:
- Constant Field Values
-
EXCLUDED_PARAGRAPH_ITEMS_DEFAULT
public static final java.lang.String[] EXCLUDED_PARAGRAPH_ITEMS_DEFAULT
-
PARAMETER_EXCLUDED_NODE_TYPES
public static final java.lang.String PARAMETER_EXCLUDED_NODE_TYPES
Excluded node types parameter name to use for your Service Configuration.- See Also:
- Constant Field Values
-
EXCLUDED_NODE_TYPES_DEFAULT
public static final java.lang.String[] EXCLUDED_NODE_TYPES_DEFAULT
-
-
Method Detail
-
createPageFilter
public static ItemFilterImpl createPageFilter(java.util.Dictionary properties, RolloutManager rolloutManager)
Creates an ItemFilterImpl from the given Properties with the namePARAMETER_EXCLUDED_NODE_TYPESandPARAMETER_EXCLUDED_PROPERTIES
Properties default to empty.- Parameters:
properties- used for configurationrolloutManager- to access the roll-out reserved settings.- Returns:
- ItemFilterImpl.
-
createComponentFilter
public static ItemFilterImpl createComponentFilter(java.util.Dictionary properties, RolloutManager rolloutManager)
Creates an ItemFilterImpl from the given Properties with the namePARAMETER_EXCLUDED_NODE_TYPESandPARAMETER_EXCLUDED_PARAGRAPH_ITEMS
Properties default to empty.- Parameters:
properties- used for configurationrolloutManager- to access the roll-out reserved settings.- Returns:
- ItemFilterImpl.
-
createPageFilter
public static ItemFilterImpl createPageFilter(ValueMap config, RolloutManager rolloutManager)
Helper method to create a page filter using aValueMap- Parameters:
config-ValueMapof configurationrolloutManager-RolloutManagerrolloutManager- Returns:
ItemFilterImpl- See Also:
createPageFilter(java.util.Dictionary, com.day.cq.wcm.msm.api.RolloutManager)
-
createComponentFilter
public static ItemFilterImpl createComponentFilter(ValueMap config, RolloutManager rolloutManager)
Helper method to create a component filter using aValueMap- Parameters:
config-ValueMapof configurationrolloutManager-RolloutManagerrolloutManager- Returns:
ItemFilterImpl- See Also:
createComponentFilter(java.util.Dictionary, com.day.cq.wcm.msm.api.RolloutManager)
-
createFilter
public static ItemFilterImpl createFilter(java.lang.String[] nodeTypes, java.lang.String[] nodeNames, java.lang.String[] propertyNames, RolloutManager rolloutManager)
Creates an ItemFilterImpl based on a set of patterns that will be used to match NodeTypes, Node names and Property names.- Parameters:
nodeTypes- RegExp pattern of NodeType names to filternodeNames- RegExp pattern of Node names to filterpropertyNames- RegExp pattern of Property Names to filterrolloutManager- aRolloutManagerto serve as the default filter if the above pattern sets are empty- Returns:
- an
ItemFilterImplinstance
-
-