001    /**
002     * Copyright (c) 2000-2013 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.Date;
018    import java.util.HashMap;
019    import java.util.Map;
020    
021    /**
022     * <p>
023     * This class is a wrapper for {@link Website}.
024     * </p>
025     *
026     * @author    Brian Wing Shun Chan
027     * @see       Website
028     * @generated
029     */
030    public class WebsiteWrapper implements Website, ModelWrapper<Website> {
031            public WebsiteWrapper(Website website) {
032                    _website = website;
033            }
034    
035            public Class<?> getModelClass() {
036                    return Website.class;
037            }
038    
039            public String getModelClassName() {
040                    return Website.class.getName();
041            }
042    
043            public Map<String, Object> getModelAttributes() {
044                    Map<String, Object> attributes = new HashMap<String, Object>();
045    
046                    attributes.put("websiteId", getWebsiteId());
047                    attributes.put("companyId", getCompanyId());
048                    attributes.put("userId", getUserId());
049                    attributes.put("userName", getUserName());
050                    attributes.put("createDate", getCreateDate());
051                    attributes.put("modifiedDate", getModifiedDate());
052                    attributes.put("classNameId", getClassNameId());
053                    attributes.put("classPK", getClassPK());
054                    attributes.put("url", getUrl());
055                    attributes.put("typeId", getTypeId());
056                    attributes.put("primary", getPrimary());
057    
058                    return attributes;
059            }
060    
061            public void setModelAttributes(Map<String, Object> attributes) {
062                    Long websiteId = (Long)attributes.get("websiteId");
063    
064                    if (websiteId != null) {
065                            setWebsiteId(websiteId);
066                    }
067    
068                    Long companyId = (Long)attributes.get("companyId");
069    
070                    if (companyId != null) {
071                            setCompanyId(companyId);
072                    }
073    
074                    Long userId = (Long)attributes.get("userId");
075    
076                    if (userId != null) {
077                            setUserId(userId);
078                    }
079    
080                    String userName = (String)attributes.get("userName");
081    
082                    if (userName != null) {
083                            setUserName(userName);
084                    }
085    
086                    Date createDate = (Date)attributes.get("createDate");
087    
088                    if (createDate != null) {
089                            setCreateDate(createDate);
090                    }
091    
092                    Date modifiedDate = (Date)attributes.get("modifiedDate");
093    
094                    if (modifiedDate != null) {
095                            setModifiedDate(modifiedDate);
096                    }
097    
098                    Long classNameId = (Long)attributes.get("classNameId");
099    
100                    if (classNameId != null) {
101                            setClassNameId(classNameId);
102                    }
103    
104                    Long classPK = (Long)attributes.get("classPK");
105    
106                    if (classPK != null) {
107                            setClassPK(classPK);
108                    }
109    
110                    String url = (String)attributes.get("url");
111    
112                    if (url != null) {
113                            setUrl(url);
114                    }
115    
116                    Integer typeId = (Integer)attributes.get("typeId");
117    
118                    if (typeId != null) {
119                            setTypeId(typeId);
120                    }
121    
122                    Boolean primary = (Boolean)attributes.get("primary");
123    
124                    if (primary != null) {
125                            setPrimary(primary);
126                    }
127            }
128    
129            /**
130            * Returns the primary key of this website.
131            *
132            * @return the primary key of this website
133            */
134            public long getPrimaryKey() {
135                    return _website.getPrimaryKey();
136            }
137    
138            /**
139            * Sets the primary key of this website.
140            *
141            * @param primaryKey the primary key of this website
142            */
143            public void setPrimaryKey(long primaryKey) {
144                    _website.setPrimaryKey(primaryKey);
145            }
146    
147            /**
148            * Returns the website ID of this website.
149            *
150            * @return the website ID of this website
151            */
152            public long getWebsiteId() {
153                    return _website.getWebsiteId();
154            }
155    
156            /**
157            * Sets the website ID of this website.
158            *
159            * @param websiteId the website ID of this website
160            */
161            public void setWebsiteId(long websiteId) {
162                    _website.setWebsiteId(websiteId);
163            }
164    
165            /**
166            * Returns the company ID of this website.
167            *
168            * @return the company ID of this website
169            */
170            public long getCompanyId() {
171                    return _website.getCompanyId();
172            }
173    
174            /**
175            * Sets the company ID of this website.
176            *
177            * @param companyId the company ID of this website
178            */
179            public void setCompanyId(long companyId) {
180                    _website.setCompanyId(companyId);
181            }
182    
183            /**
184            * Returns the user ID of this website.
185            *
186            * @return the user ID of this website
187            */
188            public long getUserId() {
189                    return _website.getUserId();
190            }
191    
192            /**
193            * Sets the user ID of this website.
194            *
195            * @param userId the user ID of this website
196            */
197            public void setUserId(long userId) {
198                    _website.setUserId(userId);
199            }
200    
201            /**
202            * Returns the user uuid of this website.
203            *
204            * @return the user uuid of this website
205            * @throws SystemException if a system exception occurred
206            */
207            public java.lang.String getUserUuid()
208                    throws com.liferay.portal.kernel.exception.SystemException {
209                    return _website.getUserUuid();
210            }
211    
212            /**
213            * Sets the user uuid of this website.
214            *
215            * @param userUuid the user uuid of this website
216            */
217            public void setUserUuid(java.lang.String userUuid) {
218                    _website.setUserUuid(userUuid);
219            }
220    
221            /**
222            * Returns the user name of this website.
223            *
224            * @return the user name of this website
225            */
226            public java.lang.String getUserName() {
227                    return _website.getUserName();
228            }
229    
230            /**
231            * Sets the user name of this website.
232            *
233            * @param userName the user name of this website
234            */
235            public void setUserName(java.lang.String userName) {
236                    _website.setUserName(userName);
237            }
238    
239            /**
240            * Returns the create date of this website.
241            *
242            * @return the create date of this website
243            */
244            public java.util.Date getCreateDate() {
245                    return _website.getCreateDate();
246            }
247    
248            /**
249            * Sets the create date of this website.
250            *
251            * @param createDate the create date of this website
252            */
253            public void setCreateDate(java.util.Date createDate) {
254                    _website.setCreateDate(createDate);
255            }
256    
257            /**
258            * Returns the modified date of this website.
259            *
260            * @return the modified date of this website
261            */
262            public java.util.Date getModifiedDate() {
263                    return _website.getModifiedDate();
264            }
265    
266            /**
267            * Sets the modified date of this website.
268            *
269            * @param modifiedDate the modified date of this website
270            */
271            public void setModifiedDate(java.util.Date modifiedDate) {
272                    _website.setModifiedDate(modifiedDate);
273            }
274    
275            /**
276            * Returns the fully qualified class name of this website.
277            *
278            * @return the fully qualified class name of this website
279            */
280            public java.lang.String getClassName() {
281                    return _website.getClassName();
282            }
283    
284            public void setClassName(java.lang.String className) {
285                    _website.setClassName(className);
286            }
287    
288            /**
289            * Returns the class name ID of this website.
290            *
291            * @return the class name ID of this website
292            */
293            public long getClassNameId() {
294                    return _website.getClassNameId();
295            }
296    
297            /**
298            * Sets the class name ID of this website.
299            *
300            * @param classNameId the class name ID of this website
301            */
302            public void setClassNameId(long classNameId) {
303                    _website.setClassNameId(classNameId);
304            }
305    
306            /**
307            * Returns the class p k of this website.
308            *
309            * @return the class p k of this website
310            */
311            public long getClassPK() {
312                    return _website.getClassPK();
313            }
314    
315            /**
316            * Sets the class p k of this website.
317            *
318            * @param classPK the class p k of this website
319            */
320            public void setClassPK(long classPK) {
321                    _website.setClassPK(classPK);
322            }
323    
324            /**
325            * Returns the url of this website.
326            *
327            * @return the url of this website
328            */
329            public java.lang.String getUrl() {
330                    return _website.getUrl();
331            }
332    
333            /**
334            * Sets the url of this website.
335            *
336            * @param url the url of this website
337            */
338            public void setUrl(java.lang.String url) {
339                    _website.setUrl(url);
340            }
341    
342            /**
343            * Returns the type ID of this website.
344            *
345            * @return the type ID of this website
346            */
347            public int getTypeId() {
348                    return _website.getTypeId();
349            }
350    
351            /**
352            * Sets the type ID of this website.
353            *
354            * @param typeId the type ID of this website
355            */
356            public void setTypeId(int typeId) {
357                    _website.setTypeId(typeId);
358            }
359    
360            /**
361            * Returns the primary of this website.
362            *
363            * @return the primary of this website
364            */
365            public boolean getPrimary() {
366                    return _website.getPrimary();
367            }
368    
369            /**
370            * Returns <code>true</code> if this website is primary.
371            *
372            * @return <code>true</code> if this website is primary; <code>false</code> otherwise
373            */
374            public boolean isPrimary() {
375                    return _website.isPrimary();
376            }
377    
378            /**
379            * Sets whether this website is primary.
380            *
381            * @param primary the primary of this website
382            */
383            public void setPrimary(boolean primary) {
384                    _website.setPrimary(primary);
385            }
386    
387            public boolean isNew() {
388                    return _website.isNew();
389            }
390    
391            public void setNew(boolean n) {
392                    _website.setNew(n);
393            }
394    
395            public boolean isCachedModel() {
396                    return _website.isCachedModel();
397            }
398    
399            public void setCachedModel(boolean cachedModel) {
400                    _website.setCachedModel(cachedModel);
401            }
402    
403            public boolean isEscapedModel() {
404                    return _website.isEscapedModel();
405            }
406    
407            public java.io.Serializable getPrimaryKeyObj() {
408                    return _website.getPrimaryKeyObj();
409            }
410    
411            public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
412                    _website.setPrimaryKeyObj(primaryKeyObj);
413            }
414    
415            public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
416                    return _website.getExpandoBridge();
417            }
418    
419            public void setExpandoBridgeAttributes(
420                    com.liferay.portal.model.BaseModel<?> baseModel) {
421                    _website.setExpandoBridgeAttributes(baseModel);
422            }
423    
424            public void setExpandoBridgeAttributes(
425                    com.liferay.portlet.expando.model.ExpandoBridge expandoBridge) {
426                    _website.setExpandoBridgeAttributes(expandoBridge);
427            }
428    
429            public void setExpandoBridgeAttributes(
430                    com.liferay.portal.service.ServiceContext serviceContext) {
431                    _website.setExpandoBridgeAttributes(serviceContext);
432            }
433    
434            @Override
435            public java.lang.Object clone() {
436                    return new WebsiteWrapper((Website)_website.clone());
437            }
438    
439            public int compareTo(com.liferay.portal.model.Website website) {
440                    return _website.compareTo(website);
441            }
442    
443            @Override
444            public int hashCode() {
445                    return _website.hashCode();
446            }
447    
448            public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Website> toCacheModel() {
449                    return _website.toCacheModel();
450            }
451    
452            public com.liferay.portal.model.Website toEscapedModel() {
453                    return new WebsiteWrapper(_website.toEscapedModel());
454            }
455    
456            public com.liferay.portal.model.Website toUnescapedModel() {
457                    return new WebsiteWrapper(_website.toUnescapedModel());
458            }
459    
460            @Override
461            public java.lang.String toString() {
462                    return _website.toString();
463            }
464    
465            public java.lang.String toXmlString() {
466                    return _website.toXmlString();
467            }
468    
469            public void persist()
470                    throws com.liferay.portal.kernel.exception.SystemException {
471                    _website.persist();
472            }
473    
474            public com.liferay.portal.model.ListType getType()
475                    throws com.liferay.portal.kernel.exception.PortalException,
476                            com.liferay.portal.kernel.exception.SystemException {
477                    return _website.getType();
478            }
479    
480            /**
481             * @deprecated As of 6.1.0, replaced by {@link #getWrappedModel}
482             */
483            public Website getWrappedWebsite() {
484                    return _website;
485            }
486    
487            public Website getWrappedModel() {
488                    return _website;
489            }
490    
491            public void resetOriginalValues() {
492                    _website.resetOriginalValues();
493            }
494    
495            private Website _website;
496    }