KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > core > databinding > observable > ChangeEvent


1 /*******************************************************************************
2  * Copyright (c) 2006, 2007 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11
12 package org.eclipse.core.databinding.observable;
13
14 /**
15  * Generic change event denoting that the state of an {@link IObservable} object
16  * has changed. This event does not carry information about the kind of change
17  * that occurred.
18  *
19  * @since 1.0
20  *
21  */

22 public class ChangeEvent extends ObservableEvent {
23
24     /**
25      *
26      */

27     private static final long serialVersionUID = -3241193109844979384L;
28     static final Object JavaDoc TYPE = new Object JavaDoc();
29
30     /**
31      * Creates a new change event object.
32      *
33      * @param source
34      * the observable that changed state
35      */

36     public ChangeEvent(IObservable source) {
37         super(source);
38     }
39
40     protected void dispatch(IObservablesListener listener) {
41         ((IChangeListener) listener).handleChange(this);
42     }
43
44     protected Object JavaDoc getListenerType() {
45         return TYPE;
46     }
47
48 }
49
Popular Tags