lamaulfarid

Bid

Oct 29th, 2020
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.55 KB | None | 0 0
  1.  
  2. /**
  3.  * Write a description of class Bid here.
  4.  *
  5.  * @author Ahmad Lamaul Farid
  6.  * @version 28 Oktober 2020
  7.  */
  8.  
  9. public class Bid
  10. {
  11.    private final Person bidder;  
  12.    private final long value;
  13.    
  14.    // konstruktor
  15.    public Bid(Person bidder, long value)
  16.    {
  17.        this.bidder = bidder;
  18.        this.value = value;
  19.    }
  20.    
  21.    // untuk menampilkan nama sang penawar
  22.    public Person getBidder()  
  23.    {  
  24.        return bidder;  
  25.    }
  26.    
  27.    // untuk menampilkan harga
  28.    public long getBid()  
  29.    {  
  30.        return value;  
  31.    }
  32. }
Add Comment
Please, Sign In to add comment