KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > test > cmp2 > idxandusersql > ejb > CMR1Bean


1 /*
2   * JBoss, Home of Professional Open Source
3   * Copyright 2005, JBoss Inc., and individual contributors as indicated
4   * by the @authors tag. See the copyright.txt in the distribution for a
5   * full listing of individual contributors.
6   *
7   * This is free software; you can redistribute it and/or modify it
8   * under the terms of the GNU Lesser General Public License as
9   * published by the Free Software Foundation; either version 2.1 of
10   * the License, or (at your option) any later version.
11   *
12   * This software is distributed in the hope that it will be useful,
13   * but WITHOUT ANY WARRANTY; without even the implied warranty of
14   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15   * Lesser General Public License for more details.
16   *
17   * You should have received a copy of the GNU Lesser General Public
18   * License along with this software; if not, write to the Free
19   * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
20   * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
21   */

22 package org.jboss.test.cmp2.idxandusersql.ejb;
23
24 import javax.ejb.EntityBean JavaDoc;
25
26 /**
27  * Test the dbindex feature
28  * @author heiko.rupp@cellent.de
29  * @version $Revision: 37406 $
30  *
31  * @ejb.bean name="CMR1"
32  * type="CMP"
33  * cmp-version="2.x"
34  * view-type="local"
35  * primkey-field="pKey"
36  *
37  * @ejb.util generate="false"
38  *
39  * @ejb.persistence table-name = "CMR1"
40  *
41  * @jboss.persistence
42  * create-table = "true"
43  * remove-table = "true"
44  *
45  */

46 public abstract class CMR1Bean implements EntityBean JavaDoc
47 {
48
49    /**
50     * We don't call them, just have them here to
51     * satisfy the cmp-engine
52     * @ejb.create-method
53     */

54    public String JavaDoc ejbCreate() throws javax.ejb.CreateException JavaDoc
55    {
56       return null;
57    }
58
59    public void ejbPostCreate()
60    {
61
62    }
63
64    /**
65     * @ejb.interface-method
66     * @param pKey
67     */

68    public abstract void setPKey(String JavaDoc pKey);
69
70    /**
71     * @ejb.interface-method
72     * @ejb.persistent-field
73     */

74    public abstract String JavaDoc getPKey();
75
76    /**
77     * This field gets a <dbindex/> that we want to
78     * look up in the database to see if the index
79     * was really created on the file.
80     * @ejb.interface-method
81     * @ejb.persistent-field
82     * @todo set the dbindex property here with a modern xdoclet*
83     */

84    public abstract String JavaDoc getFoo1();
85
86    /**
87     * This one is not indexed
88     * @ejb.interface-method
89     * @ejb.persistent-field
90     */

91    public abstract String JavaDoc getBar1();
92
93 }
94
Popular Tags