Files
lserp_cs_6.0/插件库/Lskj.Push/Common/BaseResult.cs
cyf ab56a9bcf7 基线 SVN r240
SVN-Revision: r240
2025-02-06 06:46:06 +00:00

52 lines
1.3 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Lskj.Push.Common
{
public abstract class BaseResult
{
public const int ERROR_CODE_NONE = -1;
public const int ERROR_CODE_OK = 0;
public const String ERROR_MESSAGE_NONE = "None error message.";
public const int RESPONSE_OK = 200;
private ResponseWrapper responseResult;
public ResponseWrapper ResponseResult
{
get { return responseResult; }
set { responseResult = value; }
}
public abstract bool isResultOK();
// public override String getErrorMessage();
public int getRateLimitQuota() {
if (null != responseResult) {
return responseResult.rateLimitQuota;
}
return 0;
}
public int getRateLimitRemaining() {
if (null != responseResult) {
return responseResult.rateLimitRemaining;
}
return 0;
}
public int getRateLimitReset() {
if (null != responseResult) {
return responseResult.rateLimitReset;
}
return 0;
}
}
}