public interface ContextSensitiveHandler
ContextSensitiveAction
s.
For a detailed explanation see ContextSensitiveAction
.
ContextSensitiveAction
,
ContextSensitiveHandlerChangeListener
Modifier and Type | Method and Description |
---|---|
default boolean |
isContextSensitiveHandlerEnabled(Class<? extends ContextSensitiveHandler> type)
Returns the base enabled state of the handler.
|
default boolean isContextSensitiveHandlerEnabled(Class<? extends ContextSensitiveHandler> type)
true
.
The type parameter is used to identify the handler type since one Object can implement multiple handler interfaces.
public boolean isContextSensitiveHandlerEnabled( final Class<? extends ContextSensitiveHandler> type) { if(type == SaveHandler.class) { return getCurrentUser().canWrite(); } return true; }
type
- the handler typetrue
if this handler is active and ready to be used,
false
otherwise