KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > kohsuke > stapler > Ancestor


1 package org.kohsuke.stapler;
2
3 import javax.servlet.http.HttpServletRequest JavaDoc;
4
5 /**
6  * Information about ancestor of the "it" node.
7  *
8  * @author Kohsuke Kawaguchi
9  */

10 public interface Ancestor {
11     /**
12      * Gets the model object of the application.
13      */

14     Object JavaDoc getObject();
15
16     /**
17      * Gets the URL to this ancestor.
18      *
19      * <p>
20      * The returned string represents the portion of the request URL
21      * that matches this object. It starts with
22      * {@link HttpServletRequest#getContextPath() context path},
23      * and it ends without '/'. So, for example, if your web app
24      * is deployed as "mywebapp" and this ancestor object is
25      * obtained from the app root object by <tt>getFoo().getBar(3)</tt>,
26      * then this string will be <tt>/mywebapp/foo/bar/3</tt>
27      *
28      * @return
29      * never null.
30      */

31     String JavaDoc getUrl();
32
33     /**
34      * Gets the previous ancestor, or null if none (meaning
35      * this is the root object.)
36      */

37     Ancestor getPrev();
38
39     /**
40      * Gets the next ancestor, or null if none (meaning
41      * this is the 'it' object.
42      */

43     Ancestor getNext();
44 }
45
Popular Tags