SetErrorBody() public méthode

public SetErrorBody ( string msg, ResponseBody bdy = null ) : void
msg string
bdy ResponseBody
Résultat void
        public void SetErrorResponse(Response response, int id, string format, dynamic arguments = null, bool user = true, bool telemetry = false)
        {
            var msg     = new Message(id, format, arguments, user, telemetry);
            var message = Utilities.ExpandVariables(msg.format, msg.variables);

            response.SetErrorBody(message, new ErrorResponseBody(msg));
        }
Exemple #2
0
        void SendErrorResponse(string command, int seq, int id, string format, dynamic arguments = null, bool user = true, bool telemetry = false)
        {
            var response = new Response(command, seq);
            var msg      = new Message(id, format, arguments, user, telemetry);
            var message  = Utilities.ExpandVariables(msg.format, msg.variables);

            response.SetErrorBody(message, new ErrorResponseBody(msg));
            toVSCode.SendMessage(response);
        }
 public void SendErrorResponse(Response response, int id, string format, dynamic arguments = null, bool user = true, bool telemetry = false)
 {
     var msg = new Message(id, format, arguments, user, telemetry);
     var message = Utilities.ExpandVariables(msg.format, msg.variables);
     response.SetErrorBody(message, new ErrorResponseBody(msg));
     SendMessage(response);
 }