Exemplo n.º 1
0
 public static Response icar_SetPhoneNumText(CmdParam.ParamType ParamType, string CarValues, string CarPw, CmdParam.CommMode CommMode, TrafficPhoneNumText trafficPhoneNumText)
 {
     Response response;
     if (RemotingClient.app == null)
     {
         return RemotingClient.reResult;
     }
     try
     {
         response = RemotingClient.app.icar_SetPhoneNumText(ParamType, CarValues, CarPw, CommMode, trafficPhoneNumText);
     }
     catch (SocketException socketException)
     {
         Record.execFileRecord("交通部协议指令", socketException.Message);
         response = RemotingClient.reResult;
     }
     catch (RemotingException remotingException)
     {
         Record.execFileRecord("交通部协议指令", remotingException.Message);
         response = RemotingClient.reResult;
     }
     catch (Exception exception)
     {
         Record.execFileRecord("交通部协议指令", exception.ToString());
         response = RemotingClient.reResult;
     }
     return response;
 }
Exemplo n.º 2
0
 public Response icar_SetPhoneNumText(CmdParam.ParamType paramType_0, string string_1, string string_2, CmdParam.CommMode commMode_0, TrafficPhoneNumText trafficPhoneNumText_0)
 {
     Response response = new Response();
     base.logMsg.FunctionName = "icar_SetPhoneNumText";
     base.logMsg.Msg = "发送:类型-" + paramType_0.ToString() + ",车辆-" + string_1 + ",指令-" + trafficPhoneNumText_0.OrderCode.ToString();
     string msg = base.logMsg.Msg;
     base.log.WriteLog(base.logMsg);
     if (!base.CheckCar(paramType_0, string_1, string_2))
     {
         response.ErrorMsg = base.ErrorMsg;
         return response;
     }
     if (!base.isStartCommon())
     {
         response.ErrorMsg = base.ErrorMsg;
         return response;
     }
     new Car();
     foreach (Bussiness.CarInfo info in base.carInfoList)
     {
         try
         {
             int newOrderId = SendBase.CarCmdSend.GetNewOrderId();
             if (info.ProtocolName == SendBase.m_ProtocolName)
             {
                 base.m_Params1 = trafficPhoneNumText_0.m_Params;
                 base.m_Params2 = trafficPhoneNumText_0.m_ParamsReport;
                 base.SaveCmdParm(newOrderId.ToString() + "|" + info.CarId.ToString() + ";");
                 base.userInfo.DownCommd.AddCarNewLogData(newOrderId, info.CarNum, "发送", trafficPhoneNumText_0.OrderCode.ToString(), "等待", "", msg);
                 string conntent = "";
                 string str3 = trafficPhoneNumText_0.ToXmlString(base.CalOrderId(base.WorkId, newOrderId), info.SimNum, SendBase.m_ProtocolName, (int) commMode_0, "icar_SetCommonCmd", ref conntent);
                 response.ResultCode = SendBase.CarCmdSend.icar_SendCmdXML(base.WorkId, newOrderId, info.SimNum, SendBase.m_ProtocolName, (int) trafficPhoneNumText_0.OrderCode, (int) commMode_0, str3);
             }
             else
             {
                 base.userInfo.DownCommd.AddCarNewLogData(newOrderId, info.CarNum, "发送", trafficPhoneNumText_0.OrderCode.ToString(), "失败", "", "错误描述:该车辆终端不支持此操作。");
                 response.ErrorMsg = "终端不支持该协议";
             }
         }
         catch (Exception exception)
         {
             response.ErrorMsg = exception.Message;
             return response;
         }
     }
     return response;
 }
Exemplo n.º 3
0
 public void GetPhoneNumTextPara(out string string_0, out string string_1, TrafficPhoneNumText trafficPhoneNumText_0)
 {
     string[] separator = new string[] { "," };
     new SqlDataAccess();
     string[] strArray2 = trafficPhoneNumText_0.FlagList.Split(separator, StringSplitOptions.RemoveEmptyEntries);
     string[] strArray3 = trafficPhoneNumText_0.PhoneListList.Split(separator, StringSplitOptions.RemoveEmptyEntries);
     string[] strArray4 = trafficPhoneNumText_0.NameList.Split(separator, StringSplitOptions.RemoveEmptyEntries);
     string_0 = "#";
     string_1 = "设置:";
     if (((strArray2.Length != 0) && (strArray3.Length != 0)) && (strArray4.Length != 0))
     {
         for (int i = 0; i < strArray2.Length; i++)
         {
             if ((i >= strArray3.Length) || (i >= strArray4.Length))
             {
                 break;
             }
             string str = strArray2[i];
             string str2 = strArray3[i];
             string str3 = strArray4[i];
             string str4 = string_0;
             string_0 = str4 + str + "," + str2 + "," + str3 + "#";
             string str5 = string_1;
             string_1 = str5 + str + "," + str2 + "," + str3 + "#";
         }
     }
 }
Exemplo n.º 4
0
 public Response icar_SetPhoneNumText(CmdParam.ParamType ParamType, string CarValues, string CarPw, CmdParam.CommMode CommMode, TrafficPhoneNumText trafficPhoneNumText)
 {
     try
     {
         return this.myDownDataYD.icar_SetPhoneNumText(ParamType, CarValues, CarPw, CommMode, trafficPhoneNumText);
     }
     catch (Exception exception)
     {
         this.m_LogHelper.WriteError(new ErrorMsg("RemotingServer", "icar_SetPhoneNumText", exception.ToString()));
         return new Response();
     }
 }