001
014
015 package com.liferay.portlet.shopping.model;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import java.io.Serializable;
020
021 import java.util.ArrayList;
022 import java.util.List;
023
024
030 @ProviderType
031 public class ShoppingItemPriceSoap implements Serializable {
032 public static ShoppingItemPriceSoap toSoapModel(ShoppingItemPrice model) {
033 ShoppingItemPriceSoap soapModel = new ShoppingItemPriceSoap();
034
035 soapModel.setItemPriceId(model.getItemPriceId());
036 soapModel.setItemId(model.getItemId());
037 soapModel.setMinQuantity(model.getMinQuantity());
038 soapModel.setMaxQuantity(model.getMaxQuantity());
039 soapModel.setPrice(model.getPrice());
040 soapModel.setDiscount(model.getDiscount());
041 soapModel.setTaxable(model.getTaxable());
042 soapModel.setShipping(model.getShipping());
043 soapModel.setUseShippingFormula(model.getUseShippingFormula());
044 soapModel.setStatus(model.getStatus());
045
046 return soapModel;
047 }
048
049 public static ShoppingItemPriceSoap[] toSoapModels(
050 ShoppingItemPrice[] models) {
051 ShoppingItemPriceSoap[] soapModels = new ShoppingItemPriceSoap[models.length];
052
053 for (int i = 0; i < models.length; i++) {
054 soapModels[i] = toSoapModel(models[i]);
055 }
056
057 return soapModels;
058 }
059
060 public static ShoppingItemPriceSoap[][] toSoapModels(
061 ShoppingItemPrice[][] models) {
062 ShoppingItemPriceSoap[][] soapModels = null;
063
064 if (models.length > 0) {
065 soapModels = new ShoppingItemPriceSoap[models.length][models[0].length];
066 }
067 else {
068 soapModels = new ShoppingItemPriceSoap[0][0];
069 }
070
071 for (int i = 0; i < models.length; i++) {
072 soapModels[i] = toSoapModels(models[i]);
073 }
074
075 return soapModels;
076 }
077
078 public static ShoppingItemPriceSoap[] toSoapModels(
079 List<ShoppingItemPrice> models) {
080 List<ShoppingItemPriceSoap> soapModels = new ArrayList<ShoppingItemPriceSoap>(models.size());
081
082 for (ShoppingItemPrice model : models) {
083 soapModels.add(toSoapModel(model));
084 }
085
086 return soapModels.toArray(new ShoppingItemPriceSoap[soapModels.size()]);
087 }
088
089 public ShoppingItemPriceSoap() {
090 }
091
092 public long getPrimaryKey() {
093 return _itemPriceId;
094 }
095
096 public void setPrimaryKey(long pk) {
097 setItemPriceId(pk);
098 }
099
100 public long getItemPriceId() {
101 return _itemPriceId;
102 }
103
104 public void setItemPriceId(long itemPriceId) {
105 _itemPriceId = itemPriceId;
106 }
107
108 public long getItemId() {
109 return _itemId;
110 }
111
112 public void setItemId(long itemId) {
113 _itemId = itemId;
114 }
115
116 public int getMinQuantity() {
117 return _minQuantity;
118 }
119
120 public void setMinQuantity(int minQuantity) {
121 _minQuantity = minQuantity;
122 }
123
124 public int getMaxQuantity() {
125 return _maxQuantity;
126 }
127
128 public void setMaxQuantity(int maxQuantity) {
129 _maxQuantity = maxQuantity;
130 }
131
132 public double getPrice() {
133 return _price;
134 }
135
136 public void setPrice(double price) {
137 _price = price;
138 }
139
140 public double getDiscount() {
141 return _discount;
142 }
143
144 public void setDiscount(double discount) {
145 _discount = discount;
146 }
147
148 public boolean getTaxable() {
149 return _taxable;
150 }
151
152 public boolean isTaxable() {
153 return _taxable;
154 }
155
156 public void setTaxable(boolean taxable) {
157 _taxable = taxable;
158 }
159
160 public double getShipping() {
161 return _shipping;
162 }
163
164 public void setShipping(double shipping) {
165 _shipping = shipping;
166 }
167
168 public boolean getUseShippingFormula() {
169 return _useShippingFormula;
170 }
171
172 public boolean isUseShippingFormula() {
173 return _useShippingFormula;
174 }
175
176 public void setUseShippingFormula(boolean useShippingFormula) {
177 _useShippingFormula = useShippingFormula;
178 }
179
180 public int getStatus() {
181 return _status;
182 }
183
184 public void setStatus(int status) {
185 _status = status;
186 }
187
188 private long _itemPriceId;
189 private long _itemId;
190 private int _minQuantity;
191 private int _maxQuantity;
192 private double _price;
193 private double _discount;
194 private boolean _taxable;
195 private double _shipping;
196 private boolean _useShippingFormula;
197 private int _status;
198 }