001
014
015 package com.liferay.portlet.shopping.model;
016
017 import java.io.Serializable;
018
019 import java.util.ArrayList;
020 import java.util.Date;
021 import java.util.List;
022
023
030 public class ShoppingCouponSoap implements Serializable {
031 public static ShoppingCouponSoap toSoapModel(ShoppingCoupon model) {
032 ShoppingCouponSoap soapModel = new ShoppingCouponSoap();
033
034 soapModel.setCouponId(model.getCouponId());
035 soapModel.setGroupId(model.getGroupId());
036 soapModel.setCompanyId(model.getCompanyId());
037 soapModel.setUserId(model.getUserId());
038 soapModel.setUserName(model.getUserName());
039 soapModel.setCreateDate(model.getCreateDate());
040 soapModel.setModifiedDate(model.getModifiedDate());
041 soapModel.setCode(model.getCode());
042 soapModel.setName(model.getName());
043 soapModel.setDescription(model.getDescription());
044 soapModel.setStartDate(model.getStartDate());
045 soapModel.setEndDate(model.getEndDate());
046 soapModel.setActive(model.getActive());
047 soapModel.setLimitCategories(model.getLimitCategories());
048 soapModel.setLimitSkus(model.getLimitSkus());
049 soapModel.setMinOrder(model.getMinOrder());
050 soapModel.setDiscount(model.getDiscount());
051 soapModel.setDiscountType(model.getDiscountType());
052
053 return soapModel;
054 }
055
056 public static ShoppingCouponSoap[] toSoapModels(ShoppingCoupon[] models) {
057 ShoppingCouponSoap[] soapModels = new ShoppingCouponSoap[models.length];
058
059 for (int i = 0; i < models.length; i++) {
060 soapModels[i] = toSoapModel(models[i]);
061 }
062
063 return soapModels;
064 }
065
066 public static ShoppingCouponSoap[][] toSoapModels(ShoppingCoupon[][] models) {
067 ShoppingCouponSoap[][] soapModels = null;
068
069 if (models.length > 0) {
070 soapModels = new ShoppingCouponSoap[models.length][models[0].length];
071 }
072 else {
073 soapModels = new ShoppingCouponSoap[0][0];
074 }
075
076 for (int i = 0; i < models.length; i++) {
077 soapModels[i] = toSoapModels(models[i]);
078 }
079
080 return soapModels;
081 }
082
083 public static ShoppingCouponSoap[] toSoapModels(List<ShoppingCoupon> models) {
084 List<ShoppingCouponSoap> soapModels = new ArrayList<ShoppingCouponSoap>(models.size());
085
086 for (ShoppingCoupon model : models) {
087 soapModels.add(toSoapModel(model));
088 }
089
090 return soapModels.toArray(new ShoppingCouponSoap[soapModels.size()]);
091 }
092
093 public ShoppingCouponSoap() {
094 }
095
096 public long getPrimaryKey() {
097 return _couponId;
098 }
099
100 public void setPrimaryKey(long pk) {
101 setCouponId(pk);
102 }
103
104 public long getCouponId() {
105 return _couponId;
106 }
107
108 public void setCouponId(long couponId) {
109 _couponId = couponId;
110 }
111
112 public long getGroupId() {
113 return _groupId;
114 }
115
116 public void setGroupId(long groupId) {
117 _groupId = groupId;
118 }
119
120 public long getCompanyId() {
121 return _companyId;
122 }
123
124 public void setCompanyId(long companyId) {
125 _companyId = companyId;
126 }
127
128 public long getUserId() {
129 return _userId;
130 }
131
132 public void setUserId(long userId) {
133 _userId = userId;
134 }
135
136 public String getUserName() {
137 return _userName;
138 }
139
140 public void setUserName(String userName) {
141 _userName = userName;
142 }
143
144 public Date getCreateDate() {
145 return _createDate;
146 }
147
148 public void setCreateDate(Date createDate) {
149 _createDate = createDate;
150 }
151
152 public Date getModifiedDate() {
153 return _modifiedDate;
154 }
155
156 public void setModifiedDate(Date modifiedDate) {
157 _modifiedDate = modifiedDate;
158 }
159
160 public String getCode() {
161 return _code;
162 }
163
164 public void setCode(String code) {
165 _code = code;
166 }
167
168 public String getName() {
169 return _name;
170 }
171
172 public void setName(String name) {
173 _name = name;
174 }
175
176 public String getDescription() {
177 return _description;
178 }
179
180 public void setDescription(String description) {
181 _description = description;
182 }
183
184 public Date getStartDate() {
185 return _startDate;
186 }
187
188 public void setStartDate(Date startDate) {
189 _startDate = startDate;
190 }
191
192 public Date getEndDate() {
193 return _endDate;
194 }
195
196 public void setEndDate(Date endDate) {
197 _endDate = endDate;
198 }
199
200 public boolean getActive() {
201 return _active;
202 }
203
204 public boolean isActive() {
205 return _active;
206 }
207
208 public void setActive(boolean active) {
209 _active = active;
210 }
211
212 public String getLimitCategories() {
213 return _limitCategories;
214 }
215
216 public void setLimitCategories(String limitCategories) {
217 _limitCategories = limitCategories;
218 }
219
220 public String getLimitSkus() {
221 return _limitSkus;
222 }
223
224 public void setLimitSkus(String limitSkus) {
225 _limitSkus = limitSkus;
226 }
227
228 public double getMinOrder() {
229 return _minOrder;
230 }
231
232 public void setMinOrder(double minOrder) {
233 _minOrder = minOrder;
234 }
235
236 public double getDiscount() {
237 return _discount;
238 }
239
240 public void setDiscount(double discount) {
241 _discount = discount;
242 }
243
244 public String getDiscountType() {
245 return _discountType;
246 }
247
248 public void setDiscountType(String discountType) {
249 _discountType = discountType;
250 }
251
252 private long _couponId;
253 private long _groupId;
254 private long _companyId;
255 private long _userId;
256 private String _userName;
257 private Date _createDate;
258 private Date _modifiedDate;
259 private String _code;
260 private String _name;
261 private String _description;
262 private Date _startDate;
263 private Date _endDate;
264 private boolean _active;
265 private String _limitCategories;
266 private String _limitSkus;
267 private double _minOrder;
268 private double _discount;
269 private String _discountType;
270 }