Package ch.tocco.nice2.netui.spi.actions
Class AbstractActionFactory
java.lang.Object
ch.tocco.nice2.netui.spi.actions.AbstractActionFactory
- All Implemented Interfaces:
ActionFactory
- Direct Known Subclasses:
AbstractEntityActionsFactory
,AbstractModelActionFactory
,AcceptConflictActionFactory
,ActionsModelFactory
,EntityMergeActionFactory
,EvaluationQuestionLogicCopyActionFactory
,EventLogicCopyActionFactory
,ExportingActionFactory
,GenericLabelActionFactory
,GridUserSettingActionFactory
,HistoryActionFactory
,ImportingActionFactory
,OpenDmsNodeActionFactory
,OrderPositionActionFactory
,QuestionLogicCopyActionFactory
,QuestionnaireLogicCopyActionFactory
,ReportingLogicCopyActionFactory
,RoomProposalActionFactory
,ShowDocumentsActionFactory
,SingleMarkActionFactory
,ZipFileImportActionFactory
-
Field Summary
Fields inherited from interface ch.tocco.nice2.netui.spi.actions.ActionFactory
DISABLE_ACTION, HIGH_PRIORITY, LOW_PRIORITY, PERFORM_DENIED_KEY, REMOVE_ACTION
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
addSeparator
(List<ActionModel> actionList) protected ActionModel
addToList
(List<ActionModel> actionList, @Nullable ActionModel action) Adds the action preserving the order as they were added to this list.protected Collection
<ActionModel> asCollection
(ActionModel... actions) Adds the given actions to a collection.protected @Nullable String
getEntityName
(Situation sit) Returns the entity-name if it is available via the specified situation object.protected @Nullable String
getPrimaryKey
(Situation sit) Returns the primary key if it is available from the specified situation.Returns aPredicate
which evaluates totrue
, if the appliedSituation
is providing a entity name (likeSituationWithEntityName
for list forms orSituationWithEntity
for detail forms) and the entity name equals the specified entity name.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.netui.spi.actions.ActionFactory
createActions
-
Field Details
-
actionBuilder
-
-
Constructor Details
-
AbstractActionFactory
-
-
Method Details
-
addToList
protected ActionModel addToList(List<ActionModel> actionList, @Nullable @Nullable ActionModel action) Adds the action preserving the order as they were added to this list.If the position property is set, it will not be changed.
- Parameters:
action
- the action to add, may be null so nothing is added- Returns:
- the action that was added to the list (and potentially the position property changed)
-
addSeparator
-
asCollection
Adds the given actions to a collection. -
isScope
-
isScreen
-
isPlace
-
isEntity
Returns aPredicate
which evaluates totrue
, if the appliedSituation
is providing a entity name (likeSituationWithEntityName
for list forms orSituationWithEntity
for detail forms) and the entity name equals the specified entity name. -
isForm
-
getEntityName
Returns the entity-name if it is available via the specified situation object. Returns null, if entityname is null or the situation is not capable of storing entity-names. -
getPrimaryKey
Returns the primary key if it is available from the specified situation. Returnsnull
if the primary key is null or the situation is not capable of holding a primary key (for example if we are in situation "EntityList").
-