001
014
015 package com.liferay.portlet.polls.model;
016
017 import com.liferay.portal.model.ModelWrapper;
018
019 import java.util.Date;
020 import java.util.HashMap;
021 import java.util.Map;
022
023
032 public class PollsQuestionWrapper implements PollsQuestion,
033 ModelWrapper<PollsQuestion> {
034 public PollsQuestionWrapper(PollsQuestion pollsQuestion) {
035 _pollsQuestion = pollsQuestion;
036 }
037
038 public Class<?> getModelClass() {
039 return PollsQuestion.class;
040 }
041
042 public String getModelClassName() {
043 return PollsQuestion.class.getName();
044 }
045
046 public Map<String, Object> getModelAttributes() {
047 Map<String, Object> attributes = new HashMap<String, Object>();
048
049 attributes.put("uuid", getUuid());
050 attributes.put("questionId", getQuestionId());
051 attributes.put("groupId", getGroupId());
052 attributes.put("companyId", getCompanyId());
053 attributes.put("userId", getUserId());
054 attributes.put("userName", getUserName());
055 attributes.put("createDate", getCreateDate());
056 attributes.put("modifiedDate", getModifiedDate());
057 attributes.put("title", getTitle());
058 attributes.put("description", getDescription());
059 attributes.put("expirationDate", getExpirationDate());
060 attributes.put("lastVoteDate", getLastVoteDate());
061
062 return attributes;
063 }
064
065 public void setModelAttributes(Map<String, Object> attributes) {
066 String uuid = (String)attributes.get("uuid");
067
068 if (uuid != null) {
069 setUuid(uuid);
070 }
071
072 Long questionId = (Long)attributes.get("questionId");
073
074 if (questionId != null) {
075 setQuestionId(questionId);
076 }
077
078 Long groupId = (Long)attributes.get("groupId");
079
080 if (groupId != null) {
081 setGroupId(groupId);
082 }
083
084 Long companyId = (Long)attributes.get("companyId");
085
086 if (companyId != null) {
087 setCompanyId(companyId);
088 }
089
090 Long userId = (Long)attributes.get("userId");
091
092 if (userId != null) {
093 setUserId(userId);
094 }
095
096 String userName = (String)attributes.get("userName");
097
098 if (userName != null) {
099 setUserName(userName);
100 }
101
102 Date createDate = (Date)attributes.get("createDate");
103
104 if (createDate != null) {
105 setCreateDate(createDate);
106 }
107
108 Date modifiedDate = (Date)attributes.get("modifiedDate");
109
110 if (modifiedDate != null) {
111 setModifiedDate(modifiedDate);
112 }
113
114 String title = (String)attributes.get("title");
115
116 if (title != null) {
117 setTitle(title);
118 }
119
120 String description = (String)attributes.get("description");
121
122 if (description != null) {
123 setDescription(description);
124 }
125
126 Date expirationDate = (Date)attributes.get("expirationDate");
127
128 if (expirationDate != null) {
129 setExpirationDate(expirationDate);
130 }
131
132 Date lastVoteDate = (Date)attributes.get("lastVoteDate");
133
134 if (lastVoteDate != null) {
135 setLastVoteDate(lastVoteDate);
136 }
137 }
138
139
144 public long getPrimaryKey() {
145 return _pollsQuestion.getPrimaryKey();
146 }
147
148
153 public void setPrimaryKey(long primaryKey) {
154 _pollsQuestion.setPrimaryKey(primaryKey);
155 }
156
157
162 public java.lang.String getUuid() {
163 return _pollsQuestion.getUuid();
164 }
165
166
171 public void setUuid(java.lang.String uuid) {
172 _pollsQuestion.setUuid(uuid);
173 }
174
175
180 public long getQuestionId() {
181 return _pollsQuestion.getQuestionId();
182 }
183
184
189 public void setQuestionId(long questionId) {
190 _pollsQuestion.setQuestionId(questionId);
191 }
192
193
198 public long getGroupId() {
199 return _pollsQuestion.getGroupId();
200 }
201
202
207 public void setGroupId(long groupId) {
208 _pollsQuestion.setGroupId(groupId);
209 }
210
211
216 public long getCompanyId() {
217 return _pollsQuestion.getCompanyId();
218 }
219
220
225 public void setCompanyId(long companyId) {
226 _pollsQuestion.setCompanyId(companyId);
227 }
228
229
234 public long getUserId() {
235 return _pollsQuestion.getUserId();
236 }
237
238
243 public void setUserId(long userId) {
244 _pollsQuestion.setUserId(userId);
245 }
246
247
253 public java.lang.String getUserUuid()
254 throws com.liferay.portal.kernel.exception.SystemException {
255 return _pollsQuestion.getUserUuid();
256 }
257
258
263 public void setUserUuid(java.lang.String userUuid) {
264 _pollsQuestion.setUserUuid(userUuid);
265 }
266
267
272 public java.lang.String getUserName() {
273 return _pollsQuestion.getUserName();
274 }
275
276
281 public void setUserName(java.lang.String userName) {
282 _pollsQuestion.setUserName(userName);
283 }
284
285
290 public java.util.Date getCreateDate() {
291 return _pollsQuestion.getCreateDate();
292 }
293
294
299 public void setCreateDate(java.util.Date createDate) {
300 _pollsQuestion.setCreateDate(createDate);
301 }
302
303
308 public java.util.Date getModifiedDate() {
309 return _pollsQuestion.getModifiedDate();
310 }
311
312
317 public void setModifiedDate(java.util.Date modifiedDate) {
318 _pollsQuestion.setModifiedDate(modifiedDate);
319 }
320
321
326 public java.lang.String getTitle() {
327 return _pollsQuestion.getTitle();
328 }
329
330
336 public java.lang.String getTitle(java.util.Locale locale) {
337 return _pollsQuestion.getTitle(locale);
338 }
339
340
347 public java.lang.String getTitle(java.util.Locale locale, boolean useDefault) {
348 return _pollsQuestion.getTitle(locale, useDefault);
349 }
350
351
357 public java.lang.String getTitle(java.lang.String languageId) {
358 return _pollsQuestion.getTitle(languageId);
359 }
360
361
368 public java.lang.String getTitle(java.lang.String languageId,
369 boolean useDefault) {
370 return _pollsQuestion.getTitle(languageId, useDefault);
371 }
372
373 public java.lang.String getTitleCurrentLanguageId() {
374 return _pollsQuestion.getTitleCurrentLanguageId();
375 }
376
377 public java.lang.String getTitleCurrentValue() {
378 return _pollsQuestion.getTitleCurrentValue();
379 }
380
381
386 public java.util.Map<java.util.Locale, java.lang.String> getTitleMap() {
387 return _pollsQuestion.getTitleMap();
388 }
389
390
395 public void setTitle(java.lang.String title) {
396 _pollsQuestion.setTitle(title);
397 }
398
399
405 public void setTitle(java.lang.String title, java.util.Locale locale) {
406 _pollsQuestion.setTitle(title, locale);
407 }
408
409
416 public void setTitle(java.lang.String title, java.util.Locale locale,
417 java.util.Locale defaultLocale) {
418 _pollsQuestion.setTitle(title, locale, defaultLocale);
419 }
420
421 public void setTitleCurrentLanguageId(java.lang.String languageId) {
422 _pollsQuestion.setTitleCurrentLanguageId(languageId);
423 }
424
425
430 public void setTitleMap(
431 java.util.Map<java.util.Locale, java.lang.String> titleMap) {
432 _pollsQuestion.setTitleMap(titleMap);
433 }
434
435
441 public void setTitleMap(
442 java.util.Map<java.util.Locale, java.lang.String> titleMap,
443 java.util.Locale defaultLocale) {
444 _pollsQuestion.setTitleMap(titleMap, defaultLocale);
445 }
446
447
452 public java.lang.String getDescription() {
453 return _pollsQuestion.getDescription();
454 }
455
456
462 public java.lang.String getDescription(java.util.Locale locale) {
463 return _pollsQuestion.getDescription(locale);
464 }
465
466
473 public java.lang.String getDescription(java.util.Locale locale,
474 boolean useDefault) {
475 return _pollsQuestion.getDescription(locale, useDefault);
476 }
477
478
484 public java.lang.String getDescription(java.lang.String languageId) {
485 return _pollsQuestion.getDescription(languageId);
486 }
487
488
495 public java.lang.String getDescription(java.lang.String languageId,
496 boolean useDefault) {
497 return _pollsQuestion.getDescription(languageId, useDefault);
498 }
499
500 public java.lang.String getDescriptionCurrentLanguageId() {
501 return _pollsQuestion.getDescriptionCurrentLanguageId();
502 }
503
504 public java.lang.String getDescriptionCurrentValue() {
505 return _pollsQuestion.getDescriptionCurrentValue();
506 }
507
508
513 public java.util.Map<java.util.Locale, java.lang.String> getDescriptionMap() {
514 return _pollsQuestion.getDescriptionMap();
515 }
516
517
522 public void setDescription(java.lang.String description) {
523 _pollsQuestion.setDescription(description);
524 }
525
526
532 public void setDescription(java.lang.String description,
533 java.util.Locale locale) {
534 _pollsQuestion.setDescription(description, locale);
535 }
536
537
544 public void setDescription(java.lang.String description,
545 java.util.Locale locale, java.util.Locale defaultLocale) {
546 _pollsQuestion.setDescription(description, locale, defaultLocale);
547 }
548
549 public void setDescriptionCurrentLanguageId(java.lang.String languageId) {
550 _pollsQuestion.setDescriptionCurrentLanguageId(languageId);
551 }
552
553
558 public void setDescriptionMap(
559 java.util.Map<java.util.Locale, java.lang.String> descriptionMap) {
560 _pollsQuestion.setDescriptionMap(descriptionMap);
561 }
562
563
569 public void setDescriptionMap(
570 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
571 java.util.Locale defaultLocale) {
572 _pollsQuestion.setDescriptionMap(descriptionMap, defaultLocale);
573 }
574
575
580 public java.util.Date getExpirationDate() {
581 return _pollsQuestion.getExpirationDate();
582 }
583
584
589 public void setExpirationDate(java.util.Date expirationDate) {
590 _pollsQuestion.setExpirationDate(expirationDate);
591 }
592
593
598 public java.util.Date getLastVoteDate() {
599 return _pollsQuestion.getLastVoteDate();
600 }
601
602
607 public void setLastVoteDate(java.util.Date lastVoteDate) {
608 _pollsQuestion.setLastVoteDate(lastVoteDate);
609 }
610
611 public boolean isNew() {
612 return _pollsQuestion.isNew();
613 }
614
615 public void setNew(boolean n) {
616 _pollsQuestion.setNew(n);
617 }
618
619 public boolean isCachedModel() {
620 return _pollsQuestion.isCachedModel();
621 }
622
623 public void setCachedModel(boolean cachedModel) {
624 _pollsQuestion.setCachedModel(cachedModel);
625 }
626
627 public boolean isEscapedModel() {
628 return _pollsQuestion.isEscapedModel();
629 }
630
631 public java.io.Serializable getPrimaryKeyObj() {
632 return _pollsQuestion.getPrimaryKeyObj();
633 }
634
635 public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
636 _pollsQuestion.setPrimaryKeyObj(primaryKeyObj);
637 }
638
639 public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
640 return _pollsQuestion.getExpandoBridge();
641 }
642
643 public void setExpandoBridgeAttributes(
644 com.liferay.portal.service.ServiceContext serviceContext) {
645 _pollsQuestion.setExpandoBridgeAttributes(serviceContext);
646 }
647
648 public void prepareLocalizedFieldsForImport(
649 java.util.Locale defaultImportLocale)
650 throws com.liferay.portal.LocaleException {
651 _pollsQuestion.prepareLocalizedFieldsForImport(defaultImportLocale);
652 }
653
654 @Override
655 public java.lang.Object clone() {
656 return new PollsQuestionWrapper((PollsQuestion)_pollsQuestion.clone());
657 }
658
659 public int compareTo(
660 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion) {
661 return _pollsQuestion.compareTo(pollsQuestion);
662 }
663
664 @Override
665 public int hashCode() {
666 return _pollsQuestion.hashCode();
667 }
668
669 public com.liferay.portal.model.CacheModel<com.liferay.portlet.polls.model.PollsQuestion> toCacheModel() {
670 return _pollsQuestion.toCacheModel();
671 }
672
673 public com.liferay.portlet.polls.model.PollsQuestion toEscapedModel() {
674 return new PollsQuestionWrapper(_pollsQuestion.toEscapedModel());
675 }
676
677 public com.liferay.portlet.polls.model.PollsQuestion toUnescapedModel() {
678 return new PollsQuestionWrapper(_pollsQuestion.toUnescapedModel());
679 }
680
681 @Override
682 public java.lang.String toString() {
683 return _pollsQuestion.toString();
684 }
685
686 public java.lang.String toXmlString() {
687 return _pollsQuestion.toXmlString();
688 }
689
690 public void persist()
691 throws com.liferay.portal.kernel.exception.SystemException {
692 _pollsQuestion.persist();
693 }
694
695 public java.util.List<com.liferay.portlet.polls.model.PollsChoice> getChoices()
696 throws com.liferay.portal.kernel.exception.SystemException {
697 return _pollsQuestion.getChoices();
698 }
699
700 public int getVotesCount()
701 throws com.liferay.portal.kernel.exception.SystemException {
702 return _pollsQuestion.getVotesCount();
703 }
704
705 public boolean isExpired() {
706 return _pollsQuestion.isExpired();
707 }
708
709 public boolean isExpired(
710 com.liferay.portal.service.ServiceContext serviceContext,
711 java.util.Date defaultCreateDate) {
712 return _pollsQuestion.isExpired(serviceContext, defaultCreateDate);
713 }
714
715
718 public PollsQuestion getWrappedPollsQuestion() {
719 return _pollsQuestion;
720 }
721
722 public PollsQuestion getWrappedModel() {
723 return _pollsQuestion;
724 }
725
726 public void resetOriginalValues() {
727 _pollsQuestion.resetOriginalValues();
728 }
729
730 private PollsQuestion _pollsQuestion;
731 }