View Javadoc

1   /*
2    * $Id: MenuItem.java 527870 2007-04-12 10:19:41Z apetrelli $
3    *
4    * Licensed to the Apache Software Foundation (ASF) under one
5    * or more contributor license agreements.  See the NOTICE file
6    * distributed with this work for additional information
7    * regarding copyright ownership.  The ASF licenses this file
8    * to you under the Apache License, Version 2.0 (the
9    * "License"); you may not use this file except in compliance
10   * with the License.  You may obtain a copy of the License at
11   *
12   * http://www.apache.org/licenses/LICENSE-2.0
13   *
14   * Unless required by applicable law or agreed to in writing,
15   * software distributed under the License is distributed on an
16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17   * KIND, either express or implied.  See the License for the
18   * specific language governing permissions and limitations
19   * under the License.
20   */
21  package org.apache.tiles.beans;
22  
23  import java.io.Serializable;
24  
25  /**
26   * Interface for MenuItems.
27   *
28   * @see SimpleMenuItem
29   * @version $Rev: 527870 $ $Date: 2007-04-12 20:19:41 +1000 (Thu, 12 Apr 2007) $
30   */
31  public interface MenuItem extends Serializable {
32  
33      /**
34       * Sets the value (i.e. the visible part) of this menu item.
35       *
36       * @param value The value of this item.
37       */
38      void setValue(String value);
39  
40      /**
41       * Returns the value (i.e. the visible part) of this menu item.
42       *
43       * @return The value of this item.
44       */
45      String getValue();
46  
47      /**
48       * Sets the URL of this menu item.
49       *
50       * @param link The URL of this item.
51       */
52      void setLink(String link);
53  
54      /**
55       * Returns the URL of this menu item.
56       *
57       * @return The URL of this item.
58       */
59      String getLink();
60  
61      /**
62       * Sets the icon URL of this menu item.
63       *
64       * @param link The icon URL.
65       */
66      void setIcon(String link);
67  
68      /**
69       * Returns the icon URL of this menu item.
70       *
71       * @return The icon URL.
72       */
73      String getIcon();
74  
75      /**
76       * Sets the tooltip text.
77       *
78       * @param link The tooltip text.
79       */
80      void setTooltip(String link);
81  
82      /**
83       * Returns the tooltip text.
84       *
85       * @return The tooltip text.
86       */
87      String getTooltip();
88  }