aboutsummaryrefslogtreecommitdiff
path: root/Timeline/Models/Http
diff options
context:
space:
mode:
author杨宇千 <crupest@outlook.com>2019-08-20 23:41:36 +0800
committer杨宇千 <crupest@outlook.com>2019-08-20 23:41:36 +0800
commit63eec85627bcd3c584865d47a237de44bcdb8b98 (patch)
tree4554d77dcf4e10cdfa9955e496c0ede22788448a /Timeline/Models/Http
parent4af6c82f34dd79d7a1ca348f167e01570951e3ad (diff)
downloadtimeline-63eec85627bcd3c584865d47a237de44bcdb8b98.tar.gz
timeline-63eec85627bcd3c584865d47a237de44bcdb8b98.tar.bz2
timeline-63eec85627bcd3c584865d47a237de44bcdb8b98.zip
Use etag for cache.
Diffstat (limited to 'Timeline/Models/Http')
-rw-r--r--Timeline/Models/Http/Common.cs6
1 files changed, 6 insertions, 0 deletions
diff --git a/Timeline/Models/Http/Common.cs b/Timeline/Models/Http/Common.cs
index 50f6836e..a72f187c 100644
--- a/Timeline/Models/Http/Common.cs
+++ b/Timeline/Models/Http/Common.cs
@@ -13,6 +13,7 @@ namespace Timeline.Models.Http
public const int Header_Missing_ContentType = -111;
public const int Header_Missing_ContentLength = -112;
public const int Header_Zero_ContentLength = -113;
+ public const int Header_BadFormat_IfNonMatch = -114;
}
public static CommonResponse InvalidModel(string message)
@@ -35,6 +36,11 @@ namespace Timeline.Models.Http
return new CommonResponse(ErrorCodes.Header_Zero_ContentLength, "Header Content-Length must not be 0.");
}
+ public static CommonResponse BadIfNonMatch()
+ {
+ return new CommonResponse(ErrorCodes.Header_BadFormat_IfNonMatch, "Header If-Non-Match is of bad format.");
+ }
+
public CommonResponse()
{