KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > hibernate > auction > Bid


1 //$Id: Bid.java,v 1.1 2004/06/03 16:30:01 steveebersole Exp $
2
package org.hibernate.auction;
3
4 import java.util.Date JavaDoc;
5
6 /**
7  * @author Gavin King
8  */

9 public class Bid extends Persistent {
10     private AuctionItem item;
11     private float amount;
12     private Date JavaDoc datetime;
13     private User bidder;
14     
15     public AuctionItem getItem() {
16         return item;
17     }
18
19     public void setItem(AuctionItem item) {
20         this.item = item;
21     }
22
23     public float getAmount() {
24         return amount;
25     }
26
27     public Date JavaDoc getDatetime() {
28         return datetime;
29     }
30
31     public void setAmount(float f) {
32         amount = f;
33     }
34
35     public void setDatetime(Date JavaDoc date) {
36         datetime = date;
37     }
38
39     public User getBidder() {
40         return bidder;
41     }
42
43     public void setBidder(User user) {
44         bidder = user;
45     }
46
47     public String JavaDoc toString() {
48         return bidder.getUserName() + " $" + amount;
49     }
50     
51     public boolean isBuyNow() {
52         return false;
53     }
54
55 }
56
Popular Tags