|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthudson.model.AbstractModelObject
hudson.model.Actionable
@ExportedBean public abstract class Actionable
ModelObject that can have additional Actions.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface jenkins.model.ModelObjectWithContextMenu |
|---|
ModelObjectWithContextMenu.ContextMenu, ModelObjectWithContextMenu.MenuItem |
| Constructor Summary | |
|---|---|
Actionable()
|
|
| Method Summary | ||
|---|---|---|
void |
addAction(Action a)
Adds a new action. |
|
ModelObjectWithContextMenu.ContextMenu |
doContextMenu(org.kohsuke.stapler.StaplerRequest request,
org.kohsuke.stapler.StaplerResponse response)
Generates the context menu. |
|
|
getAction(Class<T> type)
Gets the action (first instance to be found) of a specified type that contributed to this build. |
|
Action |
getAction(int index)
|
|
List<Action> |
getActions()
Gets actions contributed to this build. |
|
|
getActions(Class<T> type)
Gets all actions of a specified type that contributed to this build. |
|
Object |
getDynamic(String token,
org.kohsuke.stapler.StaplerRequest req,
org.kohsuke.stapler.StaplerResponse rsp)
|
|
| Methods inherited from class hudson.model.AbstractModelObject |
|---|
getSearch, getSearchIndex, getSearchName, makeSearchIndex, requirePOST, sendError, sendError, sendError, sendError, sendError |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface hudson.model.ModelObject |
|---|
getDisplayName |
| Methods inherited from interface hudson.search.SearchItem |
|---|
getSearchUrl |
| Constructor Detail |
|---|
public Actionable()
| Method Detail |
|---|
@Exported public List<Action> getActions()
A new Action can be added by getActions().add(...).
public <T extends Action> List<T> getActions(Class<T> type)
type - The type of action to return.
getAction(Class)public void addAction(Action a)
public Action getAction(int index)
public <T extends Action> T getAction(Class<T> type)
type -
null if no such actions exist.getActions(Class)
public Object getDynamic(String token,
org.kohsuke.stapler.StaplerRequest req,
org.kohsuke.stapler.StaplerResponse rsp)
public ModelObjectWithContextMenu.ContextMenu doContextMenu(org.kohsuke.stapler.StaplerRequest request,
org.kohsuke.stapler.StaplerResponse response)
throws Exception
ModelObjectWithContextMenureturn new ContextMenu().from(this,request,response);,
which implements the default behaviour. See ModelObjectWithContextMenu.ContextMenu.from(ModelObjectWithContextMenu, StaplerRequest, StaplerResponse)
for more details of what it does. This should suit most implementations.
doContextMenu in interface ModelObjectWithContextMenuException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||