Word.java 6.3 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280
package com.example.testapp.database;

import org.litepal.annotation.Column;
import org.litepal.crud.LitePalSupport;

public class Word extends LitePalSupport {

    // ID
    @Column(unique = true)
    private int wordId;

    // 单词
    private String word;

    // 英国音标
    private String ukPhone;

    // 美国音标
    private String usPhone;

    // 巧记
    private String remMethod;

    // 图片(网址)
    private String picAddress;

    // 自定义照片
    private byte[] picCustom;

    // 自定义备注
    private String remark;

    // 设置归属
    private String belongBook;

    // 是否收藏
    @Column(defaultValue = "0")
    private int isCollected;

    // 是否是简单词
    @Column(defaultValue = "0")
    private int isEasy;

    // 是否是刚学过
    @Column(defaultValue = "0")
    private int justLearned;

    /*
     * 以下是学习复习专用的
     */

    // 是否需要学习
    @Column(defaultValue = "0")
    private int isNeedLearned;

    // 需要学习的时间(以天为单位)
    private long needLearnDate;

    // 需要复习的时间(以天为单位)
    private long needReviewDate;

    // 是否学习过
    @Column(defaultValue = "0")
    private int isLearned;

    // 总计检验次数
    @Column(defaultValue = "0")
    private int examNum;

    // 总计检验答对次数
    @Column(defaultValue = "0")
    private int examRightNum;

    // 上次已掌握时间(时间戳)
    @Column(defaultValue = "0")
    private long lastMasterTime;

    // 上次复习的时间(时间戳)
    @Column(defaultValue = "0")
    private long lastReviewTime;

    // 掌握程度(总计10分)
    @Column(defaultValue = "0")
    private int masterDegree;

    // 深度掌握次数
    /*
     * 前提:掌握程度已达到10
     * 当深度次数为0时,记下次复习时间=上次已掌握时间+4天,若及时复习,更新上次已掌握时间
     * 当深度次数为1时,记下次复习时间=上次已掌握时间+3天,若及时复习,更新上次已掌握时间
     * 当深度次数为2时,记下次复习时间=上次已掌握时间+8天,若及时复习,更新上次已掌握时间
     * 当深度次数为3时,记已经完全掌握
     *
     * 检测哪些单词未及时深度复习:
     * 首先单词必须掌握程度=10,其次单词上次掌握的时间与现在的时间进行对比
     * (1)要是深度次数为0,且两者时间之差为大于4天,说明未深度复习
     * (2)要是深度次数为1,且两者时间之差为大于3天,说明未深度复习
     * (3)要是深度次数为2,且两者时间之差为大于8天,说明未深度复习
     * (#)若未及时深度复习,一律将其单词掌握程度-2(10→8)
     *
     * */
    @Column(defaultValue = "0")
    private int deepMasterTimes;

    public int getWordId() {
        return wordId;
    }

    public void setWordId(int wordId) {
        this.wordId = wordId;
    }

    public String getWord() {
        return word;
    }

    public void setWord(String word) {
        this.word = word;
    }

    public String getUkPhone() {
        return ukPhone;
    }

    public void setUkPhone(String ukPhone) {
        this.ukPhone = ukPhone;
    }

    public String getUsPhone() {
        return usPhone;
    }

    public void setUsPhone(String usPhone) {
        this.usPhone = usPhone;
    }

    public String getRemMethod() {
        return remMethod;
    }

    public void setRemMethod(String remMethod) {
        this.remMethod = remMethod;
    }

    public String getPicAddress() {
        return picAddress;
    }

    public void setPicAddress(String picAddress) {
        this.picAddress = picAddress;
    }

    public byte[] getPicCustom() {
        return picCustom;
    }

    public void setPicCustom(byte[] picCustom) {
        this.picCustom = picCustom;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public String getBelongBook() {
        return belongBook;
    }

    public void setBelongBook(String belongBook) {
        this.belongBook = belongBook;
    }

    public int getIsCollected() {
        return isCollected;
    }

    public void setIsCollected(int isCollected) {
        this.isCollected = isCollected;
    }

    public int getIsEasy() {
        return isEasy;
    }

    public void setIsEasy(int isEasy) {
        this.isEasy = isEasy;
    }

    public int getJustLearned() {
        return justLearned;
    }

    public void setJustLearned(int justLearned) {
        this.justLearned = justLearned;
    }

    public int getIsNeedLearned() {
        return isNeedLearned;
    }

    public void setIsNeedLearned(int isNeedLearned) {
        this.isNeedLearned = isNeedLearned;
    }

    public long getNeedLearnDate() {
        return needLearnDate;
    }

    public void setNeedLearnDate(long needLearnDate) {
        this.needLearnDate = needLearnDate;
    }

    public long getNeedReviewDate() {
        return needReviewDate;
    }

    public void setNeedReviewDate(long needReviewDate) {
        this.needReviewDate = needReviewDate;
    }

    public int getIsLearned() {
        return isLearned;
    }

    public void setIsLearned(int isLearned) {
        this.isLearned = isLearned;
    }

    public int getExamNum() {
        return examNum;
    }

    public void setExamNum(int examNum) {
        this.examNum = examNum;
    }

    public int getExamRightNum() {
        return examRightNum;
    }

    public void setExamRightNum(int examRightNum) {
        this.examRightNum = examRightNum;
    }

    public long getLastMasterTime() {
        return lastMasterTime;
    }

    public void setLastMasterTime(long lastMasterTime) {
        this.lastMasterTime = lastMasterTime;
    }

    public long getLastReviewTime() {
        return lastReviewTime;
    }

    public void setLastReviewTime(long lastReviewTime) {
        this.lastReviewTime = lastReviewTime;
    }

    public int getMasterDegree() {
        return masterDegree;
    }

    public void setMasterDegree(int masterDegree) {
        this.masterDegree = masterDegree;
    }

    public int getDeepMasterTimes() {
        return deepMasterTimes;
    }

    public void setDeepMasterTimes(int deepMasterTimes) {
        this.deepMasterTimes = deepMasterTimes;
    }
}