1
|
// $Id$
|
2
|
/**
|
3
|
* Copyright (C) 2007 EDIT
|
4
|
* European Distributed Institute of Taxonomy
|
5
|
* http://www.e-taxonomy.eu
|
6
|
*
|
7
|
* The contents of this file are subject to the Mozilla Public License Version 1.1
|
8
|
* See LICENSE.TXT at the top of this package for the full license terms.
|
9
|
*/
|
10
|
|
11
|
package eu.etaxonomy.taxeditor.ui.element;
|
12
|
|
13
|
import org.eclipse.jface.util.PropertyChangeEvent;
|
14
|
|
15
|
/**
|
16
|
* <p>CdmPropertyChangeEvent class.</p>
|
17
|
*
|
18
|
* @author n.hoffmann
|
19
|
* @created Feb 24, 2010
|
20
|
* @version 1.0
|
21
|
*/
|
22
|
public class CdmPropertyChangeEvent extends PropertyChangeEvent {
|
23
|
/**
|
24
|
*
|
25
|
*/
|
26
|
private static final long serialVersionUID = -1010152430827799277L;
|
27
|
|
28
|
private Object originatingEvent;
|
29
|
|
30
|
private Exception exception;
|
31
|
|
32
|
/**
|
33
|
* <p>Getter for the field <code>originatingEvent</code>.</p>
|
34
|
*
|
35
|
* @return a {@link java.lang.Object} object.
|
36
|
*/
|
37
|
public Object getOriginatingEvent() {
|
38
|
return originatingEvent;
|
39
|
}
|
40
|
|
41
|
/**
|
42
|
* <p>Constructor for CdmPropertyChangeEvent.</p>
|
43
|
*
|
44
|
* @param eventObject a {@link java.lang.Object} object.
|
45
|
* @param originatingEvent a {@link java.lang.Object} object.
|
46
|
*/
|
47
|
public CdmPropertyChangeEvent(Object eventObject, Object originatingEvent) {
|
48
|
super(eventObject, "EMPTY", null, null);
|
49
|
this.originatingEvent = originatingEvent;
|
50
|
}
|
51
|
|
52
|
/**
|
53
|
* <p>Constructor for CdmPropertyChangeEvent.</p>
|
54
|
*
|
55
|
* @param eventObject a {@link java.lang.Object} object.
|
56
|
* @param exception a {@link java.lang.Exception} object.
|
57
|
*/
|
58
|
public CdmPropertyChangeEvent(Object eventObject, Exception exception) {
|
59
|
super(eventObject, "EMPTY", null, null);
|
60
|
this.exception = exception;
|
61
|
}
|
62
|
|
63
|
/**
|
64
|
* <p>Setter for the field <code>exception</code>.</p>
|
65
|
*
|
66
|
* @param exception a {@link java.lang.Exception} object.
|
67
|
*/
|
68
|
public void setException(Exception exception) {
|
69
|
this.exception = exception;
|
70
|
}
|
71
|
|
72
|
/**
|
73
|
* <p>Getter for the field <code>exception</code>.</p>
|
74
|
*
|
75
|
* @return a {@link java.lang.Exception} object.
|
76
|
*/
|
77
|
public Exception getException(){
|
78
|
return exception;
|
79
|
}
|
80
|
|
81
|
/**
|
82
|
* <p>hasException</p>
|
83
|
*
|
84
|
* @return a boolean.
|
85
|
*/
|
86
|
public boolean hasException(){
|
87
|
return exception != null;
|
88
|
}
|
89
|
}
|