1 | /* |
2 | * Copyright 2005-2006 The RbUtils Project |
3 | * |
4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
5 | * you may not use this file except in compliance with the License. |
6 | * You may obtain a copy of the License at |
7 | * |
8 | * http://www.apache.org/licenses/LICENSE-2.0 |
9 | * |
10 | * Unless required by applicable law or agreed to in writing, software |
11 | * distributed under the License is distributed on an "AS IS" BASIS, |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
13 | * See the License for the specific language governing permissions and |
14 | * limitations under the License. |
15 | * |
16 | */ |
17 | |
18 | // $Id$ |
19 | |
20 | package org.ktc.rbutils.api.audit.event; |
21 | |
22 | import java.util.Date; |
23 | import java.util.EventObject; |
24 | |
25 | /** |
26 | * Base event for the RbUtils project. |
27 | * @since RbUtils 0.9.3.3 |
28 | * @version $Revision$ |
29 | * @author moishi |
30 | */ |
31 | public class RbEvent extends EventObject { |
32 | /** |
33 | * Automaticly generated field for backward compatibility. |
34 | */ |
35 | private static final long serialVersionUID = 4838028951790386517L; |
36 | |
37 | /** |
38 | * Indicates when the event occurs. |
39 | */ |
40 | private Date eventDate; |
41 | |
42 | /** |
43 | * Constructs a prototypical <code>RbEvent</code>. |
44 | * @param source The object on which the Event initially occurred. |
45 | * @exception IllegalArgumentException if source is <code>null</code>. |
46 | */ |
47 | public RbEvent(final Object source) { |
48 | super(source); |
49 | eventDate = new Date(); |
50 | } |
51 | |
52 | /** |
53 | * Gets the date when the event occurs. |
54 | * @return the eventDate. |
55 | */ |
56 | public final Date getEventDate() { |
57 | return this.eventDate; |
58 | } |
59 | } |