KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > hudson > model > Action


1 package hudson.model;
2
3 import hudson.tasks.test.TestResultProjectAction;
4
5 import java.io.Serializable JavaDoc;
6
7 /**
8  * Object that contributes an item to the left hand side menu
9  * of a {@link ModelObject}
10  * (for example to {@link Project}, {@link Build}, and etc.)
11  *
12  * <p>
13  * If an action has a view named <tt>floatBox.jelly</tt>,
14  * it will be displayed as a floating box on the top page of
15  * the target {@link ModelObject}. (For example, this is how
16  * the JUnit test result trend shows up in the project top page.
17  * See {@link TestResultProjectAction}.
18  *
19  * <p>
20  * Actions are often serialized as a part of {@link Actionable}
21  * (for example with {@link Build}.) In some other cases,
22  * {@link Action}s are transient and not persisted (such as
23  * when it's used with {@link Job}).
24  *
25  * @author Kohsuke Kawaguchi
26  */

27 public interface Action extends Serializable JavaDoc, ModelObject {
28     /**
29      * Gets the file name of the icon (relative to /images/24x24).
30      *
31      * @return
32      * null to hide it from the task list. This is normally not very useful,
33      * but this can be used for actions that only contribute <tt>floatBox.jelly</tt>
34      * and no task list item.
35      */

36     String JavaDoc getIconFileName();
37
38     /**
39      * Gets the string to be displayed.
40      *
41      * The convention is to capitalize the first letter of each word,
42      * such as "Test Result".
43      */

44     String JavaDoc getDisplayName();
45
46     /**
47      * Gets the URL path name.
48      */

49     String JavaDoc getUrlName();
50 }
51
Popular Tags