using System; using System.Collections.Generic; using System.Runtime.Remoting.Messaging; namespace ln.http { public class HttpStatusCodes { static Dictionary statusMessages = new Dictionary() { { 200, "Ok" }, { 201, "Created" }, { 202, "Accepted" }, { 204, "No Content" }, { 403, "Access denied" }, { 404, "Not Found" }, { 500, "Internal Error" } }; public static String GetStatusMessage(int code){ if (statusMessages.ContainsKey(code)) return statusMessages[code]; return ""; } } }