/**
* Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License as published by the Free
* Software Foundation; either version 2.1 of the License, or (at your option)
* any later version.
*
* This library is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
* details.
*/
package com.ese.ils.beta.model;
import com.liferay.portal.model.ModelWrapper;
import java.util.HashMap;
import java.util.Map;
/**
* <p>
* This class is a wrapper for {@link Question}.
* </p>
*
* @author edik
* @see Question
* @generated
*/
public class QuestionWrapper implements Question, ModelWrapper<Question> {
public QuestionWrapper(Question question) {
_question = question;
}
public Class<?> getModelClass() {
return Question.class;
}
public String getModelClassName() {
return Question.class.getName();
}
public Map<String, Object> getModelAttributes() {
Map<String, Object> attributes = new HashMap<String, Object>();
attributes.put("questionId", getQuestionId());
attributes.put("userId", getUserId());
attributes.put("slideId", getSlideId());
attributes.put("moduleId", getModuleId());
attributes.put("answer", getAnswer());
attributes.put("questionText", getQuestionText());
return attributes;
}
public void setModelAttributes(Map<String, Object> attributes) {
Long questionId = (Long)attributes.get("questionId");
if (questionId != null) {
setQuestionId(questionId);
}
Long userId = (Long)attributes.get("userId");
if (userId != null) {
setUserId(userId);
}
Long slideId = (Long)attributes.get("slideId");
if (slideId != null) {
setSlideId(slideId);
}
Long moduleId = (Long)attributes.get("moduleId");
if (moduleId != null) {
setModuleId(moduleId);
}
String answer = (String)attributes.get("answer");
if (answer != null) {
setAnswer(answer);
}
String questionText = (String)attributes.get("questionText");
if (questionText != null) {
setQuestionText(questionText);
}
}
/**
* Returns the primary key of this question.
*
* @return the primary key of this question
*/
public long getPrimaryKey() {
return _question.getPrimaryKey();
}
/**
* Sets the primary key of this question.
*
* @param primaryKey the primary key of this question
*/
public void setPrimaryKey(long primaryKey) {
_question.setPrimaryKey(primaryKey);
}
/**
* Returns the question ID of this question.
*
* @return the question ID of this question
*/
public long getQuestionId() {
return _question.getQuestionId();
}
/**
* Sets the question ID of this question.
*
* @param questionId the question ID of this question
*/
public void setQuestionId(long questionId) {
_question.setQuestionId(questionId);
}
/**
* Returns the user ID of this question.
*
* @return the user ID of this question
*/
public long getUserId() {
return _question.getUserId();
}
/**
* Sets the user ID of this question.
*
* @param userId the user ID of this question
*/
public void setUserId(long userId) {
_question.setUserId(userId);
}
/**
* Returns the user uuid of this question.
*
* @return the user uuid of this question
* @throws SystemException if a system exception occurred
*/
public java.lang.String getUserUuid()
throws com.liferay.portal.kernel.exception.SystemException {
return _question.getUserUuid();
}
/**
* Sets the user uuid of this question.
*
* @param userUuid the user uuid of this question
*/
public void setUserUuid(java.lang.String userUuid) {
_question.setUserUuid(userUuid);
}
/**
* Returns the slide ID of this question.
*
* @return the slide ID of this question
*/
public long getSlideId() {
return _question.getSlideId();
}
/**
* Sets the slide ID of this question.
*
* @param slideId the slide ID of this question
*/
public void setSlideId(long slideId) {
_question.setSlideId(slideId);
}
/**
* Returns the module ID of this question.
*
* @return the module ID of this question
*/
public long getModuleId() {
return _question.getModuleId();
}
/**
* Sets the module ID of this question.
*
* @param moduleId the module ID of this question
*/
public void setModuleId(long moduleId) {
_question.setModuleId(moduleId);
}
/**
* Returns the answer of this question.
*
* @return the answer of this question
*/
public java.lang.String getAnswer() {
return _question.getAnswer();
}
/**
* Sets the answer of this question.
*
* @param answer the answer of this question
*/
public void setAnswer(java.lang.String answer) {
_question.setAnswer(answer);
}
/**
* Returns the question text of this question.
*
* @return the question text of this question
*/
public java.lang.String getQuestionText() {
return _question.getQuestionText();
}
/**
* Sets the question text of this question.
*
* @param questionText the question text of this question
*/
public void setQuestionText(java.lang.String questionText) {
_question.setQuestionText(questionText);
}
public boolean isNew() {
return _question.isNew();
}
public void setNew(boolean n) {
_question.setNew(n);
}
public boolean isCachedModel() {
return _question.isCachedModel();
}
public void setCachedModel(boolean cachedModel) {
_question.setCachedModel(cachedModel);
}
public boolean isEscapedModel() {
return _question.isEscapedModel();
}
public java.io.Serializable getPrimaryKeyObj() {
return _question.getPrimaryKeyObj();
}
public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
_question.setPrimaryKeyObj(primaryKeyObj);
}
public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
return _question.getExpandoBridge();
}
public void setExpandoBridgeAttributes(
com.liferay.portal.service.ServiceContext serviceContext) {
_question.setExpandoBridgeAttributes(serviceContext);
}
@Override
public java.lang.Object clone() {
return new QuestionWrapper((Question)_question.clone());
}
public int compareTo(Question question) {
return _question.compareTo(question);
}
@Override
public int hashCode() {
return _question.hashCode();
}
public com.liferay.portal.model.CacheModel<Question> toCacheModel() {
return _question.toCacheModel();
}
public Question toEscapedModel() {
return new QuestionWrapper(_question.toEscapedModel());
}
@Override
public java.lang.String toString() {
return _question.toString();
}
public java.lang.String toXmlString() {
return _question.toXmlString();
}
public void persist()
throws com.liferay.portal.kernel.exception.SystemException {
_question.persist();
}
/**
* @deprecated Renamed to {@link #getWrappedModel}
*/
public Question getWrappedQuestion() {
return _question;
}
public Question getWrappedModel() {
return _question;
}
public void resetOriginalValues() {
_question.resetOriginalValues();
}
private Question _question;
}