1   /**
2    * Copyright (c) 2000-2009 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.portal.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="PasswordPolicySoap.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   * <code>com.liferay.portal.service.http.PasswordPolicyServiceSoap</code>.
42   * </p>
43   *
44   * @author Brian Wing Shun Chan
45   *
46   * @see com.liferay.portal.service.http.PasswordPolicyServiceSoap
47   *
48   */
49  public class PasswordPolicySoap implements Serializable {
50      public static PasswordPolicySoap toSoapModel(PasswordPolicy model) {
51          PasswordPolicySoap soapModel = new PasswordPolicySoap();
52  
53          soapModel.setPasswordPolicyId(model.getPasswordPolicyId());
54          soapModel.setCompanyId(model.getCompanyId());
55          soapModel.setUserId(model.getUserId());
56          soapModel.setUserName(model.getUserName());
57          soapModel.setCreateDate(model.getCreateDate());
58          soapModel.setModifiedDate(model.getModifiedDate());
59          soapModel.setDefaultPolicy(model.getDefaultPolicy());
60          soapModel.setName(model.getName());
61          soapModel.setDescription(model.getDescription());
62          soapModel.setChangeable(model.getChangeable());
63          soapModel.setChangeRequired(model.getChangeRequired());
64          soapModel.setMinAge(model.getMinAge());
65          soapModel.setCheckSyntax(model.getCheckSyntax());
66          soapModel.setAllowDictionaryWords(model.getAllowDictionaryWords());
67          soapModel.setMinLength(model.getMinLength());
68          soapModel.setHistory(model.getHistory());
69          soapModel.setHistoryCount(model.getHistoryCount());
70          soapModel.setExpireable(model.getExpireable());
71          soapModel.setMaxAge(model.getMaxAge());
72          soapModel.setWarningTime(model.getWarningTime());
73          soapModel.setGraceLimit(model.getGraceLimit());
74          soapModel.setLockout(model.getLockout());
75          soapModel.setMaxFailure(model.getMaxFailure());
76          soapModel.setLockoutDuration(model.getLockoutDuration());
77          soapModel.setRequireUnlock(model.getRequireUnlock());
78          soapModel.setResetFailureCount(model.getResetFailureCount());
79  
80          return soapModel;
81      }
82  
83      public static PasswordPolicySoap[] toSoapModels(PasswordPolicy[] models) {
84          PasswordPolicySoap[] soapModels = new PasswordPolicySoap[models.length];
85  
86          for (int i = 0; i < models.length; i++) {
87              soapModels[i] = toSoapModel(models[i]);
88          }
89  
90          return soapModels;
91      }
92  
93      public static PasswordPolicySoap[][] toSoapModels(PasswordPolicy[][] models) {
94          PasswordPolicySoap[][] soapModels = null;
95  
96          if (models.length > 0) {
97              soapModels = new PasswordPolicySoap[models.length][models[0].length];
98          }
99          else {
100             soapModels = new PasswordPolicySoap[0][0];
101         }
102 
103         for (int i = 0; i < models.length; i++) {
104             soapModels[i] = toSoapModels(models[i]);
105         }
106 
107         return soapModels;
108     }
109 
110     public static PasswordPolicySoap[] toSoapModels(List<PasswordPolicy> models) {
111         List<PasswordPolicySoap> soapModels = new ArrayList<PasswordPolicySoap>(models.size());
112 
113         for (PasswordPolicy model : models) {
114             soapModels.add(toSoapModel(model));
115         }
116 
117         return soapModels.toArray(new PasswordPolicySoap[soapModels.size()]);
118     }
119 
120     public PasswordPolicySoap() {
121     }
122 
123     public long getPrimaryKey() {
124         return _passwordPolicyId;
125     }
126 
127     public void setPrimaryKey(long pk) {
128         setPasswordPolicyId(pk);
129     }
130 
131     public long getPasswordPolicyId() {
132         return _passwordPolicyId;
133     }
134 
135     public void setPasswordPolicyId(long passwordPolicyId) {
136         _passwordPolicyId = passwordPolicyId;
137     }
138 
139     public long getCompanyId() {
140         return _companyId;
141     }
142 
143     public void setCompanyId(long companyId) {
144         _companyId = companyId;
145     }
146 
147     public long getUserId() {
148         return _userId;
149     }
150 
151     public void setUserId(long userId) {
152         _userId = userId;
153     }
154 
155     public String getUserName() {
156         return _userName;
157     }
158 
159     public void setUserName(String userName) {
160         _userName = userName;
161     }
162 
163     public Date getCreateDate() {
164         return _createDate;
165     }
166 
167     public void setCreateDate(Date createDate) {
168         _createDate = createDate;
169     }
170 
171     public Date getModifiedDate() {
172         return _modifiedDate;
173     }
174 
175     public void setModifiedDate(Date modifiedDate) {
176         _modifiedDate = modifiedDate;
177     }
178 
179     public boolean getDefaultPolicy() {
180         return _defaultPolicy;
181     }
182 
183     public boolean isDefaultPolicy() {
184         return _defaultPolicy;
185     }
186 
187     public void setDefaultPolicy(boolean defaultPolicy) {
188         _defaultPolicy = defaultPolicy;
189     }
190 
191     public String getName() {
192         return _name;
193     }
194 
195     public void setName(String name) {
196         _name = name;
197     }
198 
199     public String getDescription() {
200         return _description;
201     }
202 
203     public void setDescription(String description) {
204         _description = description;
205     }
206 
207     public boolean getChangeable() {
208         return _changeable;
209     }
210 
211     public boolean isChangeable() {
212         return _changeable;
213     }
214 
215     public void setChangeable(boolean changeable) {
216         _changeable = changeable;
217     }
218 
219     public boolean getChangeRequired() {
220         return _changeRequired;
221     }
222 
223     public boolean isChangeRequired() {
224         return _changeRequired;
225     }
226 
227     public void setChangeRequired(boolean changeRequired) {
228         _changeRequired = changeRequired;
229     }
230 
231     public long getMinAge() {
232         return _minAge;
233     }
234 
235     public void setMinAge(long minAge) {
236         _minAge = minAge;
237     }
238 
239     public boolean getCheckSyntax() {
240         return _checkSyntax;
241     }
242 
243     public boolean isCheckSyntax() {
244         return _checkSyntax;
245     }
246 
247     public void setCheckSyntax(boolean checkSyntax) {
248         _checkSyntax = checkSyntax;
249     }
250 
251     public boolean getAllowDictionaryWords() {
252         return _allowDictionaryWords;
253     }
254 
255     public boolean isAllowDictionaryWords() {
256         return _allowDictionaryWords;
257     }
258 
259     public void setAllowDictionaryWords(boolean allowDictionaryWords) {
260         _allowDictionaryWords = allowDictionaryWords;
261     }
262 
263     public int getMinLength() {
264         return _minLength;
265     }
266 
267     public void setMinLength(int minLength) {
268         _minLength = minLength;
269     }
270 
271     public boolean getHistory() {
272         return _history;
273     }
274 
275     public boolean isHistory() {
276         return _history;
277     }
278 
279     public void setHistory(boolean history) {
280         _history = history;
281     }
282 
283     public int getHistoryCount() {
284         return _historyCount;
285     }
286 
287     public void setHistoryCount(int historyCount) {
288         _historyCount = historyCount;
289     }
290 
291     public boolean getExpireable() {
292         return _expireable;
293     }
294 
295     public boolean isExpireable() {
296         return _expireable;
297     }
298 
299     public void setExpireable(boolean expireable) {
300         _expireable = expireable;
301     }
302 
303     public long getMaxAge() {
304         return _maxAge;
305     }
306 
307     public void setMaxAge(long maxAge) {
308         _maxAge = maxAge;
309     }
310 
311     public long getWarningTime() {
312         return _warningTime;
313     }
314 
315     public void setWarningTime(long warningTime) {
316         _warningTime = warningTime;
317     }
318 
319     public int getGraceLimit() {
320         return _graceLimit;
321     }
322 
323     public void setGraceLimit(int graceLimit) {
324         _graceLimit = graceLimit;
325     }
326 
327     public boolean getLockout() {
328         return _lockout;
329     }
330 
331     public boolean isLockout() {
332         return _lockout;
333     }
334 
335     public void setLockout(boolean lockout) {
336         _lockout = lockout;
337     }
338 
339     public int getMaxFailure() {
340         return _maxFailure;
341     }
342 
343     public void setMaxFailure(int maxFailure) {
344         _maxFailure = maxFailure;
345     }
346 
347     public long getLockoutDuration() {
348         return _lockoutDuration;
349     }
350 
351     public void setLockoutDuration(long lockoutDuration) {
352         _lockoutDuration = lockoutDuration;
353     }
354 
355     public boolean getRequireUnlock() {
356         return _requireUnlock;
357     }
358 
359     public boolean isRequireUnlock() {
360         return _requireUnlock;
361     }
362 
363     public void setRequireUnlock(boolean requireUnlock) {
364         _requireUnlock = requireUnlock;
365     }
366 
367     public long getResetFailureCount() {
368         return _resetFailureCount;
369     }
370 
371     public void setResetFailureCount(long resetFailureCount) {
372         _resetFailureCount = resetFailureCount;
373     }
374 
375     private long _passwordPolicyId;
376     private long _companyId;
377     private long _userId;
378     private String _userName;
379     private Date _createDate;
380     private Date _modifiedDate;
381     private boolean _defaultPolicy;
382     private String _name;
383     private String _description;
384     private boolean _changeable;
385     private boolean _changeRequired;
386     private long _minAge;
387     private boolean _checkSyntax;
388     private boolean _allowDictionaryWords;
389     private int _minLength;
390     private boolean _history;
391     private int _historyCount;
392     private boolean _expireable;
393     private long _maxAge;
394     private long _warningTime;
395     private int _graceLimit;
396     private boolean _lockout;
397     private int _maxFailure;
398     private long _lockoutDuration;
399     private boolean _requireUnlock;
400     private long _resetFailureCount;
401 }