Class LifecycleFactoryImpl
- java.lang.Object
-
- jakarta.faces.lifecycle.LifecycleFactory
-
- com.sun.faces.lifecycle.LifecycleFactoryImpl
-
- All Implemented Interfaces:
FacesWrapper<LifecycleFactory>
public class LifecycleFactoryImpl extends LifecycleFactory
LifecycleFactoryImpl is the stock implementation of Lifecycle in Mojarra.- See Also:
LifecycleFactory
-
-
Field Summary
Fields Modifier and Type Field Description protected ConcurrentHashMap<String,Lifecycle>
lifecycleMap
-
Fields inherited from class jakarta.faces.lifecycle.LifecycleFactory
DEFAULT_LIFECYCLE
-
-
Constructor Summary
Constructors Constructor Description LifecycleFactoryImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addLifecycle(String lifecycleId, Lifecycle lifecycle)
Register a newLifecycle
instance, associated with the specifiedlifecycleId
, to be supported by thisLifecycleFactory
.Lifecycle
getLifecycle(String lifecycleId)
Create (if needed) and return aLifecycle
instance for the specified lifecycle identifier.Iterator<String>
getLifecycleIds()
Return anIterator
over the set of lifecycle identifiers supported by this factory.-
Methods inherited from class jakarta.faces.lifecycle.LifecycleFactory
getWrapped
-
-
-
-
Field Detail
-
lifecycleMap
protected ConcurrentHashMap<String,Lifecycle> lifecycleMap
-
-
Method Detail
-
addLifecycle
public void addLifecycle(String lifecycleId, Lifecycle lifecycle)
Description copied from class:LifecycleFactory
Register a new
Lifecycle
instance, associated with the specifiedlifecycleId
, to be supported by thisLifecycleFactory
. This method may be called at any time, and makes the correspondingLifecycle
instance available throughout the remaining lifetime of this web application.- Specified by:
addLifecycle
in classLifecycleFactory
- Parameters:
lifecycleId
- Identifier of the newLifecycle
lifecycle
-Lifecycle
instance that we are registering
-
getLifecycle
public Lifecycle getLifecycle(String lifecycleId) throws FacesException
Description copied from class:LifecycleFactory
Create (if needed) and return a
Lifecycle
instance for the specified lifecycle identifier. The set of available lifecycle identifiers is available via thegetLifecycleIds()
method.Each call to
getLifecycle()
for the samelifecycleId
, from within the same web application, must return the sameLifecycle
instance.- Specified by:
getLifecycle
in classLifecycleFactory
- Parameters:
lifecycleId
- Lifecycle identifier of the requestedLifecycle
instance- Returns:
- the
Lifecycle
instance - Throws:
FacesException
-
getLifecycleIds
public Iterator<String> getLifecycleIds()
Description copied from class:LifecycleFactory
Return an
Iterator
over the set of lifecycle identifiers supported by this factory. This set must include the value specified byLifecycleFactory.DEFAULT_LIFECYCLE
.- Specified by:
getLifecycleIds
in classLifecycleFactory
- Returns:
- an
Iterator
over the set of lifecycle identifiers supported by this factory
-
-