Class DefaultIndexableComposite
java.lang.Object
org.ametys.plugins.repository.data.holder.group.impl.DefaultModelAwareComposite
org.ametys.cms.data.holder.group.impl.DefaultIndexableComposite
- All Implemented Interfaces:
IndexableComposite,IndexableDataHolder,DataHolder,Composite,ModelAwareComposite,ModelAwareDataHolder
public class DefaultIndexableComposite
extends DefaultModelAwareComposite
implements IndexableComposite
Class for indexable model aware composites
-
Field Summary
Fields inherited from class org.ametys.plugins.repository.data.holder.group.impl.DefaultModelAwareComposite
_defaultDataHolder, _definition, _repositoryDataFields inherited from interface org.ametys.plugins.repository.data.holder.ModelAwareDataHolder
ALTERNATIVE_SUFFIX, STATUS_SUFFIX -
Constructor Summary
ConstructorsConstructorDescriptionDefaultIndexableComposite(RepositoryData repositoryData, ModelItemGroup definition, IndexableDataHolder parent, IndexableDataHolder root) Creates a default indexable composite -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the default implementation of aDataHolderto usegetExternalRepeater(String repeaterPath) Retrieves the external repeater at the given pathgetLocalRepeater(String repeaterPath) Retrieves the local repeater at the given pathgetRepeater(String repeaterPath) Retrieves the repeater at the given pathMethods inherited from class org.ametys.plugins.repository.data.holder.group.impl.DefaultModelAwareComposite
getRepositoryDataMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ametys.plugins.repository.data.holder.group.Composite
dataToSAX, getValue, getValueOrDefault, hasValue, hasValueOrEmptyMethods inherited from interface org.ametys.plugins.repository.data.holder.DataHolder
copyTo, copyTo, dataToJSON, dataToSAX, getRepositoryDataMethods inherited from interface org.ametys.cms.data.holder.group.IndexableComposite
getComposite, getExternalComposite, getLocalComposite, getParentDataHolder, getRootDataHolderMethods inherited from interface org.ametys.plugins.repository.data.holder.group.ModelAwareComposite
dataToJSON, dataToJSON, dataToJSON, dataToJSONForEdition, dataToMap, dataToSAX, dataToSAX, dataToSAXForEdition, getDataNames, getDefinition, getDifferences, getDifferences, getDifferences, getDifferences, getExternalValue, getLocalValue, getModel, getModelItemTypeExtensionPoint, getStatus, getType, getValueOfType, getValueOfTypeOrDefault, getValueOrDefault, getValueWithMultiValuedPathSegments, hasDefinition, hasDifferences, hasDifferences, hasDifferences, hasDifferences, hasExternalValue, hasExternalValueOrEmpty, hasLocalValue, hasLocalValueOrEmpty, hasValue, isMultiple, isMultipleMethods inherited from interface org.ametys.plugins.repository.data.holder.ModelAwareDataHolder
dataToJSON, dataToJSON, dataToMap, dataToMap, dataToMap, dataToSAX, dataToSAX
-
Constructor Details
-
DefaultIndexableComposite
public DefaultIndexableComposite(RepositoryData repositoryData, ModelItemGroup definition, IndexableDataHolder parent, IndexableDataHolder root) Creates a default indexable composite- Parameters:
repositoryData- the repository data of the compositedefinition- the definition of the compositeparent- the parent of the createdCompositeroot- the rootIndexableDataHolder
-
-
Method Details
-
getDefaultDataHolder
Description copied from interface:CompositeRetrieves the default implementation of aDataHolderto use- Specified by:
getDefaultDataHolderin interfaceComposite- Specified by:
getDefaultDataHolderin interfaceIndexableComposite- Specified by:
getDefaultDataHolderin interfaceModelAwareComposite- Overrides:
getDefaultDataHolderin classDefaultModelAwareComposite- Returns:
- the
DataHolder
-
getRepeater
public IndexableRepeater getRepeater(String repeaterPath) throws IllegalArgumentException, UndefinedItemPathException, BadItemTypeException, BadDataPathCardinalityException Description copied from interface:ModelAwareDataHolderRetrieves the repeater at the given path- Specified by:
getRepeaterin interfaceIndexableComposite- Specified by:
getRepeaterin interfaceIndexableDataHolder- Specified by:
getRepeaterin interfaceModelAwareComposite- Specified by:
getRepeaterin interfaceModelAwareDataHolder- Parameters:
repeaterPath- path of the repeater to retrieve- Returns:
- the repeater or
nullif not exists or is empty - Throws:
IllegalArgumentException- if the given repeater path is null or emptyUndefinedItemPathException- if the given repeater path is not defined by the modelBadItemTypeException- if the stored value at the given path is not a repeaterBadDataPathCardinalityException- if the definition of a part of the data path is multiple. Only the last part can be multiple
-
getLocalRepeater
public IndexableRepeater getLocalRepeater(String repeaterPath) throws IllegalArgumentException, UndefinedItemPathException, BadItemTypeException, BadDataPathCardinalityException Description copied from interface:ModelAwareDataHolderRetrieves the local repeater at the given path- Specified by:
getLocalRepeaterin interfaceIndexableComposite- Specified by:
getLocalRepeaterin interfaceIndexableDataHolder- Specified by:
getLocalRepeaterin interfaceModelAwareComposite- Specified by:
getLocalRepeaterin interfaceModelAwareDataHolder- Parameters:
repeaterPath- path of the externalizable repeater to retrieve- Returns:
- the repeater or
nullif not exists or is empty - Throws:
IllegalArgumentException- if the given repeater path is null or emptyUndefinedItemPathException- if the given repeater path is not defined by the modelBadItemTypeException- if the stored value at the given path is not a repeaterBadDataPathCardinalityException- if the definition of a part of the data path is multiple. Only the last part can be multiple
-
getExternalRepeater
public IndexableRepeater getExternalRepeater(String repeaterPath) throws IllegalArgumentException, UndefinedItemPathException, BadItemTypeException, BadDataPathCardinalityException Description copied from interface:ModelAwareDataHolderRetrieves the external repeater at the given path- Specified by:
getExternalRepeaterin interfaceIndexableComposite- Specified by:
getExternalRepeaterin interfaceIndexableDataHolder- Specified by:
getExternalRepeaterin interfaceModelAwareComposite- Specified by:
getExternalRepeaterin interfaceModelAwareDataHolder- Parameters:
repeaterPath- path of the externalizable repeater to retrieve- Returns:
- the repeater or
nullif not exists or is empty - Throws:
IllegalArgumentException- if the given repeater path is null or emptyUndefinedItemPathException- if the given repeater path is not defined by the modelBadItemTypeException- if the stored value at the given path is not a repeaterBadDataPathCardinalityException- if the definition of a part of the data path is multiple. Only the last part can be multiple
-