KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tonbeller > wcf > catedit > Category


1 /*
2  * ====================================================================
3  * This software is subject to the terms of the Common Public License
4  * Agreement, available at the following URL:
5  * http://www.opensource.org/licenses/cpl.html .
6  * Copyright (C) 2003-2004 TONBELLER AG.
7  * All Rights Reserved.
8  * You must accept the terms of that agreement to use this software.
9  * ====================================================================
10  *
11  *
12  */

13 package com.tonbeller.wcf.catedit;
14
15 import java.util.List JavaDoc;
16
17 /**
18  * a category that has items associated with it
19  *
20  * @author av
21  */

22 public interface Category {
23
24   /**
25    * returns the image name to use for buttons
26    */

27   String JavaDoc getIcon();
28
29   /**
30    * returns the label
31    */

32   String JavaDoc getName();
33
34   /**
35    * returns the items of this category. The items must implement the Item interface
36    * @return a read-only list of Item's
37    */

38   List JavaDoc getItems();
39
40   /**
41    * adds an item to this category
42    */

43   void addItem(Item item);
44
45   /**
46    * removes an item of this category
47    */

48   void removeItem(Item item);
49
50   /**
51    * changes the order of the items
52    */

53   void changeOrder(List JavaDoc items);
54
55   /**
56    * if order is significant, move-up and move-down buttons are generated.
57    */

58   boolean isOrderSignificant();
59
60   /**
61    * if true this category may be empty (has no items)
62    */

63   boolean isEmptyAllowed();
64 }
65
Popular Tags