/// <summary>
        /// 学生手机客户端计时请求
        /// </summary>
        /// <param name="studentClient">学生手机客户端</param>
        /// <param name="stuId">学号</param>
        /// <param name="keepTime">持续计时时间</param>
        private void timeReq(attendanceServerSocket studentClient, string stuId, int keepTime)
        {
            JObject timeRsp = new JObject();

            timeRsp.Add("type", "timeRsp");
            int score = (int)(((float)keepTime / (float)attendanceServerInfo.getAttendanceServerInfo().getStartServerInterval()) * (float)100);

            if (score >= 100)
            {
                score = 100;
            }
            mysqlImp.getMysql().update("update timeattendance set score=" + score + ",keepTime = " + keepTime + " where stuId='" + stuId + "'");
            DataTable table = mysqlImp.getMysql().showTable("select keepTime,score from timeattendance where stuId='" + stuId + "'");

            timeRsp.Add("keepTime", aesImp.getAesImp().encrypt(
                            table.Rows[0]["keepTime"].ToString(),
                            attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
            timeRsp.Add("score", aesImp.getAesImp().encrypt(
                            table.Rows[0]["score"].ToString(),
                            attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
            mysqlImp.getMysql().update("update timeattendance set allcore = score + ecore where stuId='" + stuId + "'");
            mysqlImp.getMysql().update("update timeattendance set allcore = 100 where allcore > 100 and stuId='" + stuId + "'");
            mysqlImp.getMysql().update("update timeattendance set allcore = 0 where allcore < 0 and stuId='" + stuId + "'");
            studentClient.sendMsg(timeRsp.ToString());
        }
        /// <summary>
        /// 连接回复
        /// </summary>
        /// <param name="studentClient">学生手机客户端对象</param>
        public void connRsp(attendanceServerSocket studentClient)
        {
            JObject connRsp = new JObject();

            connRsp.Add("type", "connRsp");
            connRsp.Add("randomKey", attendanceServerInfo.getAttendanceServerInfo().getRandomKey());
            connRsp.Add("attendanceType", loadStudentListInfo.getLoadStudent().getAttendanceType().ToString());
            attendanceInfo.getAttendance().getStartCheck().showServerReceive("发送数据给客户端:" + connRsp.ToString());
            studentClient.sendMsg(connRsp.ToString());
        }
        /// <summary>
        /// 学生签到
        /// </summary>
        /// <param name="studentClient">学生手机客户端对象</param>
        /// <param name="stuId">学生学号</param>
        /// <param name="stuTele">学生手机号码</param>
        /// <param name="stuMac">学生手机MAC地址</param>
        private void signStudent(attendanceServerSocket studentClient, string stuId, string stuTele, string stuMac)
        {
            JObject signRsp = new JObject();

            signRsp.Add("type", "signRsp");
            if (checkStudentExist(stuId))
            {
                if (checkStudentSign(stuId))
                {
                    // 检测该学号已经签到过了
                    if (loadStudentListInfo.getLoadStudent().getAttendanceType())
                    {
                        // 检测考勤模式处于计时模式
                        if (checkStudentTeleInfo(stuId, stuTele, stuMac))
                        {
                            // 回复计时
                            returnTime(stuId, signRsp);
                            signRsp.Add("returnType", "2");
                        }
                        else
                        {
                            // 回复计时失败,原因:该学号的手机号码和手机MAC信息与签到时的信息不一致
                            signRsp.Add("result", aesImp.getAesImp().encrypt(
                                            "该学号的手机号码和手机MAC信息与签到时的信息不一致",
                                            attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                            signRsp.Add("returnType", "0");
                        }
                    }
                    else
                    {
                        // 检测考勤模式处于签到模式,签到失败:该学号已经签到过了
                        signRsp.Add("result", aesImp.getAesImp().encrypt(
                                        "该学号已经签到过了",
                                        attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                        signRsp.Add("returnType", "0");
                    }
                }
                else
                {
                    // 检测该学号没有签到
                    if (checkStudentTele(stuTele))
                    {
                        // 检测该手机号码已经被使用
                        signRsp.Add("result", aesImp.getAesImp().encrypt(
                                        "该手机号码已经被使用",
                                        attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                        signRsp.Add("returnType", "0");
                    }
                    else
                    {
                        // 该手机号码没被使用
                        if (checkStudentMac(stuMac))
                        {
                            // 检测该手机设备已经被使用
                            signRsp.Add("result", aesImp.getAesImp().encrypt(
                                            "该手机设备已经被使用",
                                            attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                            signRsp.Add("returnType", "0");
                        }
                        else
                        {
                            // 检测该手机设备没有被使用
                            // 学生签到
                            sign(stuId, stuTele, stuMac);
                            if (loadStudentListInfo.getLoadStudent().getAttendanceType())
                            {
                                signRsp.Add("result", aesImp.getAesImp().encrypt(
                                                "签到成功,请认真上课",
                                                attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                            }
                            else
                            {
                                signRsp.Add("result", aesImp.getAesImp().encrypt(
                                                "签到成功,计时过程请关闭屏幕并认真上课",
                                                attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                            }
                            signRsp.Add("interval", aesImp.getAesImp().encrypt(
                                            attendanceServerInfo.getAttendanceServerInfo().getStartServerInterval().ToString()
                                            , attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
                            signRsp.Add("returnType", "1");
                            updateStudentClient(studentClient, stuId);
                            if (!loadStudentListInfo.getLoadStudent().getAttendanceType())
                            {
                                mysqlImp.getMysql().update("update signattendance set allcore = score + ecore where stuId='" + stuId + "'");
                                mysqlImp.getMysql().update("update signattendance set allcore = 100 where allcore > 100 and stuId='" + stuId + "'");
                                mysqlImp.getMysql().update("update signattendance set allcore = 0 where allcore < 0 and stuId='" + stuId + "'");
                            }
                        }
                    }
                }
            }
            else
            {
                signRsp.Add("result", aesImp.getAesImp().encrypt(
                                "学号不存在,请重新输入学号",
                                attendanceServerInfo.getAttendanceServerInfo().getRandomKey()));
            }
            studentClient.sendMsg(signRsp.ToString());
            attendanceInfo.getAttendance().getStartCheck().showServerReceive(signRsp.ToString());
        }