001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
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.Date;
023    import java.util.List;
024    
025    /**
026     * This class is used by SOAP remote services.
027     *
028     * @author Brian Wing Shun Chan
029     * @generated
030     */
031    @ProviderType
032    public class ShoppingOrderItemSoap implements Serializable {
033            public static ShoppingOrderItemSoap toSoapModel(ShoppingOrderItem model) {
034                    ShoppingOrderItemSoap soapModel = new ShoppingOrderItemSoap();
035    
036                    soapModel.setOrderItemId(model.getOrderItemId());
037                    soapModel.setOrderId(model.getOrderId());
038                    soapModel.setItemId(model.getItemId());
039                    soapModel.setSku(model.getSku());
040                    soapModel.setName(model.getName());
041                    soapModel.setDescription(model.getDescription());
042                    soapModel.setProperties(model.getProperties());
043                    soapModel.setPrice(model.getPrice());
044                    soapModel.setQuantity(model.getQuantity());
045                    soapModel.setShippedDate(model.getShippedDate());
046    
047                    return soapModel;
048            }
049    
050            public static ShoppingOrderItemSoap[] toSoapModels(
051                    ShoppingOrderItem[] models) {
052                    ShoppingOrderItemSoap[] soapModels = new ShoppingOrderItemSoap[models.length];
053    
054                    for (int i = 0; i < models.length; i++) {
055                            soapModels[i] = toSoapModel(models[i]);
056                    }
057    
058                    return soapModels;
059            }
060    
061            public static ShoppingOrderItemSoap[][] toSoapModels(
062                    ShoppingOrderItem[][] models) {
063                    ShoppingOrderItemSoap[][] soapModels = null;
064    
065                    if (models.length > 0) {
066                            soapModels = new ShoppingOrderItemSoap[models.length][models[0].length];
067                    }
068                    else {
069                            soapModels = new ShoppingOrderItemSoap[0][0];
070                    }
071    
072                    for (int i = 0; i < models.length; i++) {
073                            soapModels[i] = toSoapModels(models[i]);
074                    }
075    
076                    return soapModels;
077            }
078    
079            public static ShoppingOrderItemSoap[] toSoapModels(
080                    List<ShoppingOrderItem> models) {
081                    List<ShoppingOrderItemSoap> soapModels = new ArrayList<ShoppingOrderItemSoap>(models.size());
082    
083                    for (ShoppingOrderItem model : models) {
084                            soapModels.add(toSoapModel(model));
085                    }
086    
087                    return soapModels.toArray(new ShoppingOrderItemSoap[soapModels.size()]);
088            }
089    
090            public ShoppingOrderItemSoap() {
091            }
092    
093            public long getPrimaryKey() {
094                    return _orderItemId;
095            }
096    
097            public void setPrimaryKey(long pk) {
098                    setOrderItemId(pk);
099            }
100    
101            public long getOrderItemId() {
102                    return _orderItemId;
103            }
104    
105            public void setOrderItemId(long orderItemId) {
106                    _orderItemId = orderItemId;
107            }
108    
109            public long getOrderId() {
110                    return _orderId;
111            }
112    
113            public void setOrderId(long orderId) {
114                    _orderId = orderId;
115            }
116    
117            public String getItemId() {
118                    return _itemId;
119            }
120    
121            public void setItemId(String itemId) {
122                    _itemId = itemId;
123            }
124    
125            public String getSku() {
126                    return _sku;
127            }
128    
129            public void setSku(String sku) {
130                    _sku = sku;
131            }
132    
133            public String getName() {
134                    return _name;
135            }
136    
137            public void setName(String name) {
138                    _name = name;
139            }
140    
141            public String getDescription() {
142                    return _description;
143            }
144    
145            public void setDescription(String description) {
146                    _description = description;
147            }
148    
149            public String getProperties() {
150                    return _properties;
151            }
152    
153            public void setProperties(String properties) {
154                    _properties = properties;
155            }
156    
157            public double getPrice() {
158                    return _price;
159            }
160    
161            public void setPrice(double price) {
162                    _price = price;
163            }
164    
165            public int getQuantity() {
166                    return _quantity;
167            }
168    
169            public void setQuantity(int quantity) {
170                    _quantity = quantity;
171            }
172    
173            public Date getShippedDate() {
174                    return _shippedDate;
175            }
176    
177            public void setShippedDate(Date shippedDate) {
178                    _shippedDate = shippedDate;
179            }
180    
181            private long _orderItemId;
182            private long _orderId;
183            private String _itemId;
184            private String _sku;
185            private String _name;
186            private String _description;
187            private String _properties;
188            private double _price;
189            private int _quantity;
190            private Date _shippedDate;
191    }