001
014
015 package com.liferay.portal.kernel.model;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.expando.kernel.model.ExpandoBridge;
020
021 import com.liferay.exportimport.kernel.lar.StagedModelType;
022
023 import com.liferay.portal.kernel.service.ServiceContext;
024
025 import java.io.Serializable;
026
027 import java.util.Date;
028 import java.util.HashMap;
029 import java.util.Map;
030 import java.util.Objects;
031
032
041 @ProviderType
042 public class PasswordPolicyWrapper implements PasswordPolicy,
043 ModelWrapper<PasswordPolicy> {
044 public PasswordPolicyWrapper(PasswordPolicy passwordPolicy) {
045 _passwordPolicy = passwordPolicy;
046 }
047
048 @Override
049 public Class<?> getModelClass() {
050 return PasswordPolicy.class;
051 }
052
053 @Override
054 public String getModelClassName() {
055 return PasswordPolicy.class.getName();
056 }
057
058 @Override
059 public Map<String, Object> getModelAttributes() {
060 Map<String, Object> attributes = new HashMap<String, Object>();
061
062 attributes.put("mvccVersion", getMvccVersion());
063 attributes.put("uuid", getUuid());
064 attributes.put("passwordPolicyId", getPasswordPolicyId());
065 attributes.put("companyId", getCompanyId());
066 attributes.put("userId", getUserId());
067 attributes.put("userName", getUserName());
068 attributes.put("createDate", getCreateDate());
069 attributes.put("modifiedDate", getModifiedDate());
070 attributes.put("defaultPolicy", getDefaultPolicy());
071 attributes.put("name", getName());
072 attributes.put("description", getDescription());
073 attributes.put("changeable", getChangeable());
074 attributes.put("changeRequired", getChangeRequired());
075 attributes.put("minAge", getMinAge());
076 attributes.put("checkSyntax", getCheckSyntax());
077 attributes.put("allowDictionaryWords", getAllowDictionaryWords());
078 attributes.put("minAlphanumeric", getMinAlphanumeric());
079 attributes.put("minLength", getMinLength());
080 attributes.put("minLowerCase", getMinLowerCase());
081 attributes.put("minNumbers", getMinNumbers());
082 attributes.put("minSymbols", getMinSymbols());
083 attributes.put("minUpperCase", getMinUpperCase());
084 attributes.put("regex", getRegex());
085 attributes.put("history", getHistory());
086 attributes.put("historyCount", getHistoryCount());
087 attributes.put("expireable", getExpireable());
088 attributes.put("maxAge", getMaxAge());
089 attributes.put("warningTime", getWarningTime());
090 attributes.put("graceLimit", getGraceLimit());
091 attributes.put("lockout", getLockout());
092 attributes.put("maxFailure", getMaxFailure());
093 attributes.put("lockoutDuration", getLockoutDuration());
094 attributes.put("requireUnlock", getRequireUnlock());
095 attributes.put("resetFailureCount", getResetFailureCount());
096 attributes.put("resetTicketMaxAge", getResetTicketMaxAge());
097
098 return attributes;
099 }
100
101 @Override
102 public void setModelAttributes(Map<String, Object> attributes) {
103 Long mvccVersion = (Long)attributes.get("mvccVersion");
104
105 if (mvccVersion != null) {
106 setMvccVersion(mvccVersion);
107 }
108
109 String uuid = (String)attributes.get("uuid");
110
111 if (uuid != null) {
112 setUuid(uuid);
113 }
114
115 Long passwordPolicyId = (Long)attributes.get("passwordPolicyId");
116
117 if (passwordPolicyId != null) {
118 setPasswordPolicyId(passwordPolicyId);
119 }
120
121 Long companyId = (Long)attributes.get("companyId");
122
123 if (companyId != null) {
124 setCompanyId(companyId);
125 }
126
127 Long userId = (Long)attributes.get("userId");
128
129 if (userId != null) {
130 setUserId(userId);
131 }
132
133 String userName = (String)attributes.get("userName");
134
135 if (userName != null) {
136 setUserName(userName);
137 }
138
139 Date createDate = (Date)attributes.get("createDate");
140
141 if (createDate != null) {
142 setCreateDate(createDate);
143 }
144
145 Date modifiedDate = (Date)attributes.get("modifiedDate");
146
147 if (modifiedDate != null) {
148 setModifiedDate(modifiedDate);
149 }
150
151 Boolean defaultPolicy = (Boolean)attributes.get("defaultPolicy");
152
153 if (defaultPolicy != null) {
154 setDefaultPolicy(defaultPolicy);
155 }
156
157 String name = (String)attributes.get("name");
158
159 if (name != null) {
160 setName(name);
161 }
162
163 String description = (String)attributes.get("description");
164
165 if (description != null) {
166 setDescription(description);
167 }
168
169 Boolean changeable = (Boolean)attributes.get("changeable");
170
171 if (changeable != null) {
172 setChangeable(changeable);
173 }
174
175 Boolean changeRequired = (Boolean)attributes.get("changeRequired");
176
177 if (changeRequired != null) {
178 setChangeRequired(changeRequired);
179 }
180
181 Long minAge = (Long)attributes.get("minAge");
182
183 if (minAge != null) {
184 setMinAge(minAge);
185 }
186
187 Boolean checkSyntax = (Boolean)attributes.get("checkSyntax");
188
189 if (checkSyntax != null) {
190 setCheckSyntax(checkSyntax);
191 }
192
193 Boolean allowDictionaryWords = (Boolean)attributes.get(
194 "allowDictionaryWords");
195
196 if (allowDictionaryWords != null) {
197 setAllowDictionaryWords(allowDictionaryWords);
198 }
199
200 Integer minAlphanumeric = (Integer)attributes.get("minAlphanumeric");
201
202 if (minAlphanumeric != null) {
203 setMinAlphanumeric(minAlphanumeric);
204 }
205
206 Integer minLength = (Integer)attributes.get("minLength");
207
208 if (minLength != null) {
209 setMinLength(minLength);
210 }
211
212 Integer minLowerCase = (Integer)attributes.get("minLowerCase");
213
214 if (minLowerCase != null) {
215 setMinLowerCase(minLowerCase);
216 }
217
218 Integer minNumbers = (Integer)attributes.get("minNumbers");
219
220 if (minNumbers != null) {
221 setMinNumbers(minNumbers);
222 }
223
224 Integer minSymbols = (Integer)attributes.get("minSymbols");
225
226 if (minSymbols != null) {
227 setMinSymbols(minSymbols);
228 }
229
230 Integer minUpperCase = (Integer)attributes.get("minUpperCase");
231
232 if (minUpperCase != null) {
233 setMinUpperCase(minUpperCase);
234 }
235
236 String regex = (String)attributes.get("regex");
237
238 if (regex != null) {
239 setRegex(regex);
240 }
241
242 Boolean history = (Boolean)attributes.get("history");
243
244 if (history != null) {
245 setHistory(history);
246 }
247
248 Integer historyCount = (Integer)attributes.get("historyCount");
249
250 if (historyCount != null) {
251 setHistoryCount(historyCount);
252 }
253
254 Boolean expireable = (Boolean)attributes.get("expireable");
255
256 if (expireable != null) {
257 setExpireable(expireable);
258 }
259
260 Long maxAge = (Long)attributes.get("maxAge");
261
262 if (maxAge != null) {
263 setMaxAge(maxAge);
264 }
265
266 Long warningTime = (Long)attributes.get("warningTime");
267
268 if (warningTime != null) {
269 setWarningTime(warningTime);
270 }
271
272 Integer graceLimit = (Integer)attributes.get("graceLimit");
273
274 if (graceLimit != null) {
275 setGraceLimit(graceLimit);
276 }
277
278 Boolean lockout = (Boolean)attributes.get("lockout");
279
280 if (lockout != null) {
281 setLockout(lockout);
282 }
283
284 Integer maxFailure = (Integer)attributes.get("maxFailure");
285
286 if (maxFailure != null) {
287 setMaxFailure(maxFailure);
288 }
289
290 Long lockoutDuration = (Long)attributes.get("lockoutDuration");
291
292 if (lockoutDuration != null) {
293 setLockoutDuration(lockoutDuration);
294 }
295
296 Boolean requireUnlock = (Boolean)attributes.get("requireUnlock");
297
298 if (requireUnlock != null) {
299 setRequireUnlock(requireUnlock);
300 }
301
302 Long resetFailureCount = (Long)attributes.get("resetFailureCount");
303
304 if (resetFailureCount != null) {
305 setResetFailureCount(resetFailureCount);
306 }
307
308 Long resetTicketMaxAge = (Long)attributes.get("resetTicketMaxAge");
309
310 if (resetTicketMaxAge != null) {
311 setResetTicketMaxAge(resetTicketMaxAge);
312 }
313 }
314
315 @Override
316 public CacheModel<PasswordPolicy> toCacheModel() {
317 return _passwordPolicy.toCacheModel();
318 }
319
320 @Override
321 public PasswordPolicy toEscapedModel() {
322 return new PasswordPolicyWrapper(_passwordPolicy.toEscapedModel());
323 }
324
325 @Override
326 public PasswordPolicy toUnescapedModel() {
327 return new PasswordPolicyWrapper(_passwordPolicy.toUnescapedModel());
328 }
329
330
335 @Override
336 public boolean getAllowDictionaryWords() {
337 return _passwordPolicy.getAllowDictionaryWords();
338 }
339
340
345 @Override
346 public boolean getChangeRequired() {
347 return _passwordPolicy.getChangeRequired();
348 }
349
350
355 @Override
356 public boolean getChangeable() {
357 return _passwordPolicy.getChangeable();
358 }
359
360
365 @Override
366 public boolean getCheckSyntax() {
367 return _passwordPolicy.getCheckSyntax();
368 }
369
370
375 @Override
376 public boolean getDefaultPolicy() {
377 return _passwordPolicy.getDefaultPolicy();
378 }
379
380
385 @Override
386 public boolean getExpireable() {
387 return _passwordPolicy.getExpireable();
388 }
389
390
395 @Override
396 public boolean getHistory() {
397 return _passwordPolicy.getHistory();
398 }
399
400
405 @Override
406 public boolean getLockout() {
407 return _passwordPolicy.getLockout();
408 }
409
410
415 @Override
416 public boolean getRequireUnlock() {
417 return _passwordPolicy.getRequireUnlock();
418 }
419
420
425 @Override
426 public boolean isAllowDictionaryWords() {
427 return _passwordPolicy.isAllowDictionaryWords();
428 }
429
430 @Override
431 public boolean isCachedModel() {
432 return _passwordPolicy.isCachedModel();
433 }
434
435
440 @Override
441 public boolean isChangeRequired() {
442 return _passwordPolicy.isChangeRequired();
443 }
444
445
450 @Override
451 public boolean isChangeable() {
452 return _passwordPolicy.isChangeable();
453 }
454
455
460 @Override
461 public boolean isCheckSyntax() {
462 return _passwordPolicy.isCheckSyntax();
463 }
464
465
470 @Override
471 public boolean isDefaultPolicy() {
472 return _passwordPolicy.isDefaultPolicy();
473 }
474
475 @Override
476 public boolean isEscapedModel() {
477 return _passwordPolicy.isEscapedModel();
478 }
479
480
485 @Override
486 public boolean isExpireable() {
487 return _passwordPolicy.isExpireable();
488 }
489
490
495 @Override
496 public boolean isHistory() {
497 return _passwordPolicy.isHistory();
498 }
499
500
505 @Override
506 public boolean isLockout() {
507 return _passwordPolicy.isLockout();
508 }
509
510 @Override
511 public boolean isNew() {
512 return _passwordPolicy.isNew();
513 }
514
515
520 @Override
521 public boolean isRequireUnlock() {
522 return _passwordPolicy.isRequireUnlock();
523 }
524
525 @Override
526 public ExpandoBridge getExpandoBridge() {
527 return _passwordPolicy.getExpandoBridge();
528 }
529
530 @Override
531 public int compareTo(PasswordPolicy passwordPolicy) {
532 return _passwordPolicy.compareTo(passwordPolicy);
533 }
534
535
540 @Override
541 public int getGraceLimit() {
542 return _passwordPolicy.getGraceLimit();
543 }
544
545
550 @Override
551 public int getHistoryCount() {
552 return _passwordPolicy.getHistoryCount();
553 }
554
555
560 @Override
561 public int getMaxFailure() {
562 return _passwordPolicy.getMaxFailure();
563 }
564
565
570 @Override
571 public int getMinAlphanumeric() {
572 return _passwordPolicy.getMinAlphanumeric();
573 }
574
575
580 @Override
581 public int getMinLength() {
582 return _passwordPolicy.getMinLength();
583 }
584
585
590 @Override
591 public int getMinLowerCase() {
592 return _passwordPolicy.getMinLowerCase();
593 }
594
595
600 @Override
601 public int getMinNumbers() {
602 return _passwordPolicy.getMinNumbers();
603 }
604
605
610 @Override
611 public int getMinSymbols() {
612 return _passwordPolicy.getMinSymbols();
613 }
614
615
620 @Override
621 public int getMinUpperCase() {
622 return _passwordPolicy.getMinUpperCase();
623 }
624
625 @Override
626 public int hashCode() {
627 return _passwordPolicy.hashCode();
628 }
629
630 @Override
631 public Serializable getPrimaryKeyObj() {
632 return _passwordPolicy.getPrimaryKeyObj();
633 }
634
635 @Override
636 public java.lang.Object clone() {
637 return new PasswordPolicyWrapper((PasswordPolicy)_passwordPolicy.clone());
638 }
639
640
645 @Override
646 public java.lang.String getDescription() {
647 return _passwordPolicy.getDescription();
648 }
649
650
655 @Override
656 public java.lang.String getName() {
657 return _passwordPolicy.getName();
658 }
659
660
665 @Override
666 public java.lang.String getRegex() {
667 return _passwordPolicy.getRegex();
668 }
669
670
675 @Override
676 public java.lang.String getUserName() {
677 return _passwordPolicy.getUserName();
678 }
679
680
685 @Override
686 public java.lang.String getUserUuid() {
687 return _passwordPolicy.getUserUuid();
688 }
689
690
695 @Override
696 public java.lang.String getUuid() {
697 return _passwordPolicy.getUuid();
698 }
699
700 @Override
701 public java.lang.String toString() {
702 return _passwordPolicy.toString();
703 }
704
705 @Override
706 public java.lang.String toXmlString() {
707 return _passwordPolicy.toXmlString();
708 }
709
710
715 @Override
716 public Date getCreateDate() {
717 return _passwordPolicy.getCreateDate();
718 }
719
720
725 @Override
726 public Date getModifiedDate() {
727 return _passwordPolicy.getModifiedDate();
728 }
729
730
735 @Override
736 public long getCompanyId() {
737 return _passwordPolicy.getCompanyId();
738 }
739
740
745 @Override
746 public long getLockoutDuration() {
747 return _passwordPolicy.getLockoutDuration();
748 }
749
750
755 @Override
756 public long getMaxAge() {
757 return _passwordPolicy.getMaxAge();
758 }
759
760
765 @Override
766 public long getMinAge() {
767 return _passwordPolicy.getMinAge();
768 }
769
770
775 @Override
776 public long getMvccVersion() {
777 return _passwordPolicy.getMvccVersion();
778 }
779
780
785 @Override
786 public long getPasswordPolicyId() {
787 return _passwordPolicy.getPasswordPolicyId();
788 }
789
790
795 @Override
796 public long getPrimaryKey() {
797 return _passwordPolicy.getPrimaryKey();
798 }
799
800
805 @Override
806 public long getResetFailureCount() {
807 return _passwordPolicy.getResetFailureCount();
808 }
809
810
815 @Override
816 public long getResetTicketMaxAge() {
817 return _passwordPolicy.getResetTicketMaxAge();
818 }
819
820
825 @Override
826 public long getUserId() {
827 return _passwordPolicy.getUserId();
828 }
829
830
835 @Override
836 public long getWarningTime() {
837 return _passwordPolicy.getWarningTime();
838 }
839
840 @Override
841 public void persist() {
842 _passwordPolicy.persist();
843 }
844
845
850 @Override
851 public void setAllowDictionaryWords(boolean allowDictionaryWords) {
852 _passwordPolicy.setAllowDictionaryWords(allowDictionaryWords);
853 }
854
855 @Override
856 public void setCachedModel(boolean cachedModel) {
857 _passwordPolicy.setCachedModel(cachedModel);
858 }
859
860
865 @Override
866 public void setChangeRequired(boolean changeRequired) {
867 _passwordPolicy.setChangeRequired(changeRequired);
868 }
869
870
875 @Override
876 public void setChangeable(boolean changeable) {
877 _passwordPolicy.setChangeable(changeable);
878 }
879
880
885 @Override
886 public void setCheckSyntax(boolean checkSyntax) {
887 _passwordPolicy.setCheckSyntax(checkSyntax);
888 }
889
890
895 @Override
896 public void setCompanyId(long companyId) {
897 _passwordPolicy.setCompanyId(companyId);
898 }
899
900
905 @Override
906 public void setCreateDate(Date createDate) {
907 _passwordPolicy.setCreateDate(createDate);
908 }
909
910
915 @Override
916 public void setDefaultPolicy(boolean defaultPolicy) {
917 _passwordPolicy.setDefaultPolicy(defaultPolicy);
918 }
919
920
925 @Override
926 public void setDescription(java.lang.String description) {
927 _passwordPolicy.setDescription(description);
928 }
929
930 @Override
931 public void setExpandoBridgeAttributes(BaseModel<?> baseModel) {
932 _passwordPolicy.setExpandoBridgeAttributes(baseModel);
933 }
934
935 @Override
936 public void setExpandoBridgeAttributes(ExpandoBridge expandoBridge) {
937 _passwordPolicy.setExpandoBridgeAttributes(expandoBridge);
938 }
939
940 @Override
941 public void setExpandoBridgeAttributes(ServiceContext serviceContext) {
942 _passwordPolicy.setExpandoBridgeAttributes(serviceContext);
943 }
944
945
950 @Override
951 public void setExpireable(boolean expireable) {
952 _passwordPolicy.setExpireable(expireable);
953 }
954
955
960 @Override
961 public void setGraceLimit(int graceLimit) {
962 _passwordPolicy.setGraceLimit(graceLimit);
963 }
964
965
970 @Override
971 public void setHistory(boolean history) {
972 _passwordPolicy.setHistory(history);
973 }
974
975
980 @Override
981 public void setHistoryCount(int historyCount) {
982 _passwordPolicy.setHistoryCount(historyCount);
983 }
984
985
990 @Override
991 public void setLockout(boolean lockout) {
992 _passwordPolicy.setLockout(lockout);
993 }
994
995
1000 @Override
1001 public void setLockoutDuration(long lockoutDuration) {
1002 _passwordPolicy.setLockoutDuration(lockoutDuration);
1003 }
1004
1005
1010 @Override
1011 public void setMaxAge(long maxAge) {
1012 _passwordPolicy.setMaxAge(maxAge);
1013 }
1014
1015
1020 @Override
1021 public void setMaxFailure(int maxFailure) {
1022 _passwordPolicy.setMaxFailure(maxFailure);
1023 }
1024
1025
1030 @Override
1031 public void setMinAge(long minAge) {
1032 _passwordPolicy.setMinAge(minAge);
1033 }
1034
1035
1040 @Override
1041 public void setMinAlphanumeric(int minAlphanumeric) {
1042 _passwordPolicy.setMinAlphanumeric(minAlphanumeric);
1043 }
1044
1045
1050 @Override
1051 public void setMinLength(int minLength) {
1052 _passwordPolicy.setMinLength(minLength);
1053 }
1054
1055
1060 @Override
1061 public void setMinLowerCase(int minLowerCase) {
1062 _passwordPolicy.setMinLowerCase(minLowerCase);
1063 }
1064
1065
1070 @Override
1071 public void setMinNumbers(int minNumbers) {
1072 _passwordPolicy.setMinNumbers(minNumbers);
1073 }
1074
1075
1080 @Override
1081 public void setMinSymbols(int minSymbols) {
1082 _passwordPolicy.setMinSymbols(minSymbols);
1083 }
1084
1085
1090 @Override
1091 public void setMinUpperCase(int minUpperCase) {
1092 _passwordPolicy.setMinUpperCase(minUpperCase);
1093 }
1094
1095
1100 @Override
1101 public void setModifiedDate(Date modifiedDate) {
1102 _passwordPolicy.setModifiedDate(modifiedDate);
1103 }
1104
1105
1110 @Override
1111 public void setMvccVersion(long mvccVersion) {
1112 _passwordPolicy.setMvccVersion(mvccVersion);
1113 }
1114
1115
1120 @Override
1121 public void setName(java.lang.String name) {
1122 _passwordPolicy.setName(name);
1123 }
1124
1125 @Override
1126 public void setNew(boolean n) {
1127 _passwordPolicy.setNew(n);
1128 }
1129
1130
1135 @Override
1136 public void setPasswordPolicyId(long passwordPolicyId) {
1137 _passwordPolicy.setPasswordPolicyId(passwordPolicyId);
1138 }
1139
1140
1145 @Override
1146 public void setPrimaryKey(long primaryKey) {
1147 _passwordPolicy.setPrimaryKey(primaryKey);
1148 }
1149
1150 @Override
1151 public void setPrimaryKeyObj(Serializable primaryKeyObj) {
1152 _passwordPolicy.setPrimaryKeyObj(primaryKeyObj);
1153 }
1154
1155
1160 @Override
1161 public void setRegex(java.lang.String regex) {
1162 _passwordPolicy.setRegex(regex);
1163 }
1164
1165
1170 @Override
1171 public void setRequireUnlock(boolean requireUnlock) {
1172 _passwordPolicy.setRequireUnlock(requireUnlock);
1173 }
1174
1175
1180 @Override
1181 public void setResetFailureCount(long resetFailureCount) {
1182 _passwordPolicy.setResetFailureCount(resetFailureCount);
1183 }
1184
1185
1190 @Override
1191 public void setResetTicketMaxAge(long resetTicketMaxAge) {
1192 _passwordPolicy.setResetTicketMaxAge(resetTicketMaxAge);
1193 }
1194
1195
1200 @Override
1201 public void setUserId(long userId) {
1202 _passwordPolicy.setUserId(userId);
1203 }
1204
1205
1210 @Override
1211 public void setUserName(java.lang.String userName) {
1212 _passwordPolicy.setUserName(userName);
1213 }
1214
1215
1220 @Override
1221 public void setUserUuid(java.lang.String userUuid) {
1222 _passwordPolicy.setUserUuid(userUuid);
1223 }
1224
1225
1230 @Override
1231 public void setUuid(java.lang.String uuid) {
1232 _passwordPolicy.setUuid(uuid);
1233 }
1234
1235
1240 @Override
1241 public void setWarningTime(long warningTime) {
1242 _passwordPolicy.setWarningTime(warningTime);
1243 }
1244
1245 @Override
1246 public boolean equals(Object obj) {
1247 if (this == obj) {
1248 return true;
1249 }
1250
1251 if (!(obj instanceof PasswordPolicyWrapper)) {
1252 return false;
1253 }
1254
1255 PasswordPolicyWrapper passwordPolicyWrapper = (PasswordPolicyWrapper)obj;
1256
1257 if (Objects.equals(_passwordPolicy,
1258 passwordPolicyWrapper._passwordPolicy)) {
1259 return true;
1260 }
1261
1262 return false;
1263 }
1264
1265 @Override
1266 public StagedModelType getStagedModelType() {
1267 return _passwordPolicy.getStagedModelType();
1268 }
1269
1270 @Override
1271 public PasswordPolicy getWrappedModel() {
1272 return _passwordPolicy;
1273 }
1274
1275 @Override
1276 public boolean isEntityCacheEnabled() {
1277 return _passwordPolicy.isEntityCacheEnabled();
1278 }
1279
1280 @Override
1281 public boolean isFinderCacheEnabled() {
1282 return _passwordPolicy.isFinderCacheEnabled();
1283 }
1284
1285 @Override
1286 public void resetOriginalValues() {
1287 _passwordPolicy.resetOriginalValues();
1288 }
1289
1290 private final PasswordPolicy _passwordPolicy;
1291 }