Spring Web Flow

org.springframework.webflow.execution.factory
Class StaticFlowExecutionListenerLoader

java.lang.Object
  extended by org.springframework.webflow.execution.factory.StaticFlowExecutionListenerLoader
All Implemented Interfaces:
FlowExecutionListenerLoader

public final class StaticFlowExecutionListenerLoader
extends java.lang.Object
implements FlowExecutionListenerLoader

A simple flow execution listener loader that simply returns a static listener array on each invocation. For more elaborate needs see the ConditionalFlowExecutionListenerLoader.

Author:
Keith Donald
See Also:
ConditionalFlowExecutionListenerLoader

Field Summary
static FlowExecutionListenerLoader EMPTY_INSTANCE
          A shared listener loader instance that returns am empty listener array on each invocation.
 
Constructor Summary
StaticFlowExecutionListenerLoader(FlowExecutionListener... listeners)
          Creates a new flow execution listener loader that returns the provided listener array on each invocation.
StaticFlowExecutionListenerLoader(FlowExecutionListener listener)
          Creates a new flow execution listener loader that returns the provided listener on each invocation.
 
Method Summary
 FlowExecutionListener[] getListeners(FlowDefinition flowDefinition)
          Get the flow execution listeners that apply to the given flow definition.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EMPTY_INSTANCE

public static final FlowExecutionListenerLoader EMPTY_INSTANCE
A shared listener loader instance that returns am empty listener array on each invocation.

Constructor Detail

StaticFlowExecutionListenerLoader

public StaticFlowExecutionListenerLoader(FlowExecutionListener listener)
Creates a new flow execution listener loader that returns the provided listener on each invocation.

Parameters:
listener - the listener

StaticFlowExecutionListenerLoader

public StaticFlowExecutionListenerLoader(FlowExecutionListener... listeners)
Creates a new flow execution listener loader that returns the provided listener array on each invocation. Clients should not attempt to modify the passed in array as no deep copy is made.

Parameters:
listeners - the listener array.
Method Detail

getListeners

public FlowExecutionListener[] getListeners(FlowDefinition flowDefinition)
Description copied from interface: FlowExecutionListenerLoader
Get the flow execution listeners that apply to the given flow definition.

Specified by:
getListeners in interface FlowExecutionListenerLoader
Parameters:
flowDefinition - the flow definition
Returns:
the listeners that apply

Spring Web Flow