using System; using System.Collections.Generic; using System.Linq; using System.Web; namespace MESWebSite.CommonClass { public class ResponseResult { public bool IsSuccess { get; set; } public string Message { get; set; } private ResponseResult() { } private ResponseResult(bool isSuccess, string message) { IsSuccess = isSuccess; Message = message; } public static ResponseResult Success() { return Success(""); } public static ResponseResult Success(string message) { return new ResponseResult(true, message); } public static ResponseResult Fail(string message) { return new ResponseResult(false, message); } public override string ToString() { return JSONHelper.ObjectToJSON(this); } } }