Package org.apache.sling.cms
Interface ComponentPolicy
public interface ComponentPolicy
A class to represent a component policy, e.g. the definition of what
components are available for a particular container and their shared
configurations.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanapplies(org.apache.sling.api.resource.Resource resource) Returns true if the ComponentPolicy applies to the specified resourceString[]Gets the list of Component Types which will be available when using this component policyGets the Component Configurations when using this component policy
-
Method Details
-
applies
boolean applies(org.apache.sling.api.resource.Resource resource) Returns true if the ComponentPolicy applies to the specified resource- Parameters:
resource- the resource to check- Returns:
- true if this policy should be enabled for the resource, false if not
-
getAvailableComponentTypes
String[] getAvailableComponentTypes()Gets the list of Component Types which will be available when using this component policy- Returns:
- the available ComponentTypes
-
getComponentConfigs
Gets the Component Configurations when using this component policy- Returns:
- the componentConfigs
-