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.portlet.softwarecatalog.model;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.util.Validator;
020    import com.liferay.portal.model.ModelWrapper;
021    
022    import java.util.Date;
023    import java.util.HashMap;
024    import java.util.Map;
025    
026    /**
027     * <p>
028     * This class is a wrapper for {@link SCProductEntry}.
029     * </p>
030     *
031     * @author Brian Wing Shun Chan
032     * @see SCProductEntry
033     * @generated
034     */
035    @ProviderType
036    public class SCProductEntryWrapper implements SCProductEntry,
037            ModelWrapper<SCProductEntry> {
038            public SCProductEntryWrapper(SCProductEntry scProductEntry) {
039                    _scProductEntry = scProductEntry;
040            }
041    
042            @Override
043            public Class<?> getModelClass() {
044                    return SCProductEntry.class;
045            }
046    
047            @Override
048            public String getModelClassName() {
049                    return SCProductEntry.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("productEntryId", getProductEntryId());
057                    attributes.put("groupId", getGroupId());
058                    attributes.put("companyId", getCompanyId());
059                    attributes.put("userId", getUserId());
060                    attributes.put("userName", getUserName());
061                    attributes.put("createDate", getCreateDate());
062                    attributes.put("modifiedDate", getModifiedDate());
063                    attributes.put("name", getName());
064                    attributes.put("type", getType());
065                    attributes.put("tags", getTags());
066                    attributes.put("shortDescription", getShortDescription());
067                    attributes.put("longDescription", getLongDescription());
068                    attributes.put("pageURL", getPageURL());
069                    attributes.put("author", getAuthor());
070                    attributes.put("repoGroupId", getRepoGroupId());
071                    attributes.put("repoArtifactId", getRepoArtifactId());
072    
073                    return attributes;
074            }
075    
076            @Override
077            public void setModelAttributes(Map<String, Object> attributes) {
078                    Long productEntryId = (Long)attributes.get("productEntryId");
079    
080                    if (productEntryId != null) {
081                            setProductEntryId(productEntryId);
082                    }
083    
084                    Long groupId = (Long)attributes.get("groupId");
085    
086                    if (groupId != null) {
087                            setGroupId(groupId);
088                    }
089    
090                    Long companyId = (Long)attributes.get("companyId");
091    
092                    if (companyId != null) {
093                            setCompanyId(companyId);
094                    }
095    
096                    Long userId = (Long)attributes.get("userId");
097    
098                    if (userId != null) {
099                            setUserId(userId);
100                    }
101    
102                    String userName = (String)attributes.get("userName");
103    
104                    if (userName != null) {
105                            setUserName(userName);
106                    }
107    
108                    Date createDate = (Date)attributes.get("createDate");
109    
110                    if (createDate != null) {
111                            setCreateDate(createDate);
112                    }
113    
114                    Date modifiedDate = (Date)attributes.get("modifiedDate");
115    
116                    if (modifiedDate != null) {
117                            setModifiedDate(modifiedDate);
118                    }
119    
120                    String name = (String)attributes.get("name");
121    
122                    if (name != null) {
123                            setName(name);
124                    }
125    
126                    String type = (String)attributes.get("type");
127    
128                    if (type != null) {
129                            setType(type);
130                    }
131    
132                    String tags = (String)attributes.get("tags");
133    
134                    if (tags != null) {
135                            setTags(tags);
136                    }
137    
138                    String shortDescription = (String)attributes.get("shortDescription");
139    
140                    if (shortDescription != null) {
141                            setShortDescription(shortDescription);
142                    }
143    
144                    String longDescription = (String)attributes.get("longDescription");
145    
146                    if (longDescription != null) {
147                            setLongDescription(longDescription);
148                    }
149    
150                    String pageURL = (String)attributes.get("pageURL");
151    
152                    if (pageURL != null) {
153                            setPageURL(pageURL);
154                    }
155    
156                    String author = (String)attributes.get("author");
157    
158                    if (author != null) {
159                            setAuthor(author);
160                    }
161    
162                    String repoGroupId = (String)attributes.get("repoGroupId");
163    
164                    if (repoGroupId != null) {
165                            setRepoGroupId(repoGroupId);
166                    }
167    
168                    String repoArtifactId = (String)attributes.get("repoArtifactId");
169    
170                    if (repoArtifactId != null) {
171                            setRepoArtifactId(repoArtifactId);
172                    }
173            }
174    
175            @Override
176            public java.lang.Object clone() {
177                    return new SCProductEntryWrapper((SCProductEntry)_scProductEntry.clone());
178            }
179    
180            @Override
181            public int compareTo(
182                    com.liferay.portlet.softwarecatalog.model.SCProductEntry scProductEntry) {
183                    return _scProductEntry.compareTo(scProductEntry);
184            }
185    
186            /**
187            * Returns the author of this s c product entry.
188            *
189            * @return the author of this s c product entry
190            */
191            @Override
192            public java.lang.String getAuthor() {
193                    return _scProductEntry.getAuthor();
194            }
195    
196            /**
197            * Returns the company ID of this s c product entry.
198            *
199            * @return the company ID of this s c product entry
200            */
201            @Override
202            public long getCompanyId() {
203                    return _scProductEntry.getCompanyId();
204            }
205    
206            /**
207            * Returns the create date of this s c product entry.
208            *
209            * @return the create date of this s c product entry
210            */
211            @Override
212            public java.util.Date getCreateDate() {
213                    return _scProductEntry.getCreateDate();
214            }
215    
216            @Override
217            public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
218                    return _scProductEntry.getExpandoBridge();
219            }
220    
221            /**
222            * Returns the group ID of this s c product entry.
223            *
224            * @return the group ID of this s c product entry
225            */
226            @Override
227            public long getGroupId() {
228                    return _scProductEntry.getGroupId();
229            }
230    
231            @Override
232            public com.liferay.portlet.softwarecatalog.model.SCProductVersion getLatestVersion() {
233                    return _scProductEntry.getLatestVersion();
234            }
235    
236            @Override
237            public java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> getLicenses() {
238                    return _scProductEntry.getLicenses();
239            }
240    
241            /**
242            * Returns the long description of this s c product entry.
243            *
244            * @return the long description of this s c product entry
245            */
246            @Override
247            public java.lang.String getLongDescription() {
248                    return _scProductEntry.getLongDescription();
249            }
250    
251            /**
252            * Returns the modified date of this s c product entry.
253            *
254            * @return the modified date of this s c product entry
255            */
256            @Override
257            public java.util.Date getModifiedDate() {
258                    return _scProductEntry.getModifiedDate();
259            }
260    
261            /**
262            * Returns the name of this s c product entry.
263            *
264            * @return the name of this s c product entry
265            */
266            @Override
267            public java.lang.String getName() {
268                    return _scProductEntry.getName();
269            }
270    
271            /**
272            * Returns the page u r l of this s c product entry.
273            *
274            * @return the page u r l of this s c product entry
275            */
276            @Override
277            public java.lang.String getPageURL() {
278                    return _scProductEntry.getPageURL();
279            }
280    
281            /**
282            * Returns the primary key of this s c product entry.
283            *
284            * @return the primary key of this s c product entry
285            */
286            @Override
287            public long getPrimaryKey() {
288                    return _scProductEntry.getPrimaryKey();
289            }
290    
291            @Override
292            public java.io.Serializable getPrimaryKeyObj() {
293                    return _scProductEntry.getPrimaryKeyObj();
294            }
295    
296            /**
297            * Returns the product entry ID of this s c product entry.
298            *
299            * @return the product entry ID of this s c product entry
300            */
301            @Override
302            public long getProductEntryId() {
303                    return _scProductEntry.getProductEntryId();
304            }
305    
306            /**
307            * Returns the repo artifact ID of this s c product entry.
308            *
309            * @return the repo artifact ID of this s c product entry
310            */
311            @Override
312            public java.lang.String getRepoArtifactId() {
313                    return _scProductEntry.getRepoArtifactId();
314            }
315    
316            /**
317            * Returns the repo group ID of this s c product entry.
318            *
319            * @return the repo group ID of this s c product entry
320            */
321            @Override
322            public java.lang.String getRepoGroupId() {
323                    return _scProductEntry.getRepoGroupId();
324            }
325    
326            @Override
327            public java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> getScreenshots() {
328                    return _scProductEntry.getScreenshots();
329            }
330    
331            /**
332            * Returns the short description of this s c product entry.
333            *
334            * @return the short description of this s c product entry
335            */
336            @Override
337            public java.lang.String getShortDescription() {
338                    return _scProductEntry.getShortDescription();
339            }
340    
341            /**
342            * Returns the tags of this s c product entry.
343            *
344            * @return the tags of this s c product entry
345            */
346            @Override
347            public java.lang.String getTags() {
348                    return _scProductEntry.getTags();
349            }
350    
351            /**
352            * Returns the type of this s c product entry.
353            *
354            * @return the type of this s c product entry
355            */
356            @Override
357            public java.lang.String getType() {
358                    return _scProductEntry.getType();
359            }
360    
361            /**
362            * Returns the user ID of this s c product entry.
363            *
364            * @return the user ID of this s c product entry
365            */
366            @Override
367            public long getUserId() {
368                    return _scProductEntry.getUserId();
369            }
370    
371            /**
372            * Returns the user name of this s c product entry.
373            *
374            * @return the user name of this s c product entry
375            */
376            @Override
377            public java.lang.String getUserName() {
378                    return _scProductEntry.getUserName();
379            }
380    
381            /**
382            * Returns the user uuid of this s c product entry.
383            *
384            * @return the user uuid of this s c product entry
385            */
386            @Override
387            public java.lang.String getUserUuid() {
388                    return _scProductEntry.getUserUuid();
389            }
390    
391            @Override
392            public int hashCode() {
393                    return _scProductEntry.hashCode();
394            }
395    
396            @Override
397            public boolean isCachedModel() {
398                    return _scProductEntry.isCachedModel();
399            }
400    
401            @Override
402            public boolean isEscapedModel() {
403                    return _scProductEntry.isEscapedModel();
404            }
405    
406            @Override
407            public boolean isNew() {
408                    return _scProductEntry.isNew();
409            }
410    
411            @Override
412            public void persist() {
413                    _scProductEntry.persist();
414            }
415    
416            /**
417            * Sets the author of this s c product entry.
418            *
419            * @param author the author of this s c product entry
420            */
421            @Override
422            public void setAuthor(java.lang.String author) {
423                    _scProductEntry.setAuthor(author);
424            }
425    
426            @Override
427            public void setCachedModel(boolean cachedModel) {
428                    _scProductEntry.setCachedModel(cachedModel);
429            }
430    
431            /**
432            * Sets the company ID of this s c product entry.
433            *
434            * @param companyId the company ID of this s c product entry
435            */
436            @Override
437            public void setCompanyId(long companyId) {
438                    _scProductEntry.setCompanyId(companyId);
439            }
440    
441            /**
442            * Sets the create date of this s c product entry.
443            *
444            * @param createDate the create date of this s c product entry
445            */
446            @Override
447            public void setCreateDate(java.util.Date createDate) {
448                    _scProductEntry.setCreateDate(createDate);
449            }
450    
451            @Override
452            public void setExpandoBridgeAttributes(
453                    com.liferay.portal.model.BaseModel<?> baseModel) {
454                    _scProductEntry.setExpandoBridgeAttributes(baseModel);
455            }
456    
457            @Override
458            public void setExpandoBridgeAttributes(
459                    com.liferay.portlet.expando.model.ExpandoBridge expandoBridge) {
460                    _scProductEntry.setExpandoBridgeAttributes(expandoBridge);
461            }
462    
463            @Override
464            public void setExpandoBridgeAttributes(
465                    com.liferay.portal.service.ServiceContext serviceContext) {
466                    _scProductEntry.setExpandoBridgeAttributes(serviceContext);
467            }
468    
469            /**
470            * Sets the group ID of this s c product entry.
471            *
472            * @param groupId the group ID of this s c product entry
473            */
474            @Override
475            public void setGroupId(long groupId) {
476                    _scProductEntry.setGroupId(groupId);
477            }
478    
479            /**
480            * Sets the long description of this s c product entry.
481            *
482            * @param longDescription the long description of this s c product entry
483            */
484            @Override
485            public void setLongDescription(java.lang.String longDescription) {
486                    _scProductEntry.setLongDescription(longDescription);
487            }
488    
489            /**
490            * Sets the modified date of this s c product entry.
491            *
492            * @param modifiedDate the modified date of this s c product entry
493            */
494            @Override
495            public void setModifiedDate(java.util.Date modifiedDate) {
496                    _scProductEntry.setModifiedDate(modifiedDate);
497            }
498    
499            /**
500            * Sets the name of this s c product entry.
501            *
502            * @param name the name of this s c product entry
503            */
504            @Override
505            public void setName(java.lang.String name) {
506                    _scProductEntry.setName(name);
507            }
508    
509            @Override
510            public void setNew(boolean n) {
511                    _scProductEntry.setNew(n);
512            }
513    
514            /**
515            * Sets the page u r l of this s c product entry.
516            *
517            * @param pageURL the page u r l of this s c product entry
518            */
519            @Override
520            public void setPageURL(java.lang.String pageURL) {
521                    _scProductEntry.setPageURL(pageURL);
522            }
523    
524            /**
525            * Sets the primary key of this s c product entry.
526            *
527            * @param primaryKey the primary key of this s c product entry
528            */
529            @Override
530            public void setPrimaryKey(long primaryKey) {
531                    _scProductEntry.setPrimaryKey(primaryKey);
532            }
533    
534            @Override
535            public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
536                    _scProductEntry.setPrimaryKeyObj(primaryKeyObj);
537            }
538    
539            /**
540            * Sets the product entry ID of this s c product entry.
541            *
542            * @param productEntryId the product entry ID of this s c product entry
543            */
544            @Override
545            public void setProductEntryId(long productEntryId) {
546                    _scProductEntry.setProductEntryId(productEntryId);
547            }
548    
549            /**
550            * Sets the repo artifact ID of this s c product entry.
551            *
552            * @param repoArtifactId the repo artifact ID of this s c product entry
553            */
554            @Override
555            public void setRepoArtifactId(java.lang.String repoArtifactId) {
556                    _scProductEntry.setRepoArtifactId(repoArtifactId);
557            }
558    
559            /**
560            * Sets the repo group ID of this s c product entry.
561            *
562            * @param repoGroupId the repo group ID of this s c product entry
563            */
564            @Override
565            public void setRepoGroupId(java.lang.String repoGroupId) {
566                    _scProductEntry.setRepoGroupId(repoGroupId);
567            }
568    
569            /**
570            * Sets the short description of this s c product entry.
571            *
572            * @param shortDescription the short description of this s c product entry
573            */
574            @Override
575            public void setShortDescription(java.lang.String shortDescription) {
576                    _scProductEntry.setShortDescription(shortDescription);
577            }
578    
579            /**
580            * Sets the tags of this s c product entry.
581            *
582            * @param tags the tags of this s c product entry
583            */
584            @Override
585            public void setTags(java.lang.String tags) {
586                    _scProductEntry.setTags(tags);
587            }
588    
589            /**
590            * Sets the type of this s c product entry.
591            *
592            * @param type the type of this s c product entry
593            */
594            @Override
595            public void setType(java.lang.String type) {
596                    _scProductEntry.setType(type);
597            }
598    
599            /**
600            * Sets the user ID of this s c product entry.
601            *
602            * @param userId the user ID of this s c product entry
603            */
604            @Override
605            public void setUserId(long userId) {
606                    _scProductEntry.setUserId(userId);
607            }
608    
609            /**
610            * Sets the user name of this s c product entry.
611            *
612            * @param userName the user name of this s c product entry
613            */
614            @Override
615            public void setUserName(java.lang.String userName) {
616                    _scProductEntry.setUserName(userName);
617            }
618    
619            /**
620            * Sets the user uuid of this s c product entry.
621            *
622            * @param userUuid the user uuid of this s c product entry
623            */
624            @Override
625            public void setUserUuid(java.lang.String userUuid) {
626                    _scProductEntry.setUserUuid(userUuid);
627            }
628    
629            @Override
630            public com.liferay.portal.model.CacheModel<com.liferay.portlet.softwarecatalog.model.SCProductEntry> toCacheModel() {
631                    return _scProductEntry.toCacheModel();
632            }
633    
634            @Override
635            public com.liferay.portlet.softwarecatalog.model.SCProductEntry toEscapedModel() {
636                    return new SCProductEntryWrapper(_scProductEntry.toEscapedModel());
637            }
638    
639            @Override
640            public java.lang.String toString() {
641                    return _scProductEntry.toString();
642            }
643    
644            @Override
645            public com.liferay.portlet.softwarecatalog.model.SCProductEntry toUnescapedModel() {
646                    return new SCProductEntryWrapper(_scProductEntry.toUnescapedModel());
647            }
648    
649            @Override
650            public java.lang.String toXmlString() {
651                    return _scProductEntry.toXmlString();
652            }
653    
654            @Override
655            public boolean equals(Object obj) {
656                    if (this == obj) {
657                            return true;
658                    }
659    
660                    if (!(obj instanceof SCProductEntryWrapper)) {
661                            return false;
662                    }
663    
664                    SCProductEntryWrapper scProductEntryWrapper = (SCProductEntryWrapper)obj;
665    
666                    if (Validator.equals(_scProductEntry,
667                                            scProductEntryWrapper._scProductEntry)) {
668                            return true;
669                    }
670    
671                    return false;
672            }
673    
674            /**
675             * @deprecated As of 6.1.0, replaced by {@link #getWrappedModel}
676             */
677            @Deprecated
678            public SCProductEntry getWrappedSCProductEntry() {
679                    return _scProductEntry;
680            }
681    
682            @Override
683            public SCProductEntry getWrappedModel() {
684                    return _scProductEntry;
685            }
686    
687            @Override
688            public boolean isEntityCacheEnabled() {
689                    return _scProductEntry.isEntityCacheEnabled();
690            }
691    
692            @Override
693            public boolean isFinderCacheEnabled() {
694                    return _scProductEntry.isFinderCacheEnabled();
695            }
696    
697            @Override
698            public void resetOriginalValues() {
699                    _scProductEntry.resetOriginalValues();
700            }
701    
702            private final SCProductEntry _scProductEntry;
703    }