Index: lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/QaAppConstants.java =================================================================== diff -u -reb6742a9f559f4ca57ebf90f1e1d10bb6a6d3ed0 -ra4cd73bee5754b50f4ffbd330d1af3eaaf8c6d6c --- lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/QaAppConstants.java (.../QaAppConstants.java) (revision eb6742a9f559f4ca57ebf90f1e1d10bb6a6d3ed0) +++ lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/QaAppConstants.java (.../QaAppConstants.java) (revision a4cd73bee5754b50f4ffbd330d1af3eaaf8c6d6c) @@ -44,6 +44,8 @@ public static final String LEARNING_STARTER ="learningStarter"; public static final String MONITORING_STARTER ="monitoringStarter"; public static final String LOAD_MONITORING ="loadMonitoring"; + public static final String EDIT_RESPONSE ="editResponse"; + public static final String EDITABLE_RESPONSE_ID ="editableResponseId"; public static final String COPY_TOOL_CONTENT ="copyToolContent"; public static final String ERROR_LIST ="errorList"; public static final String ERROR_LIST_LEARNER ="errorListLearner"; Index: lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/QaMonitoredUserDTO.java =================================================================== diff -u --- lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/QaMonitoredUserDTO.java (revision 0) +++ lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/QaMonitoredUserDTO.java (revision a4cd73bee5754b50f4ffbd330d1af3eaaf8c6d6c) @@ -0,0 +1,193 @@ +/*************************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * ***********************************************************************/ +package org.lamsfoundation.lams.tool.qa; + +import java.util.Map; + +import org.apache.commons.lang.builder.ToStringBuilder; + + +/** + *

DTO that holds users attempt history data for jsp purposes + *

+ * + * @author Ozgur Demirtas + */ +public class QaMonitoredUserDTO implements Comparable +{ + private String queUsrId; + + private String uid; + + private String attemptTime; + + private String timeZone; + + private String userName; + + private String isCorrect; + + private String response; + + private String sessionId; + + private String questionUid; + + private Map usersAttempts; + + /** + * @return Returns the queUsrId. + */ + public String getQueUsrId() { + return queUsrId; + } + /** + * @param queUsrId The queUsrId to set. + */ + public void setQueUsrId(String queUsrId) { + this.queUsrId = queUsrId; + } + + public String toString() { + return new ToStringBuilder(this) + .append("queUsrId and username", getQueUsrId() + " and " + getUserName()) + .toString(); + } + /** + * @return Returns the usersAttempts. + */ + public Map getUsersAttempts() { + return usersAttempts; + } + /** + * @param usersAttempts The usersAttempts to set. + */ + public void setUsersAttempts(Map usersAttempts) { + this.usersAttempts = usersAttempts; + } + + public int compareTo(Object o) + { + QaMonitoredUserDTO qaMonitoredUserDTO = (QaMonitoredUserDTO) o; + + if (qaMonitoredUserDTO == null) + return 1; + else + return (int) (new Long(queUsrId).longValue() - new Long(qaMonitoredUserDTO.queUsrId).longValue()); + } + /** + * @return Returns the attemptTime. + */ + public String getAttemptTime() { + return attemptTime; + } + /** + * @param attemptTime The attemptTime to set. + */ + public void setAttemptTime(String attemptTime) { + this.attemptTime = attemptTime; + } + /** + * @return Returns the isCorrect. + */ + public String getIsCorrect() { + return isCorrect; + } + /** + * @param isCorrect The isCorrect to set. + */ + public void setIsCorrect(String isCorrect) { + this.isCorrect = isCorrect; + } + /** + * @return Returns the response. + */ + public String getResponse() { + return response; + } + /** + * @param response The response to set. + */ + public void setResponse(String response) { + this.response = response; + } + /** + * @return Returns the timeZone. + */ + public String getTimeZone() { + return timeZone; + } + /** + * @param timeZone The timeZone to set. + */ + public void setTimeZone(String timeZone) { + this.timeZone = timeZone; + } + /** + * @return Returns the uid. + */ + public String getUid() { + return uid; + } + /** + * @param uid The uid to set. + */ + public void setUid(String uid) { + this.uid = uid; + } + /** + * @return Returns the userName. + */ + public String getUserName() { + return userName; + } + /** + * @param userName The userName to set. + */ + public void setUserName(String userName) { + this.userName = userName; + } + /** + * @return Returns the sessionId. + */ + public String getSessionId() { + return sessionId; + } + /** + * @param sessionId The sessionId to set. + */ + public void setSessionId(String sessionId) { + this.sessionId = sessionId; + } + /** + * @return Returns the questionUid. + */ + public String getQuestionUid() { + return questionUid; + } + /** + * @param questionUid The questionUid to set. + */ + public void setQuestionUid(String questionUid) { + this.questionUid = questionUid; + } +}