package com.koobietech.eas.common.constant;

/**
 * @author lc
 */

public enum UniversityCode {
    //学校编码
    c10212(10212, "黑龙江大学"),
    c10213(10213, "哈尔滨工业大学"),
    c10214(10214, "哈尔滨理工大学"),
    c10215(10215, "哈尔滨工程大学"),
    c10218(10218, "黑龙江科技大学"),
    c10222(10222, "东北石油大学 "),
    c10230(10230, "佳木斯大学"),
    c10233(10233, "黑龙江八一农垦大学"),
    c10234(10234, "东北农业大学"),
    c10235(10235, "东北林业大学"),
    c10236(10236, "哈尔滨医科大学"),
    c10240(10240, "黑龙江中医药大学"),
    c10241(10241, "牡丹江医学院"),
    c10243(10243, "齐齐哈尔医学院"),
    c10244(10244, "牡丹江师范学院"),
    c10245(10245, "哈尔滨师范大学"),
    c10246(10246, "齐齐哈尔大学"),
    c10247(10247, "黑龙江工程学院"),
    c10248(10248, "哈尔滨商业大学"),
    c10255(10255, "哈尔滨金融学院"),
    c10278(10278, "哈尔滨体育学院"),
    c10859(10859, "哈尔滨音乐学院"),
    c10865(10865, "黑龙江东方学院"),
    c13722(13722, "黑龙江外国语学院"),
    c13731(13731, "哈尔滨信息工程学院");

    private int code;
    private String name;

    UniversityCode(int code, String name) {
        this.code = code;
        this.name = name;
    }

    public int getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

    public static String getName(int code) {
        for (UniversityCode universityCode : UniversityCode.values()) {
            if (universityCode.getCode() == code) {
                return universityCode.getName();
            }
        }
        return null;
    }

    public static int getCode(String name) {
        for (UniversityCode universityCode : UniversityCode.values()) {
            if (universityCode.getName().equals(name)) {
                return universityCode.getCode();
            }
        }
        return -1;
    }
}


