Class AbstractGetSelectStatesTask
java.lang.Object
ch.tocco.nice2.optional.cms.impl.content.visibility.AbstractGetSelectStatesTask
- All Implemented Interfaces:
PersistTask<PrimaryKey, Map<String, Set<String>>>
- Direct Known Subclasses:
GetSelectedPageStatesTask, GetSelectedWidgetStatesTask
public abstract class AbstractGetSelectStatesTask
extends Object
implements PersistTask<PrimaryKey, Map<String, Set<String>>>
Base class for all tasks, which collect the selected states of a page.
Takes the primary key of a Page_content_to_section entity and returns all selected states.
The returned map contains the ID of a template as key and a set of the selected states as value.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract booleanisSelected(ContentStatus status, PrimaryKey contentToSectionKey, CommandContext commandContext) run(Optional<PrimaryKey> contentToSectionKey, CommandContext commandContext) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface PersistTask
andThenDo, compose, compose2, composeWhen, discardResult, expand, expand, getDescription, ifElse, orWhen, orWhenNot, passWhen, passWhenNot, skipErrors, unwrap
-
Constructor Details
-
AbstractGetSelectStatesTask
-
-
Method Details
-
run
@Nullable public @Nullable Map<String, Set<String>> run(Optional<PrimaryKey> contentToSectionKey, CommandContext commandContext) throws PersistException, InterruptedException - Specified by:
runin interfacePersistTask<PrimaryKey, Map<String, Set<String>>>- Throws:
PersistExceptionInterruptedException
-
isSelected
protected abstract boolean isSelected(ContentStatus status, PrimaryKey contentToSectionKey, CommandContext commandContext) throws PersistException - Throws:
PersistException
-