Package org.ametys.odf.restriction
Class RepeaterWithEducationalPathRestriction
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.cms.model.restrictions.DefaultRestriction
org.ametys.odf.restriction.RepeaterWithEducationalPathRestriction
- All Implemented Interfaces:
Restriction
,LogEnabled
,Component
,Configurable
,Contextualizable
,Serviceable
public class RepeaterWithEducationalPathRestriction
extends DefaultRestriction
implements Contextualizable
Restrictions for a repeater with educational path or for data in a repeater with educational
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.ametys.cms.model.restrictions.Restriction
Restriction.RestrictionResult
-
Field Summary
Fields inherited from class org.ametys.cms.model.restrictions.DefaultRestriction
_currentUserProvider, _rightManager, _workflowProvider
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
_hasRights
(Content content, Set<String> rightLimitations) Check if current user has the given rights.canRead
(Content content, RestrictedModelItem modelItem) Determine whether a model item can be read at this time.canWrite
(Content content, RestrictedModelItem modelItem) Determine whether a model item can be written at this time.void
configure
(Configuration configuration) void
contextualize
(Context context) void
service
(ServiceManager smanager) Methods inherited from class org.ametys.cms.model.restrictions.DefaultRestriction
_isInWorkflowStep
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Constructor Details
-
RepeaterWithEducationalPathRestriction
-
-
Method Details
-
configure
- Specified by:
configure
in interfaceConfigurable
- Overrides:
configure
in classDefaultRestriction
- Throws:
ConfigurationException
-
service
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classDefaultRestriction
- Throws:
ServiceException
-
contextualize
- Specified by:
contextualize
in interfaceContextualizable
- Throws:
ContextException
-
canRead
Description copied from interface:Restriction
Determine whether a model item can be read at this time.- Specified by:
canRead
in interfaceRestriction
- Overrides:
canRead
in classDefaultRestriction
- Parameters:
content
- The content where item is to be written on. Can be null, on content creation.modelItem
- the model item on which check the restrictions- Returns:
- The restriction result
-
canWrite
Description copied from interface:Restriction
Determine whether a model item can be written at this time.- Specified by:
canWrite
in interfaceRestriction
- Overrides:
canWrite
in classDefaultRestriction
- Parameters:
content
- The content where item is to be written on. Can be null, on content creation.modelItem
- the model item on which check the restrictions- Returns:
- The restriction result
-
_hasRights
Description copied from class:DefaultRestriction
Check if current user has the given rights.- Overrides:
_hasRights
in classDefaultRestriction
- Parameters:
content
- the content.rightLimitations
- the right limitations.- Returns:
true
if user has at least one right,false
otherwise.
-