KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > poker > data > DODS_GameData > GameDataBDO


1 /*-----------------------------------------------------------------------------
2  * Enhydra Java Application Server
3  * Copyright 1997-1999 Lutris Technologies, Inc.
4  * All rights reserved.
5  *
6  * Redistribution and use in source and binary forms, with or without
7  * modification, are permitted provided that the following conditions
8  * are met:
9  * 1. Redistributions of source code must retain the above copyright
10  * notice, this list of conditions and the following disclaimer.
11  * 2. Redistributions in binary form must reproduce the above copyright
12  * notice, this list of conditions and the following disclaimer in
13  * the documentation and/or other materials provided with the distribution.
14  * 3. All advertising materials mentioning features or use of this software
15  * must display the following acknowledgement:
16  * This product includes Enhydra software developed by Lutris
17  * Technologies, Inc. and its contributors.
18  * 4. Neither the name of Lutris Technologies nor the names of its contributors
19  * may be used to endorse or promote products derived from this software
20  * without specific prior written permission.
21  *
22  * THIS SOFTWARE IS PROVIDED BY LUTRIS TECHNOLOGIES AND CONTRIBUTORS ``AS IS''
23  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25  * ARE DISCLAIMED. IN NO EVENT SHALL LUTRIS TECHNOLOGIES OR CONTRIBUTORS BE
26  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
27  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
28  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
29  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
30  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
31  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
32  * POSSIBILITY OF SUCH DAMAGE.
33  *-----------------------------------------------------------------------------
34  * /root/test/poker/data/DODS_GameData/GameDataBDO.java
35  *-----------------------------------------------------------------------------
36  */

37
38 package poker.data.DODS_GameData;
39
40 import com.lutris.dods.builder.generator.query.DataObjectException;
41
42 /**
43  * GameDataBDO contains the same set and get methods as
44  * the GameDataDO class.
45  * Business Object (BO) classes typically need these set and get methods.
46  * So by deriving a BO from a BDO, or by implementing a BO that
47  * contains a BDO, the developer of the BO is spared some work.
48  *
49  * @author <AUTHOR>
50  * @version $Revision: 1.1 $
51  */

52 public class GameDataBDO implements java.io.Serializable JavaDoc {
53
54     /**
55      * The GameDataDO object upon which the set and get methods operate.
56      * This member is protected so that classes derived from GameDataBDO
57      * can access the underlying Data Object.
58      */

59     protected GameDataDO DO;
60
61     /**
62      * Like the class <CODE>GameDataDO</CODE>,
63      * this class acts as a factory.
64      * Business Object (BO) classes typically need these set and get methods.
65      * So by deriving a BO from a BDO, or by implementing a BO that
66      * contains one or more BDOs, the developer of the BO is spared some work.
67      */

68     public static GameDataBDO createVirgin() throws Exception JavaDoc {
69     GameDataBDO bdo = new GameDataBDO ();
70     bdo.DO = GameDataDO.createVirgin();
71     return bdo;
72     }
73
74     /**
75      * The createExisting method is used to create a <CODE>GameDataBDO</CODE>
76      * from a <CODE>GameDataDO</CODE> that was returned by
77      * the <CODE>GameDataQuery</CODE> class.
78      */

79     public static GameDataBDO createExisting( GameDataDO DO ) {
80     GameDataBDO bdo = new GameDataBDO ();
81     bdo.DO = DO;
82     return bdo;
83     }
84
85     /**
86      * The developer of a Business Object that derives from this class
87      * can override the methods:<CODE>
88      * beforeAnyGet
89      * beforeAnySet
90      * afterAnySet
91      * </CODE> to handle any general assertions or cleanup needed
92      * for <CODE>get</CODE> and <CODE>set</CODE> methods.
93      */

94     protected void beforeAnyGet() {}
95     protected void beforeAnySet() {}
96     protected void afterAnySet() {}
97
98    /**
99     * Get Cash of the GameDataDO
100     *
101     * @return Cash of the GameDataDO
102     */

103    public int getCash ()
104    throws DataObjectException {
105       return DO.getCash ();
106    }
107
108    /**
109     * Set Cash of the GameDataDO
110     *
111     * @param Cash of the GameDataDO
112     */

113
114    public void setCash ( int Cash )
115    throws DataObjectException {
116       DO.setCash ( Cash );
117    }
118
119
120    /**
121     * Get Deck of the GameDataDO
122     *
123     * @return Deck of the GameDataDO
124     */

125    public String JavaDoc getDeck ()
126    throws DataObjectException {
127       return DO.getDeck ();
128    }
129
130    /**
131     * Set Deck of the GameDataDO
132     *
133     * @param Deck of the GameDataDO
134     */

135
136    public void setDeck ( String JavaDoc Deck )
137    throws DataObjectException {
138       DO.setDeck ( Deck );
139    }
140
141
142    /**
143     * Get Email of the GameDataDO
144     *
145     * @return Email of the GameDataDO
146     */

147    public String JavaDoc getEmail ()
148    throws DataObjectException {
149       return DO.getEmail ();
150    }
151
152    /**
153     * Set Email of the GameDataDO
154     *
155     * @param Email of the GameDataDO
156     */

157
158    public void setEmail ( String JavaDoc Email )
159    throws DataObjectException {
160       DO.setEmail ( Email );
161    }
162
163
164    /**
165     * Get LargestBet of the GameDataDO
166     *
167     * @return LargestBet of the GameDataDO
168     */

169    public int getLargestBet ()
170    throws DataObjectException {
171       return DO.getLargestBet ();
172    }
173
174    /**
175     * Set LargestBet of the GameDataDO
176     *
177     * @param LargestBet of the GameDataDO
178     */

179
180    public void setLargestBet ( int LargestBet )
181    throws DataObjectException {
182       DO.setLargestBet ( LargestBet );
183    }
184
185
186    /**
187     * Get Name of the GameDataDO
188     *
189     * @return Name of the GameDataDO
190     */

191    public String JavaDoc getName ()
192    throws DataObjectException {
193       return DO.getName ();
194    }
195
196    /**
197     * Set Name of the GameDataDO
198     *
199     * @param Name of the GameDataDO
200     */

201
202    public void setName ( String JavaDoc Name )
203    throws DataObjectException {
204       DO.setName ( Name );
205    }
206
207
208    /**
209     * Get Password of the GameDataDO
210     *
211     * @return Password of the GameDataDO
212     */

213    public String JavaDoc getPassword ()
214    throws DataObjectException {
215       return DO.getPassword ();
216    }
217
218    /**
219     * Set Password of the GameDataDO
220     *
221     * @param Password of the GameDataDO
222     */

223
224    public void setPassword ( String JavaDoc Password )
225    throws DataObjectException {
226       DO.setPassword ( Password );
227    }
228
229
230    /**
231     * Get SmallestBet of the GameDataDO
232     *
233     * @return SmallestBet of the GameDataDO
234     */

235    public int getSmallestBet ()
236    throws DataObjectException {
237       return DO.getSmallestBet ();
238    }
239
240    /**
241     * Set SmallestBet of the GameDataDO
242     *
243     * @param SmallestBet of the GameDataDO
244     */

245
246    public void setSmallestBet ( int SmallestBet )
247    throws DataObjectException {
248       DO.setSmallestBet ( SmallestBet );
249    }
250
251
252    /**
253     * Get TotalPlayed of the GameDataDO
254     *
255     * @return TotalPlayed of the GameDataDO
256     */

257    public int getTotalPlayed ()
258    throws DataObjectException {
259       return DO.getTotalPlayed ();
260    }
261
262    /**
263     * Set TotalPlayed of the GameDataDO
264     *
265     * @param TotalPlayed of the GameDataDO
266     */

267
268    public void setTotalPlayed ( int TotalPlayed )
269    throws DataObjectException {
270       DO.setTotalPlayed ( TotalPlayed );
271    }
272
273
274    /**
275     * Get TotalWon of the GameDataDO
276     *
277     * @return TotalWon of the GameDataDO
278     */

279    public int getTotalWon ()
280    throws DataObjectException {
281       return DO.getTotalWon ();
282    }
283
284    /**
285     * Set TotalWon of the GameDataDO
286     *
287     * @param TotalWon of the GameDataDO
288     */

289
290    public void setTotalWon ( int TotalWon )
291    throws DataObjectException {
292       DO.setTotalWon ( TotalWon );
293    }
294
295
296 }
297
Popular Tags