|
|
/***********************************************************
|
|
|
* @Description : 考试的前端展示类。examCreatorId可从token中获取
|
|
|
* @author : 梁山广(Laing Shan Guang)
|
|
|
* @date : 2019-06-17 08:14
|
|
|
* @email : liangshanguang2@gmail.com
|
|
|
***********************************************************/
|
|
|
package lsgwr.exam.vo;
|
|
|
// 引入Jackson库中的注解,用于JSON序列化和反序列化时自定义属性名
|
|
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
|
|
// 引入Lombok库中的@Data注解,它会自动为你的类的字段生成getter和setter方法,以及toString、equals和hashCode方法
|
|
|
import lombok.Data;
|
|
|
|
|
|
import java.util.List;
|
|
|
// 使用@Data注解来自动生成getter、setter等方法
|
|
|
@Data
|
|
|
public class ExamCreateVo {
|
|
|
// 考试名称,通过@JsonProperty注解指定JSON字段名为"name"
|
|
|
@JsonProperty("name")
|
|
|
private String examName;
|
|
|
// 考试头像或图标,通过@JsonProperty注解指定JSON字段名为"avatar"
|
|
|
@JsonProperty("avatar")
|
|
|
private String examAvatar;
|
|
|
// 考试描述,通过@JsonProperty注解指定JSON字段名为"desc"
|
|
|
@JsonProperty("desc")
|
|
|
private String examDescription;
|
|
|
|
|
|
/**
|
|
|
* 考试时长,单位分钟。通过@JsonProperty注解指定JSON字段名为"elapse"
|
|
|
* 注意:这里的注释说明了字段的用途和单位
|
|
|
*/
|
|
|
@JsonProperty("elapse")
|
|
|
private Integer examTimeLimit;
|
|
|
|
|
|
|
|
|
/**
|
|
|
* 单选题列表。这里虽然使用了List<ExamQuestionSelectVo>类型,但注释仅指明了是单选题
|
|
|
* 注意:ExamQuestionSelectVo可能是一个表示题目信息的VO类,但在此代码段中未给出
|
|
|
*/
|
|
|
private List<ExamQuestionSelectVo> radios;
|
|
|
|
|
|
/**
|
|
|
* 多选题列表。同样使用了List<ExamQuestionSelectVo>类型,但注释指明了是多选题
|
|
|
*/
|
|
|
private List<ExamQuestionSelectVo> checks;
|
|
|
|
|
|
/**
|
|
|
* 判断题列表。使用了List<ExamQuestionSelectVo>类型,注释指明了是判断题
|
|
|
*/
|
|
|
private List<ExamQuestionSelectVo> judges;
|
|
|
|
|
|
/**
|
|
|
* 单选题每题的分数。通过@JsonProperty注解指定JSON字段名为"radioScore"
|
|
|
*/
|
|
|
@JsonProperty("radioScore")
|
|
|
private Integer examScoreRadio;
|
|
|
|
|
|
/**
|
|
|
* 多选题每题的分数。通过@JsonProperty注解指定JSON字段名为"checkScore"
|
|
|
*/
|
|
|
@JsonProperty("checkScore")
|
|
|
private Integer examScoreCheck;
|
|
|
|
|
|
/**
|
|
|
* 判断题每题的分数。通过@JsonProperty注解指定JSON字段名为"judgeScore"
|
|
|
*/
|
|
|
@JsonProperty("judgeScore")
|
|
|
private Integer examScoreJudge;
|
|
|
}
|