View Javadoc

1   package org.wcb.autohome.util;
2   /***
3    * Copyright (C) 1999  Walter Bogaardt
4    *
5    * This library is free software; you can redistribute it and/or
6    * modify it under the terms of the GNU Lesser General Public
7    * License as published by the Free Software Foundation; either
8    * version 2 of the License, or (at your option) any later version.
9    *
10   * This library is distributed in the hope that it will be useful,
11   * but WITHOUT ANY WARRANTY; without even the implied warranty of
12   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13   * Lesser General Public License for more details.
14   *
15   * You should have received a copy of the GNU Lesser General Public
16   * License along with this library; if not, write to the Free Software
17   * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
18   *
19   */
20  import javax.swing.Icon;
21  
22  /***
23   * Filename:    $Id: Item.java,v 1.2 2003/12/22 20:51:32 wbogaardt Exp $
24   *This class is a sort of place holder for use in displaying information on the events panel and
25   *macros panel.
26   *
27   *@author wbogaardt
28   *@version 1.0
29   */
30  public class Item {
31      private String sID;
32      int iType;
33      private Icon icon;
34  
35      public Item(Object[] array){
36          iType = ((Integer)array[0]).intValue();
37          icon = (Icon)array[1];
38          sID= (String)array[2];
39      }
40  
41      public Icon getIcon() {
42          return icon;
43      }
44  
45      public int getType() {
46          return iType;
47      }
48  
49      public String toString() {
50          return sID;
51      }
52  }
53  
54  
55  
56