Web开发中常⽤的状态码
在HtttpServletRespon类中有关于状态码的描述。
磨课static int SC_ACCEPTED
经典广告Status code (202) indicating that a request was accepted for processing, but was not completed.
状态码(202)表明处理的请求被接受,但未能完成。
static int SC_BAD_GATEWAY
Status code (502) indicating that the HTTP rver received an invalid respon from a rver it consulted when acting as a proxy or gateway.
状态码(502)表明HTTP服务器收到⽆效的响应从服务器充当代理或⽹关时参考。
static int SC_BAD_REQUEST
Status code (400) indicating the request nt by the client was syntactically incorrect.
状态码(400)指⽰客户端发送的请求是语法错误。
static int SC_CONFLICT
Status code (409) indicating that the request could not be completed due to a conflict with the current state of the resource.
状态码(409)表明请求不能完成由于冲突资源的当前状态。
static int SC_CONTINUE
Status code (100) indicating the client can continue.
状态码(100)指⽰客户端可以继续。
static int SC_CREATED
Status code (201) indicating the request succeeded and created a new resource on the rver.
状态码(201)表⽰请求成功和在服务器上创建了⼀个新的资源。
static int SC_EXPECTATION_FAILED
Status code (417) indicating that the rver could not meet the expectation given in the Expect request header.
状态码(417),表明给出的服务器⽆法满⾜期望的期望请求头。
static int SC_FORBIDDEN
Status code (403) indicating the rver understood the request but refud to fulfill it.
状态码(403)表明服务器理解的请求,但拒绝履⾏它。
static int SC_GATEWAY_TIMEOUT
Status code (504) indicating that the rver did not receive a timely respon from the upstream rver while acting as a gateway or proxy.
状态码(504)表明服务器没有收到及时响应从上游服务器作为⽹关或代理。
static int SC_GONE
Status code (410) indicating that the resource is no longer available at the rver and no forwarding
address is known.
状态码(410),表明资源不再是可⽤的服务器,也没有转发地址。
static int SC_HTTP_VERSION_NOT_SUPPORTED
居高临下的临是什么意思Status code (505) indicating that the rver does not support or refus to support the HTTP protocol version that was ud in the request message.
状态码(505)表明服务器不⽀持或不⽀持HTTP请求消息中使⽤的协议版本。
static int SC_INTERNAL_SERVER_ERROR
Status code (500) indicating an error inside the HTTP rver which prevented it from fulfilling the request.
状态码(500)表明⼀个错误在阻⽌它满⾜请求的HTTP服务器。
static int SC_LENGTH_REQUIRED
Status code (411) indicating that the request cannot be handled without a defined Content-Length.
状态码(411)表明请求内容长度不能处理没有定义。
static int SC_METHOD_NOT_ALLOWED
Status code (405) indicating that the method specified in the Request-Line is not allowed for the resource identified by the Request-URI.
状态码(405)表明该⽅法中指定请求⾏是不允许资源得到由请求uri所指定资源。
static int SC_MOVED_PERMANENTLY
Status code (301) indicating that the resource has permanently moved to a new location, and that future references should u a new URI with their requests.
状态码(301),表明资源已经永久搬到⼀个新的位置,和未来的引⽤应该使⽤⼀个新的URI的请求。
static int SC_MOVED_TEMPORARILY
static int SC_MOVED_TEMPORARILY
Status code (302) indicating that the resource has temporarily moved to another location, but that fut
ure references should still u the original URI to access the resource.
状态码(302),表明资源暂时搬到另⼀个位置,但未来的引⽤应该仍然使⽤原来的URI来访问资源。
static int SC_MULTIPLE_CHOICES
Status code (300) indicating that the requested resource corresponds to any one of a t of reprentations, each with its own specific location.
状态码(300)表明所请求的资源对应的⼀组表⽰,每个都有⾃⼰的特定位置。
static int SC_NO_CONTENT
Status code (204) indicating that the request succeeded but that there was no new information to return.
状态码(204)表明请求成功了,但是没有新的信息返回。
static int SC_NON_AUTHORITATIVE_INFORMATION
Status code (203) indicating that the meta information prented by the client did not originate from t
he rver.
状态码(203),表明客户端所呈现的元信息不是来⾃服务器。
static int SC_NOT_ACCEPTABLE
Status code (406) indicating that the resource identified by the request is only capable of generating respon entities which have content characteristics not acceptable according to the accept headersnt in the request.
状态码(406),表明资源被请求只能⽣成响应实体内容的特征根据接受headersnt不可接受的请求。
static int SC_NOT_FOUND
尊师重道的故事Status code (404) indicating that the requested resource is not available.
状态码(404)表明所请求的资源不可⽤。
static int SC_NOT_IMPLEMENTED
Status code (501) indicating the HTTP rver does not support the functionality needed to fulfill the r
equest.
状态码(501)指⽰所需的HTTP服务器不⽀持的功能满⾜要求。
static int SC_NOT_MODIFIED
Status code (304) indicating that a conditional GET operation found that the resource was available and not modified.
状态码(304)表明⼀个条件GET操作发现资源是可⽤的,⽽不是修改。
static int SC_OK
Status code (200) indicating the request succeeded normally.
状态码(200)通常表⽰请求成功。
static int SC_PARTIAL_CONTENT
Status code (206) indicating that the rver has fulfilled the partial GET request for the resource.
状态码(206)表明服务器已经完成部分GET请求的资源。
static int SC_PAYMENT_REQUIRED
Status code (402) rerved for future u.
状态码(402)保留以供将来使⽤。
static int SC_PRECONDITION_FAILED
Status code (412) indicating that the precondition given in one or more of the request-header fields evaluated to fal when it was tested on the rver.
状态码(412),表明给出的先决条件中的⼀个或多个请求头字段值为fal时在服务器上进⾏测试。
static int SC_PROXY_AUTHENTICATION_REQUIRED
Status code (407) indicating that the client MUST first authenticate itlf with the proxy.
状态码(407)表明客户机必须⾸先验证本⾝与代理。
static int SC_REQUEST_ENTITY_TOO_LARGE
手机个人热点
原味的味道
Status code (413) indicating that the rver is refusing to process the request becau the request entity is larger than the rver is willing or able to process.
状态码(413)表明服务器拒绝处理请求,因为请求实体⼤于服务器不愿或不能实现的⾏为过程。
static int SC_REQUEST_TIMEOUT
Status code (408) indicating that the client did not produce a requestwithin the time that the rver was prepared to wait. static int SC_REQUEST_URI_TOO_LONG
Status code (414) indicating that the rver is refusing to rvice the request becau the Request-URI is longer than the rver is willing to interpret.
static int SC_REQUESTED_RANGE_NOT_SATISFIABLE
Status code (416) indicating that the rver cannot rve the requested byte range.中考励志名言
static int SC_RESET_CONTENT
Status code (205) indicating that the agent SHOULD ret the document view which caud the request to be nt.
Status code (205) indicating that the agent SHOULD ret the document view which caud the request to be nt.
static int SC_SEE_OTHER
Status code (303) indicating that the respon to the request can be found under a different URI.
static int SC_SERVICE_UNAVAILABLE
Status code (503) indicating that the HTTP rver is temporarily overloaded, and unable to handle the request.
static int SC_SWITCHING_PROTOCOLS
Status code (101) indicating the rver is switching protocols according to Upgrade header.
static int SC_TEMPORARY_REDIRECT
Status code (307) indicating that the requested resource resides temporarily under a different URI.
static int SC_UNAUTHORIZED
羊毛出在羊身上
Status code (401) indicating that the request requires HTTP authentication.
static int SC_UNSUPPORTED_MEDIA_TYPE
Status code (415) indicating that the rver is refusing to rvice the request becau the entity of the request is in a format not supported by the requested resource for the requested method.
static int SC_USE_PROXY
Status code (305) indicating that the requested resource MUST be accesd through the proxy given by the Location field.