1   /**
2    * Copyright (c) 2000-2007 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portlet.shopping.model;
24  
25  import java.io.Serializable;
26  
27  import java.util.ArrayList;
28  import java.util.Date;
29  import java.util.List;
30  
31  /**
32   * <a href="ShoppingCategorySoap.java.html"><b><i>View Source</i></b></a>
33   *
34   * <p>
35   * ServiceBuilder generated this class. Modifications in this class will be overwritten
36   * the next time is generated.
37   * </p>
38   *
39   * <p>
40   * This class is used by <code>com.liferay.portlet.shopping.service.http.ShoppingCategoryServiceSoap</code>.
41   * </p>
42   *
43   * @author Brian Wing Shun Chan
44   *
45   * @see com.liferay.portlet.shopping.service.http.ShoppingCategoryServiceSoap
46   *
47   */
48  public class ShoppingCategorySoap implements Serializable {
49      public static ShoppingCategorySoap toSoapModel(ShoppingCategory model) {
50          ShoppingCategorySoap soapModel = new ShoppingCategorySoap();
51          soapModel.setCategoryId(model.getCategoryId());
52          soapModel.setGroupId(model.getGroupId());
53          soapModel.setCompanyId(model.getCompanyId());
54          soapModel.setUserId(model.getUserId());
55          soapModel.setUserName(model.getUserName());
56          soapModel.setCreateDate(model.getCreateDate());
57          soapModel.setModifiedDate(model.getModifiedDate());
58          soapModel.setParentCategoryId(model.getParentCategoryId());
59          soapModel.setName(model.getName());
60          soapModel.setDescription(model.getDescription());
61  
62          return soapModel;
63      }
64  
65      public static ShoppingCategorySoap[] toSoapModels(List models) {
66          List soapModels = new ArrayList(models.size());
67  
68          for (int i = 0; i < models.size(); i++) {
69              ShoppingCategory model = (ShoppingCategory)models.get(i);
70              soapModels.add(toSoapModel(model));
71          }
72  
73          return (ShoppingCategorySoap[])soapModels.toArray(new ShoppingCategorySoap[0]);
74      }
75  
76      public ShoppingCategorySoap() {
77      }
78  
79      public long getPrimaryKey() {
80          return _categoryId;
81      }
82  
83      public void setPrimaryKey(long pk) {
84          setCategoryId(pk);
85      }
86  
87      public long getCategoryId() {
88          return _categoryId;
89      }
90  
91      public void setCategoryId(long categoryId) {
92          _categoryId = categoryId;
93      }
94  
95      public long getGroupId() {
96          return _groupId;
97      }
98  
99      public void setGroupId(long groupId) {
100         _groupId = groupId;
101     }
102 
103     public long getCompanyId() {
104         return _companyId;
105     }
106 
107     public void setCompanyId(long companyId) {
108         _companyId = companyId;
109     }
110 
111     public long getUserId() {
112         return _userId;
113     }
114 
115     public void setUserId(long userId) {
116         _userId = userId;
117     }
118 
119     public String getUserName() {
120         return _userName;
121     }
122 
123     public void setUserName(String userName) {
124         _userName = userName;
125     }
126 
127     public Date getCreateDate() {
128         return _createDate;
129     }
130 
131     public void setCreateDate(Date createDate) {
132         _createDate = createDate;
133     }
134 
135     public Date getModifiedDate() {
136         return _modifiedDate;
137     }
138 
139     public void setModifiedDate(Date modifiedDate) {
140         _modifiedDate = modifiedDate;
141     }
142 
143     public long getParentCategoryId() {
144         return _parentCategoryId;
145     }
146 
147     public void setParentCategoryId(long parentCategoryId) {
148         _parentCategoryId = parentCategoryId;
149     }
150 
151     public String getName() {
152         return _name;
153     }
154 
155     public void setName(String name) {
156         _name = name;
157     }
158 
159     public String getDescription() {
160         return _description;
161     }
162 
163     public void setDescription(String description) {
164         _description = description;
165     }
166 
167     private long _categoryId;
168     private long _groupId;
169     private long _companyId;
170     private long _userId;
171     private String _userName;
172     private Date _createDate;
173     private Date _modifiedDate;
174     private long _parentCategoryId;
175     private String _name;
176     private String _description;
177 }