KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > info > monitorenter > gui > chart > events > AAxisAction


1 /*
2  * AChart2DAction, base for actions to trigger on charts.
3  * Copyright (C) Achim Westermann, created on 10.12.2004, 13:48:55
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.1 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18  *
19  * If you modify or optimize the code in a useful way please let me know.
20  * Achim.Westermann@gmx.de
21  *
22  */

23 package info.monitorenter.gui.chart.events;
24
25 import java.beans.PropertyChangeListener JavaDoc;
26
27 import info.monitorenter.gui.chart.IAxis;
28
29 import javax.swing.AbstractAction JavaDoc;
30
31
32 /**
33  * The base class that connects triggered actions with an
34  * {@link info.monitorenter.gui.chart.AAxis} instance.
35  * <p>
36  * Every subclass may delegate it's constructor-given <code>Axis</code>
37  * instance as protected member <code>m_axis</code>.
38  * </p>
39  *
40  * @author <a HREF="mailto:Achim.Westermann@gmx.de">Achim Westermann </a>
41  *
42  * @version $Revision: 1.2 $
43  *
44  */

45 public abstract class AAxisAction extends AbstractAction JavaDoc implements PropertyChangeListener JavaDoc {
46
47   /** The target of this action. */
48   protected IAxis m_axis;
49
50   /**
51    * Create an <code>Action</code> that accesses the axis and identifies
52    * itself with the given action String.
53    *
54    * @param axis
55    * the target the action will work on.
56    *
57    * @param description
58    * the descriptive <code>String</code> that will be displayed by
59    * {@link javax.swing.AbstractButton} subclasses that get this
60    * <code>Action</code> assigned (
61    * {@link javax.swing.AbstractButton#setAction(javax.swing.Action)}).
62    */

63   public AAxisAction(final IAxis axis, final String JavaDoc description) {
64     super(description);
65     this.m_axis = axis;
66   }
67 }
68
Popular Tags