Class SynchronizedRootContentHelper
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.plugins.contentio.synchronize.rights.SynchronizedRootContentHelper
- All Implemented Interfaces:
LogEnabled,Component,Serviceable
public class SynchronizedRootContentHelper
extends AbstractLogEnabled
implements Component, Serviceable
Helper for retrieving root of synchronized contents
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected AmetysObjectResolverAmetys object resolverstatic final StringThe root node name of the pluginstatic final StringThe root node name of the imported contentsstatic final StringThe component role. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetRootContent(boolean create) Gets the root of contentsbooleanisChildOfRootContent(Content content) Tests if the given content is child of the root of contents, i.e.voidservice(ServiceManager manager) Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
ROLE
The component role. -
CONTENTIO_ROOT_NODE
The root node name of the plugin- See Also:
-
IMPORTED_CONTENTS_ROOT_NODE
The root node name of the imported contents- See Also:
-
_resolver
Ametys object resolver
-
-
Constructor Details
-
SynchronizedRootContentHelper
public SynchronizedRootContentHelper()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Throws:
ServiceException
-
getRootContent
Gets the root of contents- Parameters:
create-trueto create automatically the root when missing.- Returns:
- the root of contents
- Throws:
UnknownAmetysObjectException- If root node does not exist
-
isChildOfRootContent
Tests if the given content is child of the root of contents, i.e. the given content is managed by the CMS workspace- Parameters:
content- The content to test- Returns:
- true if the given content is child of the root of contents
-