1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   *
13   */
14  
15  package com.liferay.portlet.shopping.model;
16  
17  import java.io.Serializable;
18  
19  import java.util.ArrayList;
20  import java.util.Date;
21  import java.util.List;
22  
23  /**
24   * <a href="ShoppingCouponSoap.java.html"><b><i>View Source</i></b></a>
25   *
26   * <p>
27   * ServiceBuilder generated this class. Modifications in this class will be
28   * overwritten the next time is generated.
29   * </p>
30   *
31   * <p>
32   * This class is used by
33   * {@link com.liferay.portlet.shopping.service.http.ShoppingCouponServiceSoap}.
34   * </p>
35   *
36   * @author    Brian Wing Shun Chan
37   * @see       com.liferay.portlet.shopping.service.http.ShoppingCouponServiceSoap
38   * @generated
39   */
40  public class ShoppingCouponSoap implements Serializable {
41      public static ShoppingCouponSoap toSoapModel(ShoppingCoupon model) {
42          ShoppingCouponSoap soapModel = new ShoppingCouponSoap();
43  
44          soapModel.setCouponId(model.getCouponId());
45          soapModel.setGroupId(model.getGroupId());
46          soapModel.setCompanyId(model.getCompanyId());
47          soapModel.setUserId(model.getUserId());
48          soapModel.setUserName(model.getUserName());
49          soapModel.setCreateDate(model.getCreateDate());
50          soapModel.setModifiedDate(model.getModifiedDate());
51          soapModel.setCode(model.getCode());
52          soapModel.setName(model.getName());
53          soapModel.setDescription(model.getDescription());
54          soapModel.setStartDate(model.getStartDate());
55          soapModel.setEndDate(model.getEndDate());
56          soapModel.setActive(model.getActive());
57          soapModel.setLimitCategories(model.getLimitCategories());
58          soapModel.setLimitSkus(model.getLimitSkus());
59          soapModel.setMinOrder(model.getMinOrder());
60          soapModel.setDiscount(model.getDiscount());
61          soapModel.setDiscountType(model.getDiscountType());
62  
63          return soapModel;
64      }
65  
66      public static ShoppingCouponSoap[] toSoapModels(ShoppingCoupon[] models) {
67          ShoppingCouponSoap[] soapModels = new ShoppingCouponSoap[models.length];
68  
69          for (int i = 0; i < models.length; i++) {
70              soapModels[i] = toSoapModel(models[i]);
71          }
72  
73          return soapModels;
74      }
75  
76      public static ShoppingCouponSoap[][] toSoapModels(ShoppingCoupon[][] models) {
77          ShoppingCouponSoap[][] soapModels = null;
78  
79          if (models.length > 0) {
80              soapModels = new ShoppingCouponSoap[models.length][models[0].length];
81          }
82          else {
83              soapModels = new ShoppingCouponSoap[0][0];
84          }
85  
86          for (int i = 0; i < models.length; i++) {
87              soapModels[i] = toSoapModels(models[i]);
88          }
89  
90          return soapModels;
91      }
92  
93      public static ShoppingCouponSoap[] toSoapModels(List<ShoppingCoupon> models) {
94          List<ShoppingCouponSoap> soapModels = new ArrayList<ShoppingCouponSoap>(models.size());
95  
96          for (ShoppingCoupon model : models) {
97              soapModels.add(toSoapModel(model));
98          }
99  
100         return soapModels.toArray(new ShoppingCouponSoap[soapModels.size()]);
101     }
102 
103     public ShoppingCouponSoap() {
104     }
105 
106     public long getPrimaryKey() {
107         return _couponId;
108     }
109 
110     public void setPrimaryKey(long pk) {
111         setCouponId(pk);
112     }
113 
114     public long getCouponId() {
115         return _couponId;
116     }
117 
118     public void setCouponId(long couponId) {
119         _couponId = couponId;
120     }
121 
122     public long getGroupId() {
123         return _groupId;
124     }
125 
126     public void setGroupId(long groupId) {
127         _groupId = groupId;
128     }
129 
130     public long getCompanyId() {
131         return _companyId;
132     }
133 
134     public void setCompanyId(long companyId) {
135         _companyId = companyId;
136     }
137 
138     public long getUserId() {
139         return _userId;
140     }
141 
142     public void setUserId(long userId) {
143         _userId = userId;
144     }
145 
146     public String getUserName() {
147         return _userName;
148     }
149 
150     public void setUserName(String userName) {
151         _userName = userName;
152     }
153 
154     public Date getCreateDate() {
155         return _createDate;
156     }
157 
158     public void setCreateDate(Date createDate) {
159         _createDate = createDate;
160     }
161 
162     public Date getModifiedDate() {
163         return _modifiedDate;
164     }
165 
166     public void setModifiedDate(Date modifiedDate) {
167         _modifiedDate = modifiedDate;
168     }
169 
170     public String getCode() {
171         return _code;
172     }
173 
174     public void setCode(String code) {
175         _code = code;
176     }
177 
178     public String getName() {
179         return _name;
180     }
181 
182     public void setName(String name) {
183         _name = name;
184     }
185 
186     public String getDescription() {
187         return _description;
188     }
189 
190     public void setDescription(String description) {
191         _description = description;
192     }
193 
194     public Date getStartDate() {
195         return _startDate;
196     }
197 
198     public void setStartDate(Date startDate) {
199         _startDate = startDate;
200     }
201 
202     public Date getEndDate() {
203         return _endDate;
204     }
205 
206     public void setEndDate(Date endDate) {
207         _endDate = endDate;
208     }
209 
210     public boolean getActive() {
211         return _active;
212     }
213 
214     public boolean isActive() {
215         return _active;
216     }
217 
218     public void setActive(boolean active) {
219         _active = active;
220     }
221 
222     public String getLimitCategories() {
223         return _limitCategories;
224     }
225 
226     public void setLimitCategories(String limitCategories) {
227         _limitCategories = limitCategories;
228     }
229 
230     public String getLimitSkus() {
231         return _limitSkus;
232     }
233 
234     public void setLimitSkus(String limitSkus) {
235         _limitSkus = limitSkus;
236     }
237 
238     public double getMinOrder() {
239         return _minOrder;
240     }
241 
242     public void setMinOrder(double minOrder) {
243         _minOrder = minOrder;
244     }
245 
246     public double getDiscount() {
247         return _discount;
248     }
249 
250     public void setDiscount(double discount) {
251         _discount = discount;
252     }
253 
254     public String getDiscountType() {
255         return _discountType;
256     }
257 
258     public void setDiscountType(String discountType) {
259         _discountType = discountType;
260     }
261 
262     private long _couponId;
263     private long _groupId;
264     private long _companyId;
265     private long _userId;
266     private String _userName;
267     private Date _createDate;
268     private Date _modifiedDate;
269     private String _code;
270     private String _name;
271     private String _description;
272     private Date _startDate;
273     private Date _endDate;
274     private boolean _active;
275     private String _limitCategories;
276     private String _limitSkus;
277     private double _minOrder;
278     private double _discount;
279     private String _discountType;
280 }