001    /**
002     * Copyright (c) 2000-2012 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 java.util.HashMap;
018    import java.util.Map;
019    
020    /**
021     * <p>
022     * This class is a wrapper for {@link Group}.
023     * </p>
024     *
025     * @author    Brian Wing Shun Chan
026     * @see       Group
027     * @generated
028     */
029    public class GroupWrapper implements Group, ModelWrapper<Group> {
030            public GroupWrapper(Group group) {
031                    _group = group;
032            }
033    
034            public Class<?> getModelClass() {
035                    return Group.class;
036            }
037    
038            public String getModelClassName() {
039                    return Group.class.getName();
040            }
041    
042            public Map<String, Object> getModelAttributes() {
043                    Map<String, Object> attributes = new HashMap<String, Object>();
044    
045                    attributes.put("groupId", getGroupId());
046                    attributes.put("companyId", getCompanyId());
047                    attributes.put("creatorUserId", getCreatorUserId());
048                    attributes.put("classNameId", getClassNameId());
049                    attributes.put("classPK", getClassPK());
050                    attributes.put("parentGroupId", getParentGroupId());
051                    attributes.put("liveGroupId", getLiveGroupId());
052                    attributes.put("name", getName());
053                    attributes.put("description", getDescription());
054                    attributes.put("type", getType());
055                    attributes.put("typeSettings", getTypeSettings());
056                    attributes.put("friendlyURL", getFriendlyURL());
057                    attributes.put("site", getSite());
058                    attributes.put("active", getActive());
059    
060                    return attributes;
061            }
062    
063            public void setModelAttributes(Map<String, Object> attributes) {
064                    Long groupId = (Long)attributes.get("groupId");
065    
066                    if (groupId != null) {
067                            setGroupId(groupId);
068                    }
069    
070                    Long companyId = (Long)attributes.get("companyId");
071    
072                    if (companyId != null) {
073                            setCompanyId(companyId);
074                    }
075    
076                    Long creatorUserId = (Long)attributes.get("creatorUserId");
077    
078                    if (creatorUserId != null) {
079                            setCreatorUserId(creatorUserId);
080                    }
081    
082                    Long classNameId = (Long)attributes.get("classNameId");
083    
084                    if (classNameId != null) {
085                            setClassNameId(classNameId);
086                    }
087    
088                    Long classPK = (Long)attributes.get("classPK");
089    
090                    if (classPK != null) {
091                            setClassPK(classPK);
092                    }
093    
094                    Long parentGroupId = (Long)attributes.get("parentGroupId");
095    
096                    if (parentGroupId != null) {
097                            setParentGroupId(parentGroupId);
098                    }
099    
100                    Long liveGroupId = (Long)attributes.get("liveGroupId");
101    
102                    if (liveGroupId != null) {
103                            setLiveGroupId(liveGroupId);
104                    }
105    
106                    String name = (String)attributes.get("name");
107    
108                    if (name != null) {
109                            setName(name);
110                    }
111    
112                    String description = (String)attributes.get("description");
113    
114                    if (description != null) {
115                            setDescription(description);
116                    }
117    
118                    Integer type = (Integer)attributes.get("type");
119    
120                    if (type != null) {
121                            setType(type);
122                    }
123    
124                    String typeSettings = (String)attributes.get("typeSettings");
125    
126                    if (typeSettings != null) {
127                            setTypeSettings(typeSettings);
128                    }
129    
130                    String friendlyURL = (String)attributes.get("friendlyURL");
131    
132                    if (friendlyURL != null) {
133                            setFriendlyURL(friendlyURL);
134                    }
135    
136                    Boolean site = (Boolean)attributes.get("site");
137    
138                    if (site != null) {
139                            setSite(site);
140                    }
141    
142                    Boolean active = (Boolean)attributes.get("active");
143    
144                    if (active != null) {
145                            setActive(active);
146                    }
147            }
148    
149            /**
150            * Returns the primary key of this group.
151            *
152            * @return the primary key of this group
153            */
154            public long getPrimaryKey() {
155                    return _group.getPrimaryKey();
156            }
157    
158            /**
159            * Sets the primary key of this group.
160            *
161            * @param primaryKey the primary key of this group
162            */
163            public void setPrimaryKey(long primaryKey) {
164                    _group.setPrimaryKey(primaryKey);
165            }
166    
167            /**
168            * Returns the group ID of this group.
169            *
170            * @return the group ID of this group
171            */
172            public long getGroupId() {
173                    return _group.getGroupId();
174            }
175    
176            /**
177            * Sets the group ID of this group.
178            *
179            * @param groupId the group ID of this group
180            */
181            public void setGroupId(long groupId) {
182                    _group.setGroupId(groupId);
183            }
184    
185            /**
186            * Returns the company ID of this group.
187            *
188            * @return the company ID of this group
189            */
190            public long getCompanyId() {
191                    return _group.getCompanyId();
192            }
193    
194            /**
195            * Sets the company ID of this group.
196            *
197            * @param companyId the company ID of this group
198            */
199            public void setCompanyId(long companyId) {
200                    _group.setCompanyId(companyId);
201            }
202    
203            /**
204            * Returns the creator user ID of this group.
205            *
206            * @return the creator user ID of this group
207            */
208            public long getCreatorUserId() {
209                    return _group.getCreatorUserId();
210            }
211    
212            /**
213            * Sets the creator user ID of this group.
214            *
215            * @param creatorUserId the creator user ID of this group
216            */
217            public void setCreatorUserId(long creatorUserId) {
218                    _group.setCreatorUserId(creatorUserId);
219            }
220    
221            /**
222            * Returns the creator user uuid of this group.
223            *
224            * @return the creator user uuid of this group
225            * @throws SystemException if a system exception occurred
226            */
227            public java.lang.String getCreatorUserUuid()
228                    throws com.liferay.portal.kernel.exception.SystemException {
229                    return _group.getCreatorUserUuid();
230            }
231    
232            /**
233            * Sets the creator user uuid of this group.
234            *
235            * @param creatorUserUuid the creator user uuid of this group
236            */
237            public void setCreatorUserUuid(java.lang.String creatorUserUuid) {
238                    _group.setCreatorUserUuid(creatorUserUuid);
239            }
240    
241            /**
242            * Returns the fully qualified class name of this group.
243            *
244            * @return the fully qualified class name of this group
245            */
246            public java.lang.String getClassName() {
247                    return _group.getClassName();
248            }
249    
250            public void setClassName(java.lang.String className) {
251                    _group.setClassName(className);
252            }
253    
254            /**
255            * Returns the class name ID of this group.
256            *
257            * @return the class name ID of this group
258            */
259            public long getClassNameId() {
260                    return _group.getClassNameId();
261            }
262    
263            /**
264            * Sets the class name ID of this group.
265            *
266            * @param classNameId the class name ID of this group
267            */
268            public void setClassNameId(long classNameId) {
269                    _group.setClassNameId(classNameId);
270            }
271    
272            /**
273            * Returns the class p k of this group.
274            *
275            * @return the class p k of this group
276            */
277            public long getClassPK() {
278                    return _group.getClassPK();
279            }
280    
281            /**
282            * Sets the class p k of this group.
283            *
284            * @param classPK the class p k of this group
285            */
286            public void setClassPK(long classPK) {
287                    _group.setClassPK(classPK);
288            }
289    
290            /**
291            * Returns the parent group ID of this group.
292            *
293            * @return the parent group ID of this group
294            */
295            public long getParentGroupId() {
296                    return _group.getParentGroupId();
297            }
298    
299            /**
300            * Sets the parent group ID of this group.
301            *
302            * @param parentGroupId the parent group ID of this group
303            */
304            public void setParentGroupId(long parentGroupId) {
305                    _group.setParentGroupId(parentGroupId);
306            }
307    
308            /**
309            * Returns the live group ID of this group.
310            *
311            * @return the live group ID of this group
312            */
313            public long getLiveGroupId() {
314                    return _group.getLiveGroupId();
315            }
316    
317            /**
318            * Sets the live group ID of this group.
319            *
320            * @param liveGroupId the live group ID of this group
321            */
322            public void setLiveGroupId(long liveGroupId) {
323                    _group.setLiveGroupId(liveGroupId);
324            }
325    
326            /**
327            * Returns the name of this group.
328            *
329            * @return the name of this group
330            */
331            public java.lang.String getName() {
332                    return _group.getName();
333            }
334    
335            /**
336            * Sets the name of this group.
337            *
338            * @param name the name of this group
339            */
340            public void setName(java.lang.String name) {
341                    _group.setName(name);
342            }
343    
344            /**
345            * Returns the description of this group.
346            *
347            * @return the description of this group
348            */
349            public java.lang.String getDescription() {
350                    return _group.getDescription();
351            }
352    
353            /**
354            * Sets the description of this group.
355            *
356            * @param description the description of this group
357            */
358            public void setDescription(java.lang.String description) {
359                    _group.setDescription(description);
360            }
361    
362            /**
363            * Returns the type of this group.
364            *
365            * @return the type of this group
366            */
367            public int getType() {
368                    return _group.getType();
369            }
370    
371            /**
372            * Sets the type of this group.
373            *
374            * @param type the type of this group
375            */
376            public void setType(int type) {
377                    _group.setType(type);
378            }
379    
380            /**
381            * Returns the type settings of this group.
382            *
383            * @return the type settings of this group
384            */
385            public java.lang.String getTypeSettings() {
386                    return _group.getTypeSettings();
387            }
388    
389            /**
390            * Sets the type settings of this group.
391            *
392            * @param typeSettings the type settings of this group
393            */
394            public void setTypeSettings(java.lang.String typeSettings) {
395                    _group.setTypeSettings(typeSettings);
396            }
397    
398            /**
399            * Returns the friendly u r l of this group.
400            *
401            * @return the friendly u r l of this group
402            */
403            public java.lang.String getFriendlyURL() {
404                    return _group.getFriendlyURL();
405            }
406    
407            /**
408            * Sets the friendly u r l of this group.
409            *
410            * @param friendlyURL the friendly u r l of this group
411            */
412            public void setFriendlyURL(java.lang.String friendlyURL) {
413                    _group.setFriendlyURL(friendlyURL);
414            }
415    
416            /**
417            * Returns the site of this group.
418            *
419            * @return the site of this group
420            */
421            public boolean getSite() {
422                    return _group.getSite();
423            }
424    
425            /**
426            * Returns <code>true</code> if this group is site.
427            *
428            * @return <code>true</code> if this group is site; <code>false</code> otherwise
429            */
430            public boolean isSite() {
431                    return _group.isSite();
432            }
433    
434            /**
435            * Sets whether this group is site.
436            *
437            * @param site the site of this group
438            */
439            public void setSite(boolean site) {
440                    _group.setSite(site);
441            }
442    
443            /**
444            * Returns the active of this group.
445            *
446            * @return the active of this group
447            */
448            public boolean getActive() {
449                    return _group.getActive();
450            }
451    
452            /**
453            * Returns <code>true</code> if this group is active.
454            *
455            * @return <code>true</code> if this group is active; <code>false</code> otherwise
456            */
457            public boolean isActive() {
458                    return _group.isActive();
459            }
460    
461            /**
462            * Sets whether this group is active.
463            *
464            * @param active the active of this group
465            */
466            public void setActive(boolean active) {
467                    _group.setActive(active);
468            }
469    
470            public boolean isNew() {
471                    return _group.isNew();
472            }
473    
474            public void setNew(boolean n) {
475                    _group.setNew(n);
476            }
477    
478            public boolean isCachedModel() {
479                    return _group.isCachedModel();
480            }
481    
482            public void setCachedModel(boolean cachedModel) {
483                    _group.setCachedModel(cachedModel);
484            }
485    
486            public boolean isEscapedModel() {
487                    return _group.isEscapedModel();
488            }
489    
490            public java.io.Serializable getPrimaryKeyObj() {
491                    return _group.getPrimaryKeyObj();
492            }
493    
494            public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
495                    _group.setPrimaryKeyObj(primaryKeyObj);
496            }
497    
498            public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
499                    return _group.getExpandoBridge();
500            }
501    
502            public void setExpandoBridgeAttributes(
503                    com.liferay.portal.service.ServiceContext serviceContext) {
504                    _group.setExpandoBridgeAttributes(serviceContext);
505            }
506    
507            @Override
508            public java.lang.Object clone() {
509                    return new GroupWrapper((Group)_group.clone());
510            }
511    
512            public int compareTo(com.liferay.portal.model.Group group) {
513                    return _group.compareTo(group);
514            }
515    
516            @Override
517            public int hashCode() {
518                    return _group.hashCode();
519            }
520    
521            public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Group> toCacheModel() {
522                    return _group.toCacheModel();
523            }
524    
525            public com.liferay.portal.model.Group toEscapedModel() {
526                    return new GroupWrapper(_group.toEscapedModel());
527            }
528    
529            @Override
530            public java.lang.String toString() {
531                    return _group.toString();
532            }
533    
534            public java.lang.String toXmlString() {
535                    return _group.toXmlString();
536            }
537    
538            public void persist()
539                    throws com.liferay.portal.kernel.exception.SystemException {
540                    _group.persist();
541            }
542    
543            public java.util.List<com.liferay.portal.model.Group> getAncestors()
544                    throws com.liferay.portal.kernel.exception.PortalException,
545                            com.liferay.portal.kernel.exception.SystemException {
546                    return _group.getAncestors();
547            }
548    
549            public java.util.List<com.liferay.portal.model.Group> getChildren(
550                    boolean site)
551                    throws com.liferay.portal.kernel.exception.SystemException {
552                    return _group.getChildren(site);
553            }
554    
555            public java.util.List<com.liferay.portal.model.Group> getChildrenWithLayouts(
556                    boolean site, int start, int end)
557                    throws com.liferay.portal.kernel.exception.SystemException {
558                    return _group.getChildrenWithLayouts(site, start, end);
559            }
560    
561            public int getChildrenWithLayoutsCount(boolean site)
562                    throws com.liferay.portal.kernel.exception.SystemException {
563                    return _group.getChildrenWithLayoutsCount(site);
564            }
565    
566            public long getDefaultPrivatePlid() {
567                    return _group.getDefaultPrivatePlid();
568            }
569    
570            public long getDefaultPublicPlid() {
571                    return _group.getDefaultPublicPlid();
572            }
573    
574            public java.lang.String getDescriptiveName()
575                    throws com.liferay.portal.kernel.exception.PortalException,
576                            com.liferay.portal.kernel.exception.SystemException {
577                    return _group.getDescriptiveName();
578            }
579    
580            public java.lang.String getDescriptiveName(java.util.Locale locale)
581                    throws com.liferay.portal.kernel.exception.PortalException,
582                            com.liferay.portal.kernel.exception.SystemException {
583                    return _group.getDescriptiveName(locale);
584            }
585    
586            public com.liferay.portal.model.Group getLiveGroup() {
587                    return _group.getLiveGroup();
588            }
589    
590            public long getOrganizationId() {
591                    return _group.getOrganizationId();
592            }
593    
594            public com.liferay.portal.model.Group getParentGroup()
595                    throws com.liferay.portal.kernel.exception.PortalException,
596                            com.liferay.portal.kernel.exception.SystemException {
597                    return _group.getParentGroup();
598            }
599    
600            public java.lang.String getPathFriendlyURL(boolean privateLayout,
601                    com.liferay.portal.theme.ThemeDisplay themeDisplay) {
602                    return _group.getPathFriendlyURL(privateLayout, themeDisplay);
603            }
604    
605            public com.liferay.portal.model.LayoutSet getPrivateLayoutSet() {
606                    return _group.getPrivateLayoutSet();
607            }
608    
609            public int getPrivateLayoutsPageCount() {
610                    return _group.getPrivateLayoutsPageCount();
611            }
612    
613            public com.liferay.portal.model.LayoutSet getPublicLayoutSet() {
614                    return _group.getPublicLayoutSet();
615            }
616    
617            public int getPublicLayoutsPageCount() {
618                    return _group.getPublicLayoutsPageCount();
619            }
620    
621            public com.liferay.portal.model.Group getStagingGroup() {
622                    return _group.getStagingGroup();
623            }
624    
625            public java.lang.String getTypeLabel() {
626                    return _group.getTypeLabel();
627            }
628    
629            public com.liferay.portal.kernel.util.UnicodeProperties getTypeSettingsProperties() {
630                    return _group.getTypeSettingsProperties();
631            }
632    
633            public java.lang.String getTypeSettingsProperty(java.lang.String key) {
634                    return _group.getTypeSettingsProperty(key);
635            }
636    
637            public boolean hasPrivateLayouts() {
638                    return _group.hasPrivateLayouts();
639            }
640    
641            public boolean hasPublicLayouts() {
642                    return _group.hasPublicLayouts();
643            }
644    
645            public boolean hasStagingGroup() {
646                    return _group.hasStagingGroup();
647            }
648    
649            /**
650            * @deprecated As of 6.1, renamed to {@link #isRegularSite}
651            */
652            public boolean isCommunity() {
653                    return _group.isCommunity();
654            }
655    
656            public boolean isCompany() {
657                    return _group.isCompany();
658            }
659    
660            public boolean isControlPanel() {
661                    return _group.isControlPanel();
662            }
663    
664            public boolean isGuest() {
665                    return _group.isGuest();
666            }
667    
668            public boolean isLayout() {
669                    return _group.isLayout();
670            }
671    
672            public boolean isLayoutPrototype() {
673                    return _group.isLayoutPrototype();
674            }
675    
676            public boolean isLayoutSetPrototype() {
677                    return _group.isLayoutSetPrototype();
678            }
679    
680            public boolean isOrganization() {
681                    return _group.isOrganization();
682            }
683    
684            public boolean isRegularSite() {
685                    return _group.isRegularSite();
686            }
687    
688            public boolean isRoot() {
689                    return _group.isRoot();
690            }
691    
692            public boolean isShowSite(
693                    com.liferay.portal.security.permission.PermissionChecker permissionChecker,
694                    boolean privateSite)
695                    throws com.liferay.portal.kernel.exception.PortalException,
696                            com.liferay.portal.kernel.exception.SystemException {
697                    return _group.isShowSite(permissionChecker, privateSite);
698            }
699    
700            public boolean isStaged() {
701                    return _group.isStaged();
702            }
703    
704            public boolean isStagedPortlet(java.lang.String portletId) {
705                    return _group.isStagedPortlet(portletId);
706            }
707    
708            public boolean isStagedRemotely() {
709                    return _group.isStagedRemotely();
710            }
711    
712            public boolean isStagingGroup() {
713                    return _group.isStagingGroup();
714            }
715    
716            public boolean isUser() {
717                    return _group.isUser();
718            }
719    
720            public boolean isUserGroup() {
721                    return _group.isUserGroup();
722            }
723    
724            public boolean isUserPersonalSite() {
725                    return _group.isUserPersonalSite();
726            }
727    
728            public void setTypeSettingsProperties(
729                    com.liferay.portal.kernel.util.UnicodeProperties typeSettingsProperties) {
730                    _group.setTypeSettingsProperties(typeSettingsProperties);
731            }
732    
733            /**
734             * @deprecated Renamed to {@link #getWrappedModel}
735             */
736            public Group getWrappedGroup() {
737                    return _group;
738            }
739    
740            public Group getWrappedModel() {
741                    return _group;
742            }
743    
744            public void resetOriginalValues() {
745                    _group.resetOriginalValues();
746            }
747    
748            private Group _group;
749    }