Top Description Methods
jakarta.faces.component

public Interface ActionSource

Known Direct Subinterfaces
jakarta.faces.component.ActionSource2
Imports
jakarta.faces.event.ActionEvent, .ActionListener

ActionSource is an interface that may be implemented by any concrete UIComponent that wishes to be a source of ActionEvents, including the ability to invoke application actions via the default ActionListener mechanism.

Method Summary

Modifier and TypeMethod and Description
public void
addActionListener(ActionListener
The ActionListener to be added
listener
)

Add a new ActionListener to the set of listeners interested in being notified when ActionEvents occur.

public ActionListener[]

Returns:

the action listeners, or a zero-length array.
getActionListeners
()

Return the set of registered ActionListeners for this ActionSource instance.

public boolean

Returns:

true if immediate, false otherwise.
isImmediate
()

Return a flag indicating that the default ActionListener provided by the Jakarta Faces implementation should be executed immediately (that is, during Apply Request Values phase of the request processing lifecycle), rather than waiting until the Invoke Application phase.

public void
removeActionListener(ActionListener
The ActionListener to be removed
listener
)

Remove an existing ActionListener (if any) from the set of listeners interested in being notified when ActionEvents occur.

public void
setImmediate(boolean
The new immediate execution flag
immediate
)

Set the "immediate execution" flag for this UIComponent.

Method Detail

addActionListenerback to summary
public void addActionListener(ActionListener listener)

Add a new ActionListener to the set of listeners interested in being notified when ActionEvents occur.

Parameters
listener:ActionListener

The ActionListener to be added

Exceptions
NullPointerException:
if listener is null
getActionListenersback to summary
public ActionListener[] getActionListeners()

Return the set of registered ActionListeners for this ActionSource instance. If there are no registered listeners, a zero-length array is returned.

Returns:ActionListener[]

the action listeners, or a zero-length array.

isImmediateback to summary
public boolean isImmediate()

Return a flag indicating that the default ActionListener provided by the Jakarta Faces implementation should be executed immediately (that is, during Apply Request Values phase of the request processing lifecycle), rather than waiting until the Invoke Application phase. The default value for this property must be false.

Returns:boolean

true if immediate, false otherwise.

removeActionListenerback to summary
public void removeActionListener(ActionListener listener)

Remove an existing ActionListener (if any) from the set of listeners interested in being notified when ActionEvents occur.

Parameters
listener:ActionListener

The ActionListener to be removed

Exceptions
NullPointerException:
if listener is null
setImmediateback to summary
public void setImmediate(boolean immediate)

Set the "immediate execution" flag for this UIComponent.

Parameters
immediate:boolean

The new immediate execution flag