001
014
015 package com.liferay.portal.model;
016
017 import com.liferay.portal.kernel.util.Validator;
018
019 import java.util.Date;
020 import java.util.HashMap;
021 import java.util.Map;
022
023
032 public class WebsiteWrapper implements Website, ModelWrapper<Website> {
033 public WebsiteWrapper(Website website) {
034 _website = website;
035 }
036
037 public Class<?> getModelClass() {
038 return Website.class;
039 }
040
041 public String getModelClassName() {
042 return Website.class.getName();
043 }
044
045 public Map<String, Object> getModelAttributes() {
046 Map<String, Object> attributes = new HashMap<String, Object>();
047
048 attributes.put("websiteId", getWebsiteId());
049 attributes.put("companyId", getCompanyId());
050 attributes.put("userId", getUserId());
051 attributes.put("userName", getUserName());
052 attributes.put("createDate", getCreateDate());
053 attributes.put("modifiedDate", getModifiedDate());
054 attributes.put("classNameId", getClassNameId());
055 attributes.put("classPK", getClassPK());
056 attributes.put("url", getUrl());
057 attributes.put("typeId", getTypeId());
058 attributes.put("primary", getPrimary());
059
060 return attributes;
061 }
062
063 public void setModelAttributes(Map<String, Object> attributes) {
064 Long websiteId = (Long)attributes.get("websiteId");
065
066 if (websiteId != null) {
067 setWebsiteId(websiteId);
068 }
069
070 Long companyId = (Long)attributes.get("companyId");
071
072 if (companyId != null) {
073 setCompanyId(companyId);
074 }
075
076 Long userId = (Long)attributes.get("userId");
077
078 if (userId != null) {
079 setUserId(userId);
080 }
081
082 String userName = (String)attributes.get("userName");
083
084 if (userName != null) {
085 setUserName(userName);
086 }
087
088 Date createDate = (Date)attributes.get("createDate");
089
090 if (createDate != null) {
091 setCreateDate(createDate);
092 }
093
094 Date modifiedDate = (Date)attributes.get("modifiedDate");
095
096 if (modifiedDate != null) {
097 setModifiedDate(modifiedDate);
098 }
099
100 Long classNameId = (Long)attributes.get("classNameId");
101
102 if (classNameId != null) {
103 setClassNameId(classNameId);
104 }
105
106 Long classPK = (Long)attributes.get("classPK");
107
108 if (classPK != null) {
109 setClassPK(classPK);
110 }
111
112 String url = (String)attributes.get("url");
113
114 if (url != null) {
115 setUrl(url);
116 }
117
118 Integer typeId = (Integer)attributes.get("typeId");
119
120 if (typeId != null) {
121 setTypeId(typeId);
122 }
123
124 Boolean primary = (Boolean)attributes.get("primary");
125
126 if (primary != null) {
127 setPrimary(primary);
128 }
129 }
130
131
136 public long getPrimaryKey() {
137 return _website.getPrimaryKey();
138 }
139
140
145 public void setPrimaryKey(long primaryKey) {
146 _website.setPrimaryKey(primaryKey);
147 }
148
149
154 public long getWebsiteId() {
155 return _website.getWebsiteId();
156 }
157
158
163 public void setWebsiteId(long websiteId) {
164 _website.setWebsiteId(websiteId);
165 }
166
167
172 public long getCompanyId() {
173 return _website.getCompanyId();
174 }
175
176
181 public void setCompanyId(long companyId) {
182 _website.setCompanyId(companyId);
183 }
184
185
190 public long getUserId() {
191 return _website.getUserId();
192 }
193
194
199 public void setUserId(long userId) {
200 _website.setUserId(userId);
201 }
202
203
209 public java.lang.String getUserUuid()
210 throws com.liferay.portal.kernel.exception.SystemException {
211 return _website.getUserUuid();
212 }
213
214
219 public void setUserUuid(java.lang.String userUuid) {
220 _website.setUserUuid(userUuid);
221 }
222
223
228 public java.lang.String getUserName() {
229 return _website.getUserName();
230 }
231
232
237 public void setUserName(java.lang.String userName) {
238 _website.setUserName(userName);
239 }
240
241
246 public java.util.Date getCreateDate() {
247 return _website.getCreateDate();
248 }
249
250
255 public void setCreateDate(java.util.Date createDate) {
256 _website.setCreateDate(createDate);
257 }
258
259
264 public java.util.Date getModifiedDate() {
265 return _website.getModifiedDate();
266 }
267
268
273 public void setModifiedDate(java.util.Date modifiedDate) {
274 _website.setModifiedDate(modifiedDate);
275 }
276
277
282 public java.lang.String getClassName() {
283 return _website.getClassName();
284 }
285
286 public void setClassName(java.lang.String className) {
287 _website.setClassName(className);
288 }
289
290
295 public long getClassNameId() {
296 return _website.getClassNameId();
297 }
298
299
304 public void setClassNameId(long classNameId) {
305 _website.setClassNameId(classNameId);
306 }
307
308
313 public long getClassPK() {
314 return _website.getClassPK();
315 }
316
317
322 public void setClassPK(long classPK) {
323 _website.setClassPK(classPK);
324 }
325
326
331 public java.lang.String getUrl() {
332 return _website.getUrl();
333 }
334
335
340 public void setUrl(java.lang.String url) {
341 _website.setUrl(url);
342 }
343
344
349 public int getTypeId() {
350 return _website.getTypeId();
351 }
352
353
358 public void setTypeId(int typeId) {
359 _website.setTypeId(typeId);
360 }
361
362
367 public boolean getPrimary() {
368 return _website.getPrimary();
369 }
370
371
376 public boolean isPrimary() {
377 return _website.isPrimary();
378 }
379
380
385 public void setPrimary(boolean primary) {
386 _website.setPrimary(primary);
387 }
388
389 public boolean isNew() {
390 return _website.isNew();
391 }
392
393 public void setNew(boolean n) {
394 _website.setNew(n);
395 }
396
397 public boolean isCachedModel() {
398 return _website.isCachedModel();
399 }
400
401 public void setCachedModel(boolean cachedModel) {
402 _website.setCachedModel(cachedModel);
403 }
404
405 public boolean isEscapedModel() {
406 return _website.isEscapedModel();
407 }
408
409 public java.io.Serializable getPrimaryKeyObj() {
410 return _website.getPrimaryKeyObj();
411 }
412
413 public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
414 _website.setPrimaryKeyObj(primaryKeyObj);
415 }
416
417 public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
418 return _website.getExpandoBridge();
419 }
420
421 public void setExpandoBridgeAttributes(
422 com.liferay.portal.service.ServiceContext serviceContext) {
423 _website.setExpandoBridgeAttributes(serviceContext);
424 }
425
426 @Override
427 public java.lang.Object clone() {
428 return new WebsiteWrapper((Website)_website.clone());
429 }
430
431 public int compareTo(com.liferay.portal.model.Website website) {
432 return _website.compareTo(website);
433 }
434
435 @Override
436 public int hashCode() {
437 return _website.hashCode();
438 }
439
440 public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Website> toCacheModel() {
441 return _website.toCacheModel();
442 }
443
444 public com.liferay.portal.model.Website toEscapedModel() {
445 return new WebsiteWrapper(_website.toEscapedModel());
446 }
447
448 public com.liferay.portal.model.Website toUnescapedModel() {
449 return new WebsiteWrapper(_website.toUnescapedModel());
450 }
451
452 @Override
453 public java.lang.String toString() {
454 return _website.toString();
455 }
456
457 public java.lang.String toXmlString() {
458 return _website.toXmlString();
459 }
460
461 public void persist()
462 throws com.liferay.portal.kernel.exception.SystemException {
463 _website.persist();
464 }
465
466 public com.liferay.portal.model.ListType getType()
467 throws com.liferay.portal.kernel.exception.PortalException,
468 com.liferay.portal.kernel.exception.SystemException {
469 return _website.getType();
470 }
471
472 @Override
473 public boolean equals(Object obj) {
474 if (this == obj) {
475 return true;
476 }
477
478 if (!(obj instanceof WebsiteWrapper)) {
479 return false;
480 }
481
482 WebsiteWrapper websiteWrapper = (WebsiteWrapper)obj;
483
484 if (Validator.equals(_website, websiteWrapper._website)) {
485 return true;
486 }
487
488 return false;
489 }
490
491
494 public Website getWrappedWebsite() {
495 return _website;
496 }
497
498 public Website getWrappedModel() {
499 return _website;
500 }
501
502 public void resetOriginalValues() {
503 _website.resetOriginalValues();
504 }
505
506 private Website _website;
507 }