Interface ExperienceFragment
- All Superinterfaces:
Component,ComponentExporter,ContainerExporter
Defines the
ExperienceFragment Sling Model used for the
/apps/core/wcm/components/experiencefragment component.- Since:
- com.adobe.cq.wcm.core.components.models 12.9.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringName of the configuration policy property that specifies the experience fragment variation path. -
Method Summary
Modifier and TypeMethodDescriptiondefault @Nullable StringGenerates some container class names (needed for SPA framework)default @NotNull Map<String, ? extends ComponentExporter> Returns the map of all exported child items (resource names from Sling Model classes).default @NotNull String[]Returns the order of items in the map.default @NotNull StringReturns the type of the resource for which the export is performed.default StringReturns the localized path of the experience fragment variation if the experience fragment resource is defined in the template.default StringgetName()Returns the technical name of the experience fragment.default booleanSimple boolean flag to check if the experience fragment variation and its underlying experience fragment is configured.Methods inherited from interface com.adobe.cq.wcm.core.components.models.Component
getAppliedCssClasses, getData, getId
-
Field Details
-
PN_FRAGMENT_VARIATION_PATH
Name of the configuration policy property that specifies the experience fragment variation path. The property should provide aStringvalue.- Since:
- com.adobe.cq.wcm.core.components.models 12.9.0
- See Also:
-
-
Method Details
-
getLocalizedFragmentVariationPath
Returns the localized path of the experience fragment variation if the experience fragment resource is defined in the template. If not, it returns the configured fragment path if it exists,nullotherwise. If both the content page and the experience fragment have a localized root (language, live copy or blueprint), - it is then assumed that the content pages and the experience fragments follow the same structure patterns - this method returns the localized path of the experience fragment based on the localization of the content page if it exists, otherwise it returns the fragment path that is configured, suffixed with "/jcr:content".- Returns:
- Localized experience fragment variation path
- Since:
- com.adobe.cq.wcm.core.components.models 12.9.0
-
getName
Returns the technical name of the experience fragment.- Returns:
- the technical name of the experience fragment
- Since:
- com.adobe.cq.wcm.core.components.models 12.11.0
-
getCssClassNames
Generates some container class names (needed for SPA framework)- Returns:
- Css Class names
- Since:
- com.adobe.cq.wcm.core.components.models 12.15.0
-
isConfigured
default boolean isConfigured()Simple boolean flag to check if the experience fragment variation and its underlying experience fragment is configured. If the localizedFragmentVariationPath path is not configured or the children are empty, this wis will return false.- Returns:
- localizedFragmentVariationPath is configured and has entries
- Since:
- com.adobe.cq.wcm.core.components.models 12.15.0
-
getExportedType
Description copied from interface:ComponentExporterReturns the type of the resource for which the export is performed.
NOTE: methods whose JSON serialization would lead to the same JSON property name (":type") will not be serialized.
- Specified by:
getExportedTypein interfaceComponent- Specified by:
getExportedTypein interfaceComponentExporter- Returns:
- the type of the component
- Since:
- com.adobe.cq.wcm.core.components.models 12.9.0
- See Also:
-
getExportedItemsOrder
Description copied from interface:ContainerExporterReturns the order of items in the map.
NOTE: This information is required because the JSON specification and most implementations don't provide a stable order of items in JSON objects. Methods whose JSON serialization would lead to the same JSON property name (":order") will not be serialized.
- Specified by:
getExportedItemsOrderin interfaceContainerExporter- Returns:
- the order of the items in the map; the array can be empty if the item order is not provided by the underlying persistence layer
- Since:
- com.adobe.cq.wcm.core.components.models 12.15.0
- See Also:
-
getExportedItems
Description copied from interface:ContainerExporterReturns the map of all exported child items (resource names from Sling Model classes).
NOTE: Methods whose JSON serialization would lead to the same JSON property name (":items") will not be serialized.
- Specified by:
getExportedItemsin interfaceContainerExporter- Returns:
- the map of all exported child items
- Since:
- com.adobe.cq.wcm.core.components.models 12.15.0
- See Also:
-