Package hudson.model
Class TransientProjectActionFactory
- java.lang.Object
-
- hudson.model.TransientProjectActionFactory
-
- All Implemented Interfaces:
ExtensionPoint
public abstract class TransientProjectActionFactory extends Object implements ExtensionPoint
Extension point for inserting transientAction
s intoAbstractProject
s.Actions of projects are primarily determined by
BuildStep
s that are associated by configurations, but sometimes it's convenient to be able to add actions across all or many projects, without being invoked through configuration. This extension point provides such a mechanism. Actions ofAbstractProject
s are transient — they will not be persisted, and each time Hudson starts or the configuration of the job changes, they'll be recreated. Therefore, to maintain persistent data per project, you'll need to do data serialization by yourself. Do so by storing a file underAbstractItem.getRootDir()
.To register your implementation, put
Extension
on your subtype.- Since:
- 1.327
- Author:
- Kohsuke Kawaguchi
- See Also:
Action
,TransientActionFactory
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Constructor Summary
Constructors Constructor Description TransientProjectActionFactory()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static ExtensionList<TransientProjectActionFactory>
all()
Returns all the registeredTransientProjectActionFactory
s.abstract Collection<? extends Action>
createFor(AbstractProject target)
Creates actions for the given project.
-
-
-
Method Detail
-
createFor
public abstract Collection<? extends Action> createFor(AbstractProject target)
Creates actions for the given project.- Parameters:
target
- The project for which the action objects are requested. Never null.- Returns:
- Can be empty but must not be null.
-
all
public static ExtensionList<TransientProjectActionFactory> all()
Returns all the registeredTransientProjectActionFactory
s.
-
-