1 /*******************************************************************************
2 * Imixs Workflow
3 * Copyright (C) 2001, 2011 Imixs Software Solutions GmbH,
4 * http://www.imixs.com
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version 2
9 * of the License, or (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * General Public License for more details.
15 *
16 * You can receive a copy of the GNU General Public
17 * License at http://www.gnu.org/licenses/gpl.html
18 *
19 * Project:
20 * http://www.imixs.org
21 * http://java.net/projects/imixs-workflow
22 *
23 * Contributors:
24 * Imixs Software Solutions GmbH - initial API and implementation
25 * Ralph Soika - Software Developer
26 *******************************************************************************/
27
28 package org.imixs.workflow.jee.jpa;
29
30 import javax.persistence.*;
31
32 import java.math.BigInteger;
33 import java.util.*;
34
35 /**
36 * A CalendarItem is a subdata item of the data object class WorkItem. These
37 * subdata types are used to extract single attributes of an ItemCollection from
38 * the data Attribute of a WorkItem outside to seperate entity ejbs. As both -
39 * the WorkItem and the SubDataItem are Entity EJBs this facilitate the
40 * possibility of a object-relational data mapping into different table.
41 *
42 * @see org.imixs.workflow.jee.jpa.Entity
43 * @see org.imixs.workflow.jee.ejb.EntityService
44 * @author Ralph Soika
45 * @version 1.0
46 *
47 */
48
49 @javax.persistence.Entity
50 public class CalendarItem implements java.io.Serializable {
51
52 /**
53 * default serial id
54 */
55 private static final long serialVersionUID = 1L;
56
57 @SuppressWarnings("unused")
58 @Id
59 @GeneratedValue
60 private BigInteger id;
61
62 @Temporal(TemporalType.TIMESTAMP)
63 public Calendar itemValue;
64
65 public String itemName;
66
67 @SuppressWarnings("unused")
68 private CalendarItem() {
69 }
70
71 public CalendarItem(String name, Calendar value) {
72 itemValue = value;
73 itemName = name;
74 }
75 }