1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    *
5    *
6    *
7    * The contents of this file are subject to the terms of the Liferay Enterprise
8    * Subscription License ("License"). You may not use this file except in
9    * compliance with the License. You can obtain a copy of the License by
10   * contacting Liferay, Inc. See the License for the specific language governing
11   * permissions and limitations under the License, including but not limited to
12   * distribution rights 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.polls.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="PollsQuestionSoap.java.html"><b><i>View Source</i></b></a>
33   *
34   * <p>
35   * ServiceBuilder generated this class. Modifications in this class will be
36   * overwritten the next time is generated.
37   * </p>
38   *
39   * <p>
40   * This class is used by
41   * {@link com.liferay.portlet.polls.service.http.PollsQuestionServiceSoap}.
42   * </p>
43   *
44   * @author    Brian Wing Shun Chan
45   * @see       com.liferay.portlet.polls.service.http.PollsQuestionServiceSoap
46   * @generated
47   */
48  public class PollsQuestionSoap implements Serializable {
49      public static PollsQuestionSoap toSoapModel(PollsQuestion model) {
50          PollsQuestionSoap soapModel = new PollsQuestionSoap();
51  
52          soapModel.setUuid(model.getUuid());
53          soapModel.setQuestionId(model.getQuestionId());
54          soapModel.setGroupId(model.getGroupId());
55          soapModel.setCompanyId(model.getCompanyId());
56          soapModel.setUserId(model.getUserId());
57          soapModel.setUserName(model.getUserName());
58          soapModel.setCreateDate(model.getCreateDate());
59          soapModel.setModifiedDate(model.getModifiedDate());
60          soapModel.setTitle(model.getTitle());
61          soapModel.setDescription(model.getDescription());
62          soapModel.setExpirationDate(model.getExpirationDate());
63          soapModel.setLastVoteDate(model.getLastVoteDate());
64  
65          return soapModel;
66      }
67  
68      public static PollsQuestionSoap[] toSoapModels(PollsQuestion[] models) {
69          PollsQuestionSoap[] soapModels = new PollsQuestionSoap[models.length];
70  
71          for (int i = 0; i < models.length; i++) {
72              soapModels[i] = toSoapModel(models[i]);
73          }
74  
75          return soapModels;
76      }
77  
78      public static PollsQuestionSoap[][] toSoapModels(PollsQuestion[][] models) {
79          PollsQuestionSoap[][] soapModels = null;
80  
81          if (models.length > 0) {
82              soapModels = new PollsQuestionSoap[models.length][models[0].length];
83          }
84          else {
85              soapModels = new PollsQuestionSoap[0][0];
86          }
87  
88          for (int i = 0; i < models.length; i++) {
89              soapModels[i] = toSoapModels(models[i]);
90          }
91  
92          return soapModels;
93      }
94  
95      public static PollsQuestionSoap[] toSoapModels(List<PollsQuestion> models) {
96          List<PollsQuestionSoap> soapModels = new ArrayList<PollsQuestionSoap>(models.size());
97  
98          for (PollsQuestion model : models) {
99              soapModels.add(toSoapModel(model));
100         }
101 
102         return soapModels.toArray(new PollsQuestionSoap[soapModels.size()]);
103     }
104 
105     public PollsQuestionSoap() {
106     }
107 
108     public long getPrimaryKey() {
109         return _questionId;
110     }
111 
112     public void setPrimaryKey(long pk) {
113         setQuestionId(pk);
114     }
115 
116     public String getUuid() {
117         return _uuid;
118     }
119 
120     public void setUuid(String uuid) {
121         _uuid = uuid;
122     }
123 
124     public long getQuestionId() {
125         return _questionId;
126     }
127 
128     public void setQuestionId(long questionId) {
129         _questionId = questionId;
130     }
131 
132     public long getGroupId() {
133         return _groupId;
134     }
135 
136     public void setGroupId(long groupId) {
137         _groupId = groupId;
138     }
139 
140     public long getCompanyId() {
141         return _companyId;
142     }
143 
144     public void setCompanyId(long companyId) {
145         _companyId = companyId;
146     }
147 
148     public long getUserId() {
149         return _userId;
150     }
151 
152     public void setUserId(long userId) {
153         _userId = userId;
154     }
155 
156     public String getUserName() {
157         return _userName;
158     }
159 
160     public void setUserName(String userName) {
161         _userName = userName;
162     }
163 
164     public Date getCreateDate() {
165         return _createDate;
166     }
167 
168     public void setCreateDate(Date createDate) {
169         _createDate = createDate;
170     }
171 
172     public Date getModifiedDate() {
173         return _modifiedDate;
174     }
175 
176     public void setModifiedDate(Date modifiedDate) {
177         _modifiedDate = modifiedDate;
178     }
179 
180     public String getTitle() {
181         return _title;
182     }
183 
184     public void setTitle(String title) {
185         _title = title;
186     }
187 
188     public String getDescription() {
189         return _description;
190     }
191 
192     public void setDescription(String description) {
193         _description = description;
194     }
195 
196     public Date getExpirationDate() {
197         return _expirationDate;
198     }
199 
200     public void setExpirationDate(Date expirationDate) {
201         _expirationDate = expirationDate;
202     }
203 
204     public Date getLastVoteDate() {
205         return _lastVoteDate;
206     }
207 
208     public void setLastVoteDate(Date lastVoteDate) {
209         _lastVoteDate = lastVoteDate;
210     }
211 
212     private String _uuid;
213     private long _questionId;
214     private long _groupId;
215     private long _companyId;
216     private long _userId;
217     private String _userName;
218     private Date _createDate;
219     private Date _modifiedDate;
220     private String _title;
221     private String _description;
222     private Date _expirationDate;
223     private Date _lastVoteDate;
224 }