001    /**
002     * Copyright (c) 2000-2011 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    /**
018     * <p>
019     * This class is a wrapper for {@link PortletPreferences}.
020     * </p>
021     *
022     * @author    Brian Wing Shun Chan
023     * @see       PortletPreferences
024     * @generated
025     */
026    public class PortletPreferencesWrapper implements PortletPreferences {
027            public PortletPreferencesWrapper(PortletPreferences portletPreferences) {
028                    _portletPreferences = portletPreferences;
029            }
030    
031            public Class<?> getModelClass() {
032                    return PortletPreferences.class;
033            }
034    
035            public String getModelClassName() {
036                    return PortletPreferences.class.getName();
037            }
038    
039            /**
040            * Returns the primary key of this portlet preferences.
041            *
042            * @return the primary key of this portlet preferences
043            */
044            public long getPrimaryKey() {
045                    return _portletPreferences.getPrimaryKey();
046            }
047    
048            /**
049            * Sets the primary key of this portlet preferences.
050            *
051            * @param primaryKey the primary key of this portlet preferences
052            */
053            public void setPrimaryKey(long primaryKey) {
054                    _portletPreferences.setPrimaryKey(primaryKey);
055            }
056    
057            /**
058            * Returns the portlet preferences ID of this portlet preferences.
059            *
060            * @return the portlet preferences ID of this portlet preferences
061            */
062            public long getPortletPreferencesId() {
063                    return _portletPreferences.getPortletPreferencesId();
064            }
065    
066            /**
067            * Sets the portlet preferences ID of this portlet preferences.
068            *
069            * @param portletPreferencesId the portlet preferences ID of this portlet preferences
070            */
071            public void setPortletPreferencesId(long portletPreferencesId) {
072                    _portletPreferences.setPortletPreferencesId(portletPreferencesId);
073            }
074    
075            /**
076            * Returns the owner ID of this portlet preferences.
077            *
078            * @return the owner ID of this portlet preferences
079            */
080            public long getOwnerId() {
081                    return _portletPreferences.getOwnerId();
082            }
083    
084            /**
085            * Sets the owner ID of this portlet preferences.
086            *
087            * @param ownerId the owner ID of this portlet preferences
088            */
089            public void setOwnerId(long ownerId) {
090                    _portletPreferences.setOwnerId(ownerId);
091            }
092    
093            /**
094            * Returns the owner type of this portlet preferences.
095            *
096            * @return the owner type of this portlet preferences
097            */
098            public int getOwnerType() {
099                    return _portletPreferences.getOwnerType();
100            }
101    
102            /**
103            * Sets the owner type of this portlet preferences.
104            *
105            * @param ownerType the owner type of this portlet preferences
106            */
107            public void setOwnerType(int ownerType) {
108                    _portletPreferences.setOwnerType(ownerType);
109            }
110    
111            /**
112            * Returns the plid of this portlet preferences.
113            *
114            * @return the plid of this portlet preferences
115            */
116            public long getPlid() {
117                    return _portletPreferences.getPlid();
118            }
119    
120            /**
121            * Sets the plid of this portlet preferences.
122            *
123            * @param plid the plid of this portlet preferences
124            */
125            public void setPlid(long plid) {
126                    _portletPreferences.setPlid(plid);
127            }
128    
129            /**
130            * Returns the portlet ID of this portlet preferences.
131            *
132            * @return the portlet ID of this portlet preferences
133            */
134            public java.lang.String getPortletId() {
135                    return _portletPreferences.getPortletId();
136            }
137    
138            /**
139            * Sets the portlet ID of this portlet preferences.
140            *
141            * @param portletId the portlet ID of this portlet preferences
142            */
143            public void setPortletId(java.lang.String portletId) {
144                    _portletPreferences.setPortletId(portletId);
145            }
146    
147            /**
148            * Returns the preferences of this portlet preferences.
149            *
150            * @return the preferences of this portlet preferences
151            */
152            public java.lang.String getPreferences() {
153                    return _portletPreferences.getPreferences();
154            }
155    
156            /**
157            * Sets the preferences of this portlet preferences.
158            *
159            * @param preferences the preferences of this portlet preferences
160            */
161            public void setPreferences(java.lang.String preferences) {
162                    _portletPreferences.setPreferences(preferences);
163            }
164    
165            public boolean isNew() {
166                    return _portletPreferences.isNew();
167            }
168    
169            public void setNew(boolean n) {
170                    _portletPreferences.setNew(n);
171            }
172    
173            public boolean isCachedModel() {
174                    return _portletPreferences.isCachedModel();
175            }
176    
177            public void setCachedModel(boolean cachedModel) {
178                    _portletPreferences.setCachedModel(cachedModel);
179            }
180    
181            public boolean isEscapedModel() {
182                    return _portletPreferences.isEscapedModel();
183            }
184    
185            public java.io.Serializable getPrimaryKeyObj() {
186                    return _portletPreferences.getPrimaryKeyObj();
187            }
188    
189            public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
190                    _portletPreferences.setPrimaryKeyObj(primaryKeyObj);
191            }
192    
193            public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
194                    return _portletPreferences.getExpandoBridge();
195            }
196    
197            public void setExpandoBridgeAttributes(
198                    com.liferay.portal.service.ServiceContext serviceContext) {
199                    _portletPreferences.setExpandoBridgeAttributes(serviceContext);
200            }
201    
202            @Override
203            public java.lang.Object clone() {
204                    return new PortletPreferencesWrapper((PortletPreferences)_portletPreferences.clone());
205            }
206    
207            public int compareTo(
208                    com.liferay.portal.model.PortletPreferences portletPreferences) {
209                    return _portletPreferences.compareTo(portletPreferences);
210            }
211    
212            @Override
213            public int hashCode() {
214                    return _portletPreferences.hashCode();
215            }
216    
217            public com.liferay.portal.model.CacheModel<com.liferay.portal.model.PortletPreferences> toCacheModel() {
218                    return _portletPreferences.toCacheModel();
219            }
220    
221            public com.liferay.portal.model.PortletPreferences toEscapedModel() {
222                    return new PortletPreferencesWrapper(_portletPreferences.toEscapedModel());
223            }
224    
225            @Override
226            public java.lang.String toString() {
227                    return _portletPreferences.toString();
228            }
229    
230            public java.lang.String toXmlString() {
231                    return _portletPreferences.toXmlString();
232            }
233    
234            public void persist()
235                    throws com.liferay.portal.kernel.exception.SystemException {
236                    _portletPreferences.persist();
237            }
238    
239            public PortletPreferences getWrappedPortletPreferences() {
240                    return _portletPreferences;
241            }
242    
243            public void resetOriginalValues() {
244                    _portletPreferences.resetOriginalValues();
245            }
246    
247            private PortletPreferences _portletPreferences;
248    }