001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.model;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.util.Validator;
020    
021    import com.liferay.portlet.exportimport.lar.StagedModelType;
022    
023    import java.util.Date;
024    import java.util.HashMap;
025    import java.util.Map;
026    
027    /**
028     * <p>
029     * This class is a wrapper for {@link Team}.
030     * </p>
031     *
032     * @author Brian Wing Shun Chan
033     * @see Team
034     * @generated
035     */
036    @ProviderType
037    public class TeamWrapper implements Team, ModelWrapper<Team> {
038            public TeamWrapper(Team team) {
039                    _team = team;
040            }
041    
042            @Override
043            public Class<?> getModelClass() {
044                    return Team.class;
045            }
046    
047            @Override
048            public String getModelClassName() {
049                    return Team.class.getName();
050            }
051    
052            @Override
053            public Map<String, Object> getModelAttributes() {
054                    Map<String, Object> attributes = new HashMap<String, Object>();
055    
056                    attributes.put("mvccVersion", getMvccVersion());
057                    attributes.put("uuid", getUuid());
058                    attributes.put("teamId", getTeamId());
059                    attributes.put("companyId", getCompanyId());
060                    attributes.put("userId", getUserId());
061                    attributes.put("userName", getUserName());
062                    attributes.put("createDate", getCreateDate());
063                    attributes.put("modifiedDate", getModifiedDate());
064                    attributes.put("groupId", getGroupId());
065                    attributes.put("name", getName());
066                    attributes.put("description", getDescription());
067                    attributes.put("lastPublishDate", getLastPublishDate());
068    
069                    return attributes;
070            }
071    
072            @Override
073            public void setModelAttributes(Map<String, Object> attributes) {
074                    Long mvccVersion = (Long)attributes.get("mvccVersion");
075    
076                    if (mvccVersion != null) {
077                            setMvccVersion(mvccVersion);
078                    }
079    
080                    String uuid = (String)attributes.get("uuid");
081    
082                    if (uuid != null) {
083                            setUuid(uuid);
084                    }
085    
086                    Long teamId = (Long)attributes.get("teamId");
087    
088                    if (teamId != null) {
089                            setTeamId(teamId);
090                    }
091    
092                    Long companyId = (Long)attributes.get("companyId");
093    
094                    if (companyId != null) {
095                            setCompanyId(companyId);
096                    }
097    
098                    Long userId = (Long)attributes.get("userId");
099    
100                    if (userId != null) {
101                            setUserId(userId);
102                    }
103    
104                    String userName = (String)attributes.get("userName");
105    
106                    if (userName != null) {
107                            setUserName(userName);
108                    }
109    
110                    Date createDate = (Date)attributes.get("createDate");
111    
112                    if (createDate != null) {
113                            setCreateDate(createDate);
114                    }
115    
116                    Date modifiedDate = (Date)attributes.get("modifiedDate");
117    
118                    if (modifiedDate != null) {
119                            setModifiedDate(modifiedDate);
120                    }
121    
122                    Long groupId = (Long)attributes.get("groupId");
123    
124                    if (groupId != null) {
125                            setGroupId(groupId);
126                    }
127    
128                    String name = (String)attributes.get("name");
129    
130                    if (name != null) {
131                            setName(name);
132                    }
133    
134                    String description = (String)attributes.get("description");
135    
136                    if (description != null) {
137                            setDescription(description);
138                    }
139    
140                    Date lastPublishDate = (Date)attributes.get("lastPublishDate");
141    
142                    if (lastPublishDate != null) {
143                            setLastPublishDate(lastPublishDate);
144                    }
145            }
146    
147            @Override
148            public java.lang.Object clone() {
149                    return new TeamWrapper((Team)_team.clone());
150            }
151    
152            @Override
153            public int compareTo(com.liferay.portal.model.Team team) {
154                    return _team.compareTo(team);
155            }
156    
157            /**
158            * Returns the company ID of this team.
159            *
160            * @return the company ID of this team
161            */
162            @Override
163            public long getCompanyId() {
164                    return _team.getCompanyId();
165            }
166    
167            /**
168            * Returns the create date of this team.
169            *
170            * @return the create date of this team
171            */
172            @Override
173            public Date getCreateDate() {
174                    return _team.getCreateDate();
175            }
176    
177            /**
178            * Returns the description of this team.
179            *
180            * @return the description of this team
181            */
182            @Override
183            public java.lang.String getDescription() {
184                    return _team.getDescription();
185            }
186    
187            @Override
188            public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
189                    return _team.getExpandoBridge();
190            }
191    
192            /**
193            * Returns the group ID of this team.
194            *
195            * @return the group ID of this team
196            */
197            @Override
198            public long getGroupId() {
199                    return _team.getGroupId();
200            }
201    
202            /**
203            * Returns the last publish date of this team.
204            *
205            * @return the last publish date of this team
206            */
207            @Override
208            public Date getLastPublishDate() {
209                    return _team.getLastPublishDate();
210            }
211    
212            /**
213            * Returns the modified date of this team.
214            *
215            * @return the modified date of this team
216            */
217            @Override
218            public Date getModifiedDate() {
219                    return _team.getModifiedDate();
220            }
221    
222            /**
223            * Returns the mvcc version of this team.
224            *
225            * @return the mvcc version of this team
226            */
227            @Override
228            public long getMvccVersion() {
229                    return _team.getMvccVersion();
230            }
231    
232            /**
233            * Returns the name of this team.
234            *
235            * @return the name of this team
236            */
237            @Override
238            public java.lang.String getName() {
239                    return _team.getName();
240            }
241    
242            /**
243            * Returns the primary key of this team.
244            *
245            * @return the primary key of this team
246            */
247            @Override
248            public long getPrimaryKey() {
249                    return _team.getPrimaryKey();
250            }
251    
252            @Override
253            public java.io.Serializable getPrimaryKeyObj() {
254                    return _team.getPrimaryKeyObj();
255            }
256    
257            @Override
258            public com.liferay.portal.model.Role getRole()
259                    throws com.liferay.portal.kernel.exception.PortalException {
260                    return _team.getRole();
261            }
262    
263            /**
264            * Returns the team ID of this team.
265            *
266            * @return the team ID of this team
267            */
268            @Override
269            public long getTeamId() {
270                    return _team.getTeamId();
271            }
272    
273            /**
274            * Returns the user ID of this team.
275            *
276            * @return the user ID of this team
277            */
278            @Override
279            public long getUserId() {
280                    return _team.getUserId();
281            }
282    
283            /**
284            * Returns the user name of this team.
285            *
286            * @return the user name of this team
287            */
288            @Override
289            public java.lang.String getUserName() {
290                    return _team.getUserName();
291            }
292    
293            /**
294            * Returns the user uuid of this team.
295            *
296            * @return the user uuid of this team
297            */
298            @Override
299            public java.lang.String getUserUuid() {
300                    return _team.getUserUuid();
301            }
302    
303            /**
304            * Returns the uuid of this team.
305            *
306            * @return the uuid of this team
307            */
308            @Override
309            public java.lang.String getUuid() {
310                    return _team.getUuid();
311            }
312    
313            @Override
314            public int hashCode() {
315                    return _team.hashCode();
316            }
317    
318            @Override
319            public boolean isCachedModel() {
320                    return _team.isCachedModel();
321            }
322    
323            @Override
324            public boolean isEscapedModel() {
325                    return _team.isEscapedModel();
326            }
327    
328            @Override
329            public boolean isNew() {
330                    return _team.isNew();
331            }
332    
333            @Override
334            public void persist() {
335                    _team.persist();
336            }
337    
338            @Override
339            public void setCachedModel(boolean cachedModel) {
340                    _team.setCachedModel(cachedModel);
341            }
342    
343            /**
344            * Sets the company ID of this team.
345            *
346            * @param companyId the company ID of this team
347            */
348            @Override
349            public void setCompanyId(long companyId) {
350                    _team.setCompanyId(companyId);
351            }
352    
353            /**
354            * Sets the create date of this team.
355            *
356            * @param createDate the create date of this team
357            */
358            @Override
359            public void setCreateDate(Date createDate) {
360                    _team.setCreateDate(createDate);
361            }
362    
363            /**
364            * Sets the description of this team.
365            *
366            * @param description the description of this team
367            */
368            @Override
369            public void setDescription(java.lang.String description) {
370                    _team.setDescription(description);
371            }
372    
373            @Override
374            public void setExpandoBridgeAttributes(BaseModel<?> baseModel) {
375                    _team.setExpandoBridgeAttributes(baseModel);
376            }
377    
378            @Override
379            public void setExpandoBridgeAttributes(
380                    com.liferay.portlet.expando.model.ExpandoBridge expandoBridge) {
381                    _team.setExpandoBridgeAttributes(expandoBridge);
382            }
383    
384            @Override
385            public void setExpandoBridgeAttributes(
386                    com.liferay.portal.service.ServiceContext serviceContext) {
387                    _team.setExpandoBridgeAttributes(serviceContext);
388            }
389    
390            /**
391            * Sets the group ID of this team.
392            *
393            * @param groupId the group ID of this team
394            */
395            @Override
396            public void setGroupId(long groupId) {
397                    _team.setGroupId(groupId);
398            }
399    
400            /**
401            * Sets the last publish date of this team.
402            *
403            * @param lastPublishDate the last publish date of this team
404            */
405            @Override
406            public void setLastPublishDate(Date lastPublishDate) {
407                    _team.setLastPublishDate(lastPublishDate);
408            }
409    
410            /**
411            * Sets the modified date of this team.
412            *
413            * @param modifiedDate the modified date of this team
414            */
415            @Override
416            public void setModifiedDate(Date modifiedDate) {
417                    _team.setModifiedDate(modifiedDate);
418            }
419    
420            /**
421            * Sets the mvcc version of this team.
422            *
423            * @param mvccVersion the mvcc version of this team
424            */
425            @Override
426            public void setMvccVersion(long mvccVersion) {
427                    _team.setMvccVersion(mvccVersion);
428            }
429    
430            /**
431            * Sets the name of this team.
432            *
433            * @param name the name of this team
434            */
435            @Override
436            public void setName(java.lang.String name) {
437                    _team.setName(name);
438            }
439    
440            @Override
441            public void setNew(boolean n) {
442                    _team.setNew(n);
443            }
444    
445            /**
446            * Sets the primary key of this team.
447            *
448            * @param primaryKey the primary key of this team
449            */
450            @Override
451            public void setPrimaryKey(long primaryKey) {
452                    _team.setPrimaryKey(primaryKey);
453            }
454    
455            @Override
456            public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
457                    _team.setPrimaryKeyObj(primaryKeyObj);
458            }
459    
460            /**
461            * Sets the team ID of this team.
462            *
463            * @param teamId the team ID of this team
464            */
465            @Override
466            public void setTeamId(long teamId) {
467                    _team.setTeamId(teamId);
468            }
469    
470            /**
471            * Sets the user ID of this team.
472            *
473            * @param userId the user ID of this team
474            */
475            @Override
476            public void setUserId(long userId) {
477                    _team.setUserId(userId);
478            }
479    
480            /**
481            * Sets the user name of this team.
482            *
483            * @param userName the user name of this team
484            */
485            @Override
486            public void setUserName(java.lang.String userName) {
487                    _team.setUserName(userName);
488            }
489    
490            /**
491            * Sets the user uuid of this team.
492            *
493            * @param userUuid the user uuid of this team
494            */
495            @Override
496            public void setUserUuid(java.lang.String userUuid) {
497                    _team.setUserUuid(userUuid);
498            }
499    
500            /**
501            * Sets the uuid of this team.
502            *
503            * @param uuid the uuid of this team
504            */
505            @Override
506            public void setUuid(java.lang.String uuid) {
507                    _team.setUuid(uuid);
508            }
509    
510            @Override
511            public CacheModel<com.liferay.portal.model.Team> toCacheModel() {
512                    return _team.toCacheModel();
513            }
514    
515            @Override
516            public com.liferay.portal.model.Team toEscapedModel() {
517                    return new TeamWrapper(_team.toEscapedModel());
518            }
519    
520            @Override
521            public java.lang.String toString() {
522                    return _team.toString();
523            }
524    
525            @Override
526            public com.liferay.portal.model.Team toUnescapedModel() {
527                    return new TeamWrapper(_team.toUnescapedModel());
528            }
529    
530            @Override
531            public java.lang.String toXmlString() {
532                    return _team.toXmlString();
533            }
534    
535            @Override
536            public boolean equals(Object obj) {
537                    if (this == obj) {
538                            return true;
539                    }
540    
541                    if (!(obj instanceof TeamWrapper)) {
542                            return false;
543                    }
544    
545                    TeamWrapper teamWrapper = (TeamWrapper)obj;
546    
547                    if (Validator.equals(_team, teamWrapper._team)) {
548                            return true;
549                    }
550    
551                    return false;
552            }
553    
554            @Override
555            public StagedModelType getStagedModelType() {
556                    return _team.getStagedModelType();
557            }
558    
559            @Override
560            public Team getWrappedModel() {
561                    return _team;
562            }
563    
564            @Override
565            public boolean isEntityCacheEnabled() {
566                    return _team.isEntityCacheEnabled();
567            }
568    
569            @Override
570            public boolean isFinderCacheEnabled() {
571                    return _team.isFinderCacheEnabled();
572            }
573    
574            @Override
575            public void resetOriginalValues() {
576                    _team.resetOriginalValues();
577            }
578    
579            private final Team _team;
580    }