package cn.base.util;

import java.util.HashMap;

public class Constants {
	public static  final String AMPERSAND = "&";
	public static  final String AND = "and";
	public static  final String AT = "@";
	public static  final String ASTERISK = "*";
	public static  final String BACK_SLASH = "\\";
	public static  final String COLON = ":";
	public static  final String COMMA = ",";
	public static  final String DASH = "-";
	public static  final String DOLLAR = "$";
	public static  final String DOT = ".";
	public static  final String DOTDOT = "..";
	public static  final String DOT_CLASS = ".class";
	public static  final String DOT_JAVA = ".java";
	public static  final String EMPTY = "";
	public static  final String EQUALS = "=";
	public static  final String FALSE = "false";
	public static  final String SLASH = "/";
	public static  final String HASH = "#";
	public static  final String HAT = "^";
	public static  final String LEFT_BRACE = "{";
	public static  final String LEFT_BRACKET = "(";
	public static  final String LEFT_CHEV = "<";
	public static  final String NEWLINE = "\n";
	public static  final String N = "n";
	public static  final String NO = "no";
	public static  final String NULL = "null";
	public static  final String OFF = "off";
	public static  final String ON = "on";
	public static  final String PERCENT = "%";
	public static  final String PIPE = "|";
	public static  final String PLUS = "+";
	public static  final String QUESTION_MARK = "?";
	public static  final String EXCLAMATION_MARK = "!";
	public static  final String QUOTE = "\"";
	public static  final String RETURN = "\r";
	public static  final String TAB = "\t";
	public static  final String RIGHT_BRACE = "}";
	public static  final String RIGHT_BRACKET = ")";
	public static  final String RIGHT_CHEV = ">";
	public static  final String SEMICOLON = ";";
	public static  final String SINGLE_QUOTE = "'";
	public static  final String BACKTICK = "`";
	public static  final String SPACE = " ";
	public static  final String LEFT_SQ_BRACKET = "[";
	public static  final String RIGHT_SQ_BRACKET = "]";
	public static  final String TRUE = "true";
	public static  final String UNDERSCORE = "_";
	public static  final String UTF_8 = "UTF-8";
	public static  final String US_ASCII = "US-ASCII";
	public static  final String ISO_8859_1 = "ISO-8859-1";
	public static  final String Y = "y";
	public static  final String YES = "yes";
	public static  final String ONE = "1";
	public static  final String ZERO = "0";
	public static  final String DOLLAR_LEFT_BRACE = "${";
	public static  final String CRLF = "\r\n";
	public static  final String HTML_NBSP = "&nbsp;";
	public static  final String HTML_AMP = "&amp";
	public static  final String HTML_QUOTE = "&quot;";
	public static  final String HTML_LT = "&lt;";
	public static  final String HTML_GT = "&gt;";

	public static String SAME = "same";
	public static String SUCCESS = "success";
	public static String FAIL = "fail";
	public static String ERROR = "error";
	public static String GEUSER = "geUser";
	public static String LOCK = "lock";
	public static String EXIST = "exist";

	public static int LOGIN_SUCCESS = 1;
	public static int LOGIN_OTHER_ERROR = -1;
	public static int LOGIN_USERACCOUNT_ERROR = 2;
	public static int LOGIN_USERPASSWD_ERROR = 3;
	public static int LOGIN_AUTHCODE_ERROR = 4;
	public static int LOGIN_USERACCOUNT_P = 5;

	public static final String TOTALCOUNT = "total";
	public static final String RESULTS = "rows";

	public static HashMap<Integer, String> recordTypeMap = new HashMap<Integer, String>();

	public static String getStoreRecordType(int alarmType) {
		recordTypeMap.put(0, "录像中 ");
		recordTypeMap.put(1, "无录像计划 ");
		recordTypeMap.put(2, "在备用存储区录像 ");
		recordTypeMap.put(3, "无存储组 ");
		recordTypeMap.put(4, "无可写的存储区 ");
		recordTypeMap.put(5, "前端不在线 ");
		recordTypeMap.put(6, "可写存储区不在线");
		recordTypeMap.put(7, "可写存储区已满 ");
		recordTypeMap.put(8, "频繁启停 ");
		recordTypeMap.put(9, "未启用 ");
		recordTypeMap.put(254, "未知异常");
		recordTypeMap.put(255, "未知状态 ");
		String name = recordTypeMap.get(alarmType);
		return name;
	}

	public static String LOG_QUERY = "查询";
	public static String LOG_ADD = "增加";
	public static String LOG_UPDATE = "修改";
	public static String LOG_DELETE = "删除";

	public static String NS = "北向南";
	public static String SN = "南向北";
	public static String EW = "东向西";
	public static String WE = "西向东";

	public static HashMap<Integer, String> actionTypeMap = new HashMap<Integer, String>();

	public static String getActionType(int actionType) {
		actionTypeMap.put(0, "其他");
		actionTypeMap.put(1, "用户登录类日志");
		actionTypeMap.put(2, "查询类日志信息");
		actionTypeMap.put(3, "增加类日志信息");
		actionTypeMap.put(4, "修改类日志信息");
		actionTypeMap.put(5, "删除类日志信息");
		String name = actionTypeMap.get(actionType);
		return name;
	}
	//交通设备类型
//	public final static String JT_BZ = "1";//标志
//	public final static String JT_BX = "2";//标线
//	public final static String JT_HL = "3";//护栏
//	public final static String JT_XHD = "4";//信号灯
//	public final static String JT_LEDYDP = "5";//led诱导屏
	public final static String JT_XHD = "3";//标志
	public final static String JT_YDP = "4";//标线
	public final static String JT_DC = "10";//护栏
	public final static String JT_WB = "11";//信号灯
	public final static String JT_LD = "12";//led诱导屏
}
