diff options
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | lib/net/http/response.rb | 61 | ||||
-rw-r--r-- | lib/net/http/responses.rb | 21 |
3 files changed, 19 insertions, 70 deletions
@@ -1,3 +1,10 @@ +Sun Jun 10 18:58:16 2012 Akinori MUSHA <knu@iDaemons.org> + + * lib/net/http/response.rb: Remove a duplicated rdoc and leave a + pointer. + + * lib/net/http/responses.rb: Add RFC numbers to base on. + Sun Jun 10 18:31:42 2012 Yuki Sonoda (Yugui) <yugui@yugui.jp> * configure.in (RUBY_NACL): Warns if $PATH does not contain the path diff --git a/lib/net/http/response.rb b/lib/net/http/response.rb index a5c30a87d6..dde5ae308e 100644 --- a/lib/net/http/response.rb +++ b/lib/net/http/response.rb @@ -9,66 +9,9 @@ # Note that each possible HTTP response code defines its own # HTTPResponse subclass. These are listed below. # -# All classes are -# defined under the Net module. Indentation indicates inheritance. +# All classes are defined under the Net module. Indentation indicates +# inheritance. For a list of the classes see Net::HTTP. # -# xxx HTTPResponse -# -# 1xx HTTPInformation -# 100 HTTPContinue -# 101 HTTPSwitchProtocol -# -# 2xx HTTPSuccess -# 200 HTTPOK -# 201 HTTPCreated -# 202 HTTPAccepted -# 203 HTTPNonAuthoritativeInformation -# 204 HTTPNoContent -# 205 HTTPResetContent -# 206 HTTPPartialContent -# -# 3xx HTTPRedirection -# 300 HTTPMultipleChoice -# 301 HTTPMovedPermanently -# 302 HTTPFound -# 303 HTTPSeeOther -# 304 HTTPNotModified -# 305 HTTPUseProxy -# 307 HTTPTemporaryRedirect -# -# 4xx HTTPClientError -# 400 HTTPBadRequest -# 401 HTTPUnauthorized -# 402 HTTPPaymentRequired -# 403 HTTPForbidden -# 404 HTTPNotFound -# 405 HTTPMethodNotAllowed -# 406 HTTPNotAcceptable -# 407 HTTPProxyAuthenticationRequired -# 408 HTTPRequestTimeOut -# 409 HTTPConflict -# 410 HTTPGone -# 411 HTTPLengthRequired -# 412 HTTPPreconditionFailed -# 413 HTTPRequestEntityTooLarge -# 414 HTTPRequestURITooLong -# 415 HTTPUnsupportedMediaType -# 416 HTTPRequestedRangeNotSatisfiable -# 417 HTTPExpectationFailed -# 428 HTTPPreconditionRequired -# 429 HTTPTooManyRequests -# 431 HTTPRequestHeaderFieldsTooLarge -# -# 5xx HTTPServerError -# 500 HTTPInternalServerError -# 501 HTTPNotImplemented -# 502 HTTPBadGateway -# 503 HTTPServiceUnavailable -# 504 HTTPGatewayTimeOut -# 505 HTTPVersionNotSupported -# 511 HTTPNetworkAuthenticationRequired -# -# xxx HTTPUnknownResponse # class Net::HTTPResponse class << self diff --git a/lib/net/http/responses.rb b/lib/net/http/responses.rb index d17a452e7f..43494caaf1 100644 --- a/lib/net/http/responses.rb +++ b/lib/net/http/responses.rb @@ -116,16 +116,6 @@ end class Net::HTTPPreconditionFailed < Net::HTTPClientError # 412 HAS_BODY = true end -class Net::HTTPPreconditionRequired < Net::HTTPClientError # 428 - HAS_BODY = true -end -class Net::HTTPTooManyRequests < Net::HTTPClientError # 429 - HAS_BODY = true -end -class Net::HTTPRequestHeaderFieldsTooLarge < Net::HTTPClientError # 431 - HAS_BODY = true -end - class Net::HTTPRequestEntityTooLarge < Net::HTTPClientError # 413 HAS_BODY = true end @@ -142,6 +132,15 @@ end class Net::HTTPExpectationFailed < Net::HTTPClientError # 417 HAS_BODY = true end +class Net::HTTPPreconditionRequired < Net::HTTPClientError # 428 - RFC 6585 + HAS_BODY = true +end +class Net::HTTPTooManyRequests < Net::HTTPClientError # 429 - RFC 6585 + HAS_BODY = true +end +class Net::HTTPRequestHeaderFieldsTooLarge < Net::HTTPClientError # 431 - RFC 6585 + HAS_BODY = true +end class Net::HTTPInternalServerError < Net::HTTPServerError # 500 HAS_BODY = true @@ -161,7 +160,7 @@ end class Net::HTTPVersionNotSupported < Net::HTTPServerError # 505 HAS_BODY = true end -class Net::HTTPNetworkAuthenticationRequired < Net::HTTPServerError # 511 +class Net::HTTPNetworkAuthenticationRequired < Net::HTTPServerError # 511 - RFC 6585 HAS_BODY = true end |