[29] | 1 | /* |
---|
| 2 | * This program is free software; you can redistribute it and/or modify |
---|
| 3 | * it under the terms of the GNU General Public License as published by |
---|
| 4 | * the Free Software Foundation; either version 2 of the License, or |
---|
| 5 | * (at your option) any later version. |
---|
| 6 | * |
---|
| 7 | * This program is distributed in the hope that it will be useful, |
---|
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
| 10 | * GNU General Public License for more details. |
---|
| 11 | * |
---|
| 12 | * You should have received a copy of the GNU General Public License |
---|
| 13 | * along with this program; if not, write to the Free Software |
---|
| 14 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
---|
| 15 | */ |
---|
| 16 | |
---|
| 17 | /* |
---|
| 18 | * TextEvent.java |
---|
| 19 | * Copyright (C) 2002 University of Waikato, Hamilton, New Zealand |
---|
| 20 | * |
---|
| 21 | */ |
---|
| 22 | |
---|
| 23 | package weka.gui.beans; |
---|
| 24 | |
---|
| 25 | import java.util.EventObject; |
---|
| 26 | |
---|
| 27 | /** |
---|
| 28 | * Event that encapsulates some textual information |
---|
| 29 | * |
---|
| 30 | * @author <a href="mailto:mhall@cs.waikato.ac.nz">Mark Hall</a> |
---|
| 31 | * @version $Revision: 1.4 $ |
---|
| 32 | */ |
---|
| 33 | public class TextEvent |
---|
| 34 | extends EventObject { |
---|
| 35 | |
---|
| 36 | /** for serialization */ |
---|
| 37 | private static final long serialVersionUID = 4196810607402973744L; |
---|
| 38 | |
---|
| 39 | /** |
---|
| 40 | * The text |
---|
| 41 | */ |
---|
| 42 | protected String m_text; |
---|
| 43 | |
---|
| 44 | /** |
---|
| 45 | * The title for the text. Could be used in a list component |
---|
| 46 | */ |
---|
| 47 | protected String m_textTitle; |
---|
| 48 | |
---|
| 49 | /** |
---|
| 50 | * Creates a new <code>TextEvent</code> instance. |
---|
| 51 | * |
---|
| 52 | * @param source an <code>Object</code> value |
---|
| 53 | * @param text a <code>String</code> value |
---|
| 54 | */ |
---|
| 55 | public TextEvent(Object source, String text, String textTitle) { |
---|
| 56 | super(source); |
---|
| 57 | |
---|
| 58 | m_text = text; |
---|
| 59 | m_textTitle = textTitle; |
---|
| 60 | } |
---|
| 61 | |
---|
| 62 | /** |
---|
| 63 | * Describe <code>getText</code> method here. |
---|
| 64 | * |
---|
| 65 | * @return a <code>String</code> value |
---|
| 66 | */ |
---|
| 67 | public String getText() { |
---|
| 68 | return m_text; |
---|
| 69 | } |
---|
| 70 | |
---|
| 71 | /** |
---|
| 72 | * Describe <code>getTextTitle</code> method here. |
---|
| 73 | * |
---|
| 74 | * @return a <code>String</code> value |
---|
| 75 | */ |
---|
| 76 | public String getTextTitle() { |
---|
| 77 | return m_textTitle; |
---|
| 78 | } |
---|
| 79 | } |
---|