Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

Source code: com/jdwsoftware/wfh/model/Fish.java


1   package com.jdwsoftware.wfh.model;
2   
3   /**
4    * <p><b>Title</b>: Woody's Fishing Hole</p>
5    * <p><b>Description</b>: Educational Fishing Game</p>
6    * <p><b>Copyright</b>: Copyright (C) 2003 JDW Software, LLC</p>
7    * <p><b>Company</b>: JDW Software, LLC</p>
8    *
9    * <p>Basic fish model.  Stores information about the image id to
10   *    use for this fish, the current location and direction of the
11   *    fish and the answer this fish is storing</o>
12   *
13   * @author <a href="mailto:jdw@jdwsoftware.com">Jim Woodgate</a>
14   * @version $Revision: 1.5 $
15   */
16  
17  /*
18   * This file is part of Woodys Fishing Hole.
19   *
20   * Woodys Fishing Hole is free software; you can redistribute it
21   * and/or modify it under the terms of the GNU General Public License
22   * as published by the Free Software Foundation; either version 2 of
23   * the License, or (at your option) any later version.
24   *
25   * Woodys Fishing Hole is distributed in the hope that it will be
26   * useful, but WITHOUT ANY WARRANTY; without even the implied warranty
27   * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
28   * GNU General Public License for more details.
29   *
30   * You should have received a copy of the GNU General Public License
31   * along with Woodys Fishing Hole; if not, write to the Free Software
32   * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
33   * USA
34   */
35  
36  public class Fish {
37    private static final String COPYRIGHT = com.jdwsoftware.util.Copyright.COPYRIGHT;
38    private static final String VERSION = "$Id: Fish.java,v 1.5 2003/11/22 03:47:15 jdw Exp $";
39  
40    private String    _value;
41    private Location  _location;
42    private Direction _direction;
43    private int       _imageIndex;
44  
45    /**
46     * Default constructor
47     */
48    public Fish() {
49      super();
50    }
51  
52    /**
53     * Get the direction attribute
54     *
55     * @return direction
56     */
57    public Direction getDirection() {
58      return _direction;
59    }
60  
61    /**
62     * Set the direction attribute
63     *
64     * @param direction new direction attribute
65     */
66    public void setDirection(Direction direction) {
67      _direction = direction;
68    }
69  
70    /**
71     * Get the imageIndex attribute
72     *
73     * @return imageIndex
74     */
75    public int getImageIndex() {
76      return _imageIndex;
77    }
78  
79    /**
80     * Set the imageIndex attribute
81     *
82     * @param imageIndex new imageIndex attribute
83     */
84    public void setImageIndex(int imageIndex) {
85      _imageIndex = imageIndex;
86    }
87  
88    /**
89     * Get the location attribute
90     *
91     * @return location
92     */
93    public Location getLocation() {
94      return _location;
95    }
96  
97    /**
98     * Set the location attribute
99     *
100    * @param location new location attribute
101    */
102   public void setLocation(Location location) {
103     _location = location;
104   }
105 
106   /**
107    * Get the value attribute
108    *
109    * @return value
110    */
111   public String getValue() {
112     return _value;
113   }
114 
115   /**
116    * Set the value attribute
117    *
118    * @param value new value attribute
119    */
120   public void setValue(String value) {
121     _value = value;
122   }
123 }