public abstract class AbstractDocumentCommand extends AbstractPageViewCommand
Modifier and Type | Class and Description |
---|---|
static class |
AbstractDocumentCommand.Scope |
Constructor and Description |
---|
AbstractDocumentCommand() |
Modifier and Type | Method and Description |
---|---|
protected boolean |
canExecute()
Subclasses may override this method to perform argument validation beyond the validation that
happens automatically during the injection phase.
|
protected RenderControls |
getRenderControls(boolean create)
Return a
RenderControls for the current scope . |
AbstractDocumentCommand.Scope |
getScope() |
void |
setScope(AbstractDocumentCommand.Scope scope) |
getPageView, setPageView
getContext, propagateContextChange, setContext
canExecute, execute, execute, getKey, isAvailable, isSelected, isSelected, setKey
protected Document document
protected boolean canExecute()
InjectedCommand
Argument
annotations and the
arguments have been injected.canExecute
in class InjectedCommand
true
if the command can/may be executed in the current context,
false
otherwise.public void setScope(AbstractDocumentCommand.Scope scope)
public AbstractDocumentCommand.Scope getScope()
protected RenderControls getRenderControls(boolean create)
RenderControls
for the current scope
.
Depending on the scope this method will either return the document controls of the current
document or the page controls for the current page in the target PageView
.
create
- if the command should work in a per-page way ( getScope()
==
AbstractDocumentCommand.Scope.PAGE
) and no page control is available, this parameter decides whether
to create a new render controls for the page or to return the document render
controls.Copyright © 2024 levigo holding gmbh. All rights reserved.