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