Package org.ametys.odf.observation.skill
Class UpdateProgramSkillStep1Observer
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.odf.observation.skill.AbstractSkillsObserver
org.ametys.odf.observation.skill.AbstractSkillsStepObserver
org.ametys.odf.observation.skill.AbstractContentSkillStep1Observer
org.ametys.odf.observation.skill.UpdateContentSkillStep1Observer
org.ametys.odf.observation.skill.UpdateProgramSkillStep1Observer
- All Implemented Interfaces:
Observer,LogEnabled,Prioritizable,Supporter<Event>,Contextualizable,Serviceable
Observer to store the skills of a program before modification.
When the modified content is a Program, keep its "transversalSkills" in the request to be able to compare them after modification and edit its courses
-
Field Summary
Fields inherited from class org.ametys.odf.observation.skill.AbstractSkillsStepObserver
_contextFields inherited from class org.ametys.odf.observation.skill.AbstractSkillsObserver
_contentDAO, _contentTypesHelperFields inherited from interface org.ametys.core.observation.Observer
MAX_PRIORITY, MIN_PRIORITY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetSkillsAttributeName(Content content) Get the skills attribute namevoidObserveprotected booleansupportsContent(Content content) Check if the content is supportedMethods inherited from class org.ametys.odf.observation.skill.UpdateContentSkillStep1Observer
getSupportedEventIdMethods inherited from class org.ametys.odf.observation.skill.AbstractSkillsStepObserver
_getRequestAttribute, _setRequestAttribute, contextualize, getSkillsToDeleteMethods inherited from class org.ametys.odf.observation.skill.AbstractSkillsObserver
_getSkills, getPriority, service, supportsMethods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Constructor Details
-
UpdateProgramSkillStep1Observer
public UpdateProgramSkillStep1Observer()
-
-
Method Details
-
supportsContent
Description copied from class:AbstractSkillsObserverCheck if the content is supported- Overrides:
supportsContentin classAbstractSkillsObserver- Parameters:
content- The content- Returns:
- a
Boolean,trueif the content is supported,falseotherwise
-
getSkillsAttributeName
Description copied from class:AbstractSkillsObserverGet the skills attribute name- Overrides:
getSkillsAttributeNamein classAbstractSkillsObserver- Parameters:
content- The content- Returns:
- The attribute name for the skills
-
observe
Observe- Specified by:
observein interfaceObserver- Overrides:
observein classAbstractContentSkillStep1Observer- Parameters:
event- the event.transientVars- transientVars passed from one Observer to another when processing a single Event. This may allow optimizations between observers.- Throws:
Exception- if an error occurs. All exceptions will be logged but not propagated, as the observation mechanism should never fail.
-