|
@@ -1,20 +1,6 @@
|
|
|
package cn.com.qmth.examcloud.support.cache;
|
|
|
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.AppCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.BasePaperCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.CourseCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.ExamOrgPropertyCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.ExamOrgSettingsCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.ExamRecordPropertyCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.ExamSettingsCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.OrgCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.PrivilegeRolesCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.QuestionCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.RootOrgCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.RootOrgPrivilegesCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.SmsAssemblyCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.StudentCacheBean;
|
|
|
-import cn.com.qmth.examcloud.support.cache.bean.SysPropertyCacheBean;
|
|
|
+import cn.com.qmth.examcloud.support.cache.bean.*;
|
|
|
import cn.com.qmth.examcloud.web.cache.ObjectRedisCacheProcessor;
|
|
|
|
|
|
/**
|
|
@@ -104,34 +90,63 @@ public class CacheHelper {
|
|
|
"cn.com.qmth.examcloud.core.basic.service.cache.RootOrgPrrivilegesCache");
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * 获取试卷结构(题库)
|
|
|
- *
|
|
|
- * @param paperId
|
|
|
- * @return
|
|
|
- */
|
|
|
- public static BasePaperCacheBean getBasePaper(String paperId) {
|
|
|
- return ObjectRedisCacheProcessor.get("Q_PAPER:BASE_", new Object[]{paperId},
|
|
|
- BasePaperCacheBean.class, "EC-CORE-QUESTION",
|
|
|
- "cn.com.qmth.examcloud.core.questions.service.cache.BasePaperCache");
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * 获取试题(题库)
|
|
|
- *
|
|
|
- * @param examId
|
|
|
- * @param courseCode
|
|
|
- * @param groupCode
|
|
|
- * @param questionId
|
|
|
- * @return
|
|
|
- */
|
|
|
- public static QuestionCacheBean getQuestion(Long examId, String courseCode, String groupCode,
|
|
|
- String questionId) {
|
|
|
- return ObjectRedisCacheProcessor.get("Q_QUESTION:",
|
|
|
- new Object[]{examId, courseCode, groupCode, questionId}, QuestionCacheBean.class,
|
|
|
- "EC-CORE-QUESTION",
|
|
|
- "cn.com.qmth.examcloud.core.questions.service.cache.QuestionCache");
|
|
|
- }
|
|
|
+ /**
|
|
|
+ * 获取调卷规则信息(题库)
|
|
|
+ *
|
|
|
+ * @param examId
|
|
|
+ * @param courseCode
|
|
|
+ * @param groupCode
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static ExtractConfigCacheBean getExtractConfig(Long examId, String courseCode, String groupCode) {
|
|
|
+ return ObjectRedisCacheProcessor.get("Q_EXTRACT_CONFIG:", new Object[]{examId, courseCode, groupCode},
|
|
|
+ ExtractConfigCacheBean.class, "EC-CORE-QUESTION",
|
|
|
+ "cn.com.qmth.examcloud.core.questions.service.cache.ExtractConfigCache");
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 获取调卷规则调取的试卷结构(题库)
|
|
|
+ *
|
|
|
+ * @param examId
|
|
|
+ * @param courseCode
|
|
|
+ * @param groupCode
|
|
|
+ * @param paperId
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static ExtractConfigPaperCacheBean getExtractConfigPaper(Long examId, String courseCode, String groupCode, String paperId) {
|
|
|
+ return ObjectRedisCacheProcessor.get("Q_PAPER:EXTRACT_CONFIG_PAPER_", new Object[]{examId, courseCode, groupCode, paperId},
|
|
|
+ ExtractConfigPaperCacheBean.class, "EC-CORE-QUESTION",
|
|
|
+ "cn.com.qmth.examcloud.core.questions.service.cache.ExtractConfigPaperCache");
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 获取试卷结构(题库)
|
|
|
+ *
|
|
|
+ * @param paperId
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static BasePaperCacheBean getBasePaper(String paperId) {
|
|
|
+ return ObjectRedisCacheProcessor.get("Q_PAPER:BASE_", new Object[]{paperId},
|
|
|
+ BasePaperCacheBean.class, "EC-CORE-QUESTION",
|
|
|
+ "cn.com.qmth.examcloud.core.questions.service.cache.BasePaperCache");
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 获取试题(题库)
|
|
|
+ *
|
|
|
+ * @param examId
|
|
|
+ * @param courseCode
|
|
|
+ * @param groupCode
|
|
|
+ * @param questionId
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static QuestionCacheBean getQuestion(Long examId, String courseCode, String groupCode,
|
|
|
+ String questionId) {
|
|
|
+ return ObjectRedisCacheProcessor.get("Q_QUESTION:",
|
|
|
+ new Object[]{examId, courseCode, groupCode, questionId}, QuestionCacheBean.class,
|
|
|
+ "EC-CORE-QUESTION",
|
|
|
+ "cn.com.qmth.examcloud.core.questions.service.cache.QuestionCache");
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
|
* 查询课程
|