/*
* Copyright (c) 2006 Thomas Weise
*
* E-Mail : tweise@gmx.de
* Creation Date : 2006-02-21 05:25:29
* Original Filename: org.sfc.events.ParallelStateEvent.java
* Version : 3.0.0
* Last modification: 2006-04-10
* by: Thomas Weise
*
* License : GNU LESSER GENERAL PUBLIC LICENSE
* Version 2.1, February 1999
* You should have received a copy of this license along
* with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
* MA 02111-1307, USA or download the license under
* http://www.gnu.org/copyleft/lesser.html.
*
* Warranty : This software is provided "as is" without any
* warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose.
* See the Gnu Lesser General Public License for more
* details.
*/
package org.sfc.parallel.events;
import org.sfc.events.TimedEvent;
/**
* This event notifies about the state of something.
* It could be used to notify for example if a thread has been started or
* stopped.
*
* @author Thomas Weise
*/
public class ParallelStateEvent extends TimedEvent
{
/**
* The serial version uid.
*/
private static final long serialVersionUID = 1;
/**
* The state stored.
*/
private final boolean m_state ;
/**
* Create a new state event.
* @param p_source The source object.
* @param p_state The state of the source object.
* true
if the source just been started,
* false
if it has terminated.
*/
public ParallelStateEvent (final Object p_source,
final boolean p_state)
{
super(p_source);
this.m_state = p_state ;
}
/**
* Obtain the state of the source object created.
* @return The state of the source object.
* true
if the source just been started,
* false
if it has terminated.
*/
public final boolean get_state ()
{
return this.m_state;
}
}