KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > jonas > jtests > beans > transacted > SimpleEC


1 /*
2  * JOnAS: Java(TM) Open Application Server
3  * Copyright (C) 1999 Bull S.A.
4  * Contact: jonas-team@objectweb.org
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or any later version.
10  *
11  * This library 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  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19  * USA
20  *
21  * --------------------------------------------------------------------------
22  * $Id: SimpleEC.java,v 1.7 2004/03/19 11:57:17 benoitf Exp $
23  * --------------------------------------------------------------------------
24  */

25
26 package org.objectweb.jonas.jtests.beans.transacted;
27
28 import javax.ejb.EntityBean JavaDoc;
29 import javax.ejb.EntityContext JavaDoc;
30
31 import org.objectweb.util.monolog.api.BasicLevel;
32
33 /**
34  * Entity bean with container managed persistence version 1.
35  */

36 public class SimpleEC extends SimpleEC2 implements EntityBean JavaDoc {
37
38     protected EntityContext JavaDoc entityContext;
39
40     // Bean state (CMP v1)
41
public String JavaDoc accno; // PK
42
public String JavaDoc customer;
43     public long balance;
44     public int timerIdent;
45     public int timerCount;
46
47     // Accessors and setters implementation
48
public String JavaDoc getAccno() {
49         return this.accno;
50     }
51     public void setAccno(String JavaDoc accno) {
52         this.accno = accno;
53     }
54     public String JavaDoc getCustomer() {
55         return this.customer;
56     }
57     public void setCustomer(String JavaDoc customer) {
58         this.customer = customer;
59     }
60     public long getBalance() {
61         return this.balance;
62     }
63     public void setBalance(long balance) {
64         this.balance = balance;
65     }
66
67     public int getTimerIdent() {
68         logger.log(BasicLevel.DEBUG, "");
69         return timerIdent;
70     }
71
72     public void setTimerIdent(int id) {
73         logger.log(BasicLevel.DEBUG, "");
74         timerIdent = id;
75     }
76
77     public int getTimerCount() {
78         logger.log(BasicLevel.DEBUG, "");
79         return timerCount;
80     }
81
82     public void setTimerCount(int cnt) {
83         logger.log(BasicLevel.DEBUG, "");
84         timerCount = cnt;
85     }
86     
87     
88 }
89
Popular Tags