Project

General

Profile

1
/**
2
 *  '$RCSfile$'
3
 *    Purpose: A class represents an event for the solr indexing.
4
 *    Copyright: 2013 Regents of the University of California and the
5
 *             National Center for Ecological Analysis and Synthesis
6
 *    Authors: Jing Tao
7
 *
8
 * This program is free software; you can redistribute it and/or modify
9
 * it under the terms of the GNU General Public License as published by
10
 * the Free Software Foundation; either version 2 of the License, or
11
 * (at your option) any later version.
12
 *
13
 * This program is distributed in the hope that it will be useful,
14
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
 * GNU General Public License for more details.
17
 *
18
 * You should have received a copy of the GNU General Public License
19
 * along with this program; if not, write to the Free Software
20
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
21
 */
22
package edu.ucsb.nceas.metacat.common.index.event;
23

    
24
import java.io.Serializable;
25
import java.util.Date;
26

    
27
import org.dataone.service.types.v1.Event;
28
import org.dataone.service.types.v1.Identifier;
29

    
30

    
31
/**
32
 * A class represents an event for the solr indexing.
33
 * @author tao
34
 *
35
 */
36
public class IndexEvent implements Serializable {
37
    
38

    
39
	private static final long serialVersionUID = 1L;
40
	
41
	private Event action = null;
42
    private Date date = null;
43
    private Identifier identifier = null;
44
    private String description = null;
45
    
46
    /**
47
     * Get the action of the event.
48
     * @return the action of the event
49
     */
50
    public Event getAction() {
51
        return this.action;
52
    }
53
    
54
    /**
55
     * Set the action of the event
56
     * @param action
57
     */
58
    public void setAction(Event action) {
59
        this.action = action;
60
    }
61
    
62
    /**
63
     * Get the date when the event happened
64
     * @return
65
     */
66
    public Date getDate() {
67
        return date;
68
    }
69
    
70
    /**
71
     * Set the date when the event happened
72
     * @param date
73
     */
74
    public void setDate(Date date) {
75
        this.date = date;
76
    }
77
    
78
    /**
79
     * Get the identifier of the data object involving the event
80
     * @return
81
     */
82
    public Identifier getIdentifier() {
83
        return identifier;
84
    }
85
    
86
    /**
87
     * Set the identifier of the data object involving the event.
88
     * @param pid
89
     */
90
    public void setIdentifier(Identifier pid) {
91
        this.identifier = pid;
92
    }
93
    
94
    /**
95
     * Get the description of the event
96
     * @return
97
     */
98
    public String getDescription() {
99
        return description;
100
    }
101
    
102
    /**
103
     * Set the description of the event
104
     * @param description
105
     */
106
    public void setDescription(String description) {
107
        this.description = description;
108
    }
109
    
110
   
111
}
    (1-1/1)