public abstract class AbstractUIContext extends Object implements UIContext
Constructor and Description |
---|
AbstractUIContext() |
Modifier and Type | Method and Description |
---|---|
org.jboss.forge.furnace.spi.ListenerRegistration<CommandExecutionListener> |
addCommandExecutionListener(CommandExecutionListener listener)
Add a
CommandExecutionListener , returning the ListenerRegistration with which it may subsequently
be removed. |
void |
clearListeners() |
void |
close() |
Map<Object,Object> |
getAttributeMap()
Returns a modifiable map for this
UIContext |
Set<CommandExecutionListener> |
getListeners()
Returns the registered
CommandExecutionListener objects for this UIContext . |
UIProvider |
getProvider()
Returns the
UIProvider that created this UIContext object. |
<SELECTIONTYPE> |
getSelection()
Returns the selection set by
UIContext.setSelection(Object) or UIContext.setSelection(UISelection)
, or if no selection was set for this interaction, the value of UIContext.getInitialSelection() . |
<SELECTIONTYPE> |
setSelection(SELECTIONTYPE selection)
Sets a new selection.
|
<SELECTIONTYPE> |
setSelection(UISelection<SELECTIONTYPE> selection)
Sets a new selection.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getInitialSelection
public <SELECTIONTYPE> UISelection<SELECTIONTYPE> getSelection()
UIContext
UIContext.setSelection(Object)
or UIContext.setSelection(UISelection)
, or if no selection was set for this interaction, the value of UIContext.getInitialSelection()
.
(***WARNING*** - This is NOT the same as UIContext.getInitialSelection()
. It will NOT return
the user's initial selection if a new selection has previously been set via UIContext.setSelection(Object)
or
UIContext.setSelection(UISelection)
.)getSelection
in interface UIContext
UISelection
,
UIContext.getInitialSelection()
public <SELECTIONTYPE> void setSelection(SELECTIONTYPE selection)
UIContext
UISelection
- behavior varies
somewhat depending on the UIProvider
implementation.) The user's selection will be not be changed until
after UICommand.execute(UIExecutionContext)
has completed.setSelection
in interface UIContext
UISelection
public <SELECTIONTYPE> void setSelection(UISelection<SELECTIONTYPE> selection)
UIContext
UISelection
- behavior varies
somewhat depending on the UIProvider
implementation.) The user's selection will be not be changed until
after UICommand.execute(UIExecutionContext)
has completed.setSelection
in interface UIContext
UISelection
public Map<Object,Object> getAttributeMap()
UIContext
UIContext
getAttributeMap
in interface UIContext
public UIProvider getProvider()
UIContext
getProvider
in interface UIContext
public void close()
close
in interface AutoCloseable
public org.jboss.forge.furnace.spi.ListenerRegistration<CommandExecutionListener> addCommandExecutionListener(CommandExecutionListener listener)
UIContext
CommandExecutionListener
, returning the ListenerRegistration
with which it may subsequently
be removed.addCommandExecutionListener
in interface UIContext
public Set<CommandExecutionListener> getListeners()
UIContext
getListeners
in interface UIContext
public void clearListeners()
Copyright © 2014 JBoss by Red Hat. All rights reserved.