Bid.java
package beans;
public class Bid {
/** Holds value of property price. */
private long price;
/** Holds value of property item. */
private String item;
/** Creates a new instance of Bid */
public Bid() {
}
/** Getter for property price.
* @return Value of property price.
*
*/
public long getPrice() {
return this.price;
}
/** Setter for property price.
* @param price New value of property price.
*
*/
public void setPrice(long price) {
this.price = price;
}
/** Getter for property item.
* @return Value of property item.
*
*/
public String getItem() {
return this.item;
}
/** Setter for property item.
* @param item New value of property item.
*
*/
public void setItem(String item) {
this.item = item;
}
}
Bidder.java
package beans;
public class Bidder {
/** Holds value of property item. */
private String item;
/** Holds value of property price. */
private long price;
/** Holds value of property result. */
private String result;
/** Creates a new instance of Bidder */
public Bidder() {
}
/** Getter for property item.
* @return Value of property item.
*
*/
public String getItem() {
return this.item;
}
/** Setter for property item.
* @param item New value of property item.
*
*/
public void setItem(String item) {
this.item = item;
}
/** Getter for property price.
* @return Value of property price.
*
*/
public long getPrice() {
return this.price;
}
/** Setter for property price.
* @param price New value of property price.
*
*/
public void setPrice(long price) {
this.price = price;
}
/** Getter for property result.
* @return Value of property result.
*
*/
public String getResult() {
/* simulate bid result */
this.result = "Sorry your bid did not win. The successful bidder was joe1233.";
return this.result;
}
}
BidError.java
package beans;
public class BidError {
/** Holds value of property msg. */
private String msg;
/** Creates a new instance of BidError */
public BidError() {
}
/** Getter for property msg.
* @return Value of property msg.
*
*/
public String getMsg() {
return this.msg;
}
/** Setter for property msg.
* @param msg New value of property msg.
*
*/
public void setMsg(String msg) {
this.msg = msg;
}
}
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
= 999)}">
Show the Bid
Your Auction Bid
Item bid for
Bid price
Bid result
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
Enter Your Bid
Wrox JSP Auction
${biderror.msg}