KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > dotmarketing > portlets > order_manager > struts > OrderItemForm


1 package com.dotmarketing.portlets.order_manager.struts;
2
3 import javax.servlet.http.HttpServletRequest JavaDoc;
4
5 import org.apache.struts.action.ActionErrors;
6 import org.apache.struts.action.ActionMapping;
7 import org.apache.struts.validator.ValidatorForm;
8 import com.liferay.portal.util.Constants;
9
10 public class OrderItemForm extends ValidatorForm {
11     private static final long serialVersionUID = 1L;
12     private long inode; //identifier
13
private long orderInode; //persistent
14
private long productInode; //persistent
15
private int itemQty; //persistent
16
private float itemPrice; //persistent
17
private String JavaDoc productName;
18     private String JavaDoc formatName;
19
20     public OrderItemForm() {
21     }
22
23     public ActionErrors validate(ActionMapping mapping, HttpServletRequest JavaDoc request) {
24         if(request.getParameter("cmd")!=null && request.getParameter("cmd").equals(Constants.ADD)) {
25             return super.validate(mapping, request);
26         }
27         return null;
28     }
29
30     public long getInode() {
31         return this.inode;
32     }
33
34     public void setInode(long inode) {
35         this.inode = inode;
36     }
37     public long getOrderInode() {
38         return this.orderInode;
39     }
40
41     public void setOrderInode(long orderInode) {
42         this.orderInode = orderInode;
43     }
44     public long getProductInode() {
45         return this.productInode;
46     }
47
48     public void setProductInode(long productInode) {
49         this.productInode = productInode;
50     }
51     public int getItemQty() {
52         return this.itemQty;
53     }
54
55     public void setItemQty(int itemQty) {
56         this.itemQty = itemQty;
57     }
58     public float getItemPrice() {
59         return this.itemPrice;
60     }
61
62     public void setItemPrice(float itemPrice) {
63         this.itemPrice = itemPrice;
64     }
65
66     public String JavaDoc getProductName() {
67         return productName;
68     }
69
70     public void setProductName(String JavaDoc productName) {
71         this.productName = productName;
72     }
73
74     public String JavaDoc getFormatName() {
75         return formatName;
76     }
77
78     public void setFormatName(String JavaDoc formatName) {
79         this.formatName = formatName;
80     }
81
82 }
83
Popular Tags