Class PublishSnippetTask
java.lang.Object
ch.tocco.nice2.optional.cms.impl.content.persist.PublishSnippetTask
- All Implemented Interfaces:
PersistTask<Entity,
Void>
This task publishes a snippet:
* get published section of snippet and delete it
* duplicate unpublished section and link the copy as published section
-
Constructor Summary
ConstructorDescriptionPublishSnippetTask
(CascadingDeleteService cascadingDeleteService, CopyWidgetConfigService copyWidgetConfigService, SecurityManager securityManager) -
Method Summary
Modifier and TypeMethodDescription@Nullable Void
run
(Optional<Entity> snippet, CommandContext commandContext) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface ch.tocco.nice2.persist.core.api.exec.PersistTask
andThenDo, compose, compose2, composeWhen, discardResult, expand, expand, getDescription, ifElse, orWhen, orWhenNot, passWhen, passWhenNot, skipErrors, unwrap
-
Constructor Details
-
PublishSnippetTask
public PublishSnippetTask(CascadingDeleteService cascadingDeleteService, CopyWidgetConfigService copyWidgetConfigService, SecurityManager securityManager)
-
-
Method Details
-
run
@Nullable public @Nullable Void run(Optional<Entity> snippet, CommandContext commandContext) throws Exception - Specified by:
run
in interfacePersistTask<Entity,
Void> - Throws:
Exception
-