~landscape/zope3/ztk-1.1.3

« back to all changes in this revision

Viewing changes to src/twisted/web2/responsecode.py

  • Committer: Andreas Hasenack
  • Date: 2009-07-20 17:49:16 UTC
  • Revision ID: andreas@canonical.com-20090720174916-g2tn6qmietz2hn0u
Revert twisted removal, it breaks several dozen tests [trivial]

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# -*- test-case-name: twisted.web2.test -*-
 
2
# Copyright (c) 2001-2004 Twisted Matrix Laboratories.
 
3
# See LICENSE for details.
 
4
 
 
5
CONTINUE                        = 100
 
6
SWITCHING                       = 101
 
7
 
 
8
OK                              = 200
 
9
CREATED                         = 201
 
10
ACCEPTED                        = 202
 
11
NON_AUTHORITATIVE_INFORMATION   = 203
 
12
NO_CONTENT                      = 204
 
13
RESET_CONTENT                   = 205
 
14
PARTIAL_CONTENT                 = 206
 
15
MULTI_STATUS                    = 207
 
16
 
 
17
MULTIPLE_CHOICE                 = 300
 
18
MOVED_PERMANENTLY               = 301
 
19
FOUND                           = 302
 
20
SEE_OTHER                       = 303
 
21
NOT_MODIFIED                    = 304
 
22
USE_PROXY                       = 305
 
23
TEMPORARY_REDIRECT              = 307
 
24
 
 
25
BAD_REQUEST                     = 400
 
26
UNAUTHORIZED                    = 401
 
27
PAYMENT_REQUIRED                = 402
 
28
FORBIDDEN                       = 403
 
29
NOT_FOUND                       = 404
 
30
NOT_ALLOWED                     = 405
 
31
NOT_ACCEPTABLE                  = 406
 
32
PROXY_AUTH_REQUIRED             = 407
 
33
REQUEST_TIMEOUT                 = 408
 
34
CONFLICT                        = 409
 
35
GONE                            = 410
 
36
LENGTH_REQUIRED                 = 411
 
37
PRECONDITION_FAILED             = 412
 
38
REQUEST_ENTITY_TOO_LARGE        = 413
 
39
REQUEST_URI_TOO_LONG            = 414
 
40
UNSUPPORTED_MEDIA_TYPE          = 415
 
41
REQUESTED_RANGE_NOT_SATISFIABLE = 416
 
42
EXPECTATION_FAILED              = 417
 
43
UNPROCESSABLE_ENTITY            = 422 # RFC 2518
 
44
LOCKED                          = 423 # RFC 2518
 
45
FAILED_DEPENDENCY               = 424 # RFC 2518
 
46
 
 
47
INTERNAL_SERVER_ERROR           = 500
 
48
NOT_IMPLEMENTED                 = 501
 
49
BAD_GATEWAY                     = 502
 
50
SERVICE_UNAVAILABLE             = 503
 
51
GATEWAY_TIMEOUT                 = 504
 
52
HTTP_VERSION_NOT_SUPPORTED      = 505
 
53
INSUFFICIENT_STORAGE_SPACE      = 507
 
54
NOT_EXTENDED                    = 510
 
55
 
 
56
RESPONSES = {
 
57
    # 100
 
58
    CONTINUE: "Continue",
 
59
    SWITCHING: "Switching Protocols",
 
60
 
 
61
    # 200
 
62
    OK: "OK",
 
63
    CREATED: "Created",
 
64
    ACCEPTED: "Accepted",
 
65
    NON_AUTHORITATIVE_INFORMATION: "Non-Authoritative Information",
 
66
    NO_CONTENT: "No Content",
 
67
    RESET_CONTENT: "Reset Content.",
 
68
    PARTIAL_CONTENT: "Partial Content",
 
69
    MULTI_STATUS: "Multi-Status",
 
70
 
 
71
    # 300
 
72
    MULTIPLE_CHOICE: "Multiple Choices",
 
73
    MOVED_PERMANENTLY: "Moved Permanently",
 
74
    FOUND: "Found",
 
75
    SEE_OTHER: "See Other",
 
76
    NOT_MODIFIED: "Not Modified",
 
77
    USE_PROXY: "Use Proxy",
 
78
    # 306 unused
 
79
    TEMPORARY_REDIRECT: "Temporary Redirect",
 
80
 
 
81
    # 400
 
82
    BAD_REQUEST: "Bad Request",
 
83
    UNAUTHORIZED: "Unauthorized",
 
84
    PAYMENT_REQUIRED: "Payment Required",
 
85
    FORBIDDEN: "Forbidden",
 
86
    NOT_FOUND: "Not Found",
 
87
    NOT_ALLOWED: "Method Not Allowed",
 
88
    NOT_ACCEPTABLE: "Not Acceptable",
 
89
    PROXY_AUTH_REQUIRED: "Proxy Authentication Required",
 
90
    REQUEST_TIMEOUT: "Request Time-out",
 
91
    CONFLICT: "Conflict",
 
92
    GONE: "Gone",
 
93
    LENGTH_REQUIRED: "Length Required",
 
94
    PRECONDITION_FAILED: "Precondition Failed",
 
95
    REQUEST_ENTITY_TOO_LARGE: "Request Entity Too Large",
 
96
    REQUEST_URI_TOO_LONG: "Request-URI Too Long",
 
97
    UNSUPPORTED_MEDIA_TYPE: "Unsupported Media Type",
 
98
    REQUESTED_RANGE_NOT_SATISFIABLE: "Requested Range not satisfiable",
 
99
    EXPECTATION_FAILED: "Expectation Failed",
 
100
    UNPROCESSABLE_ENTITY: "Unprocessable Entity",
 
101
    LOCKED: "Locked",
 
102
    FAILED_DEPENDENCY: "Failed Dependency",
 
103
 
 
104
    # 500
 
105
    INTERNAL_SERVER_ERROR: "Internal Server Error",
 
106
    NOT_IMPLEMENTED: "Not Implemented",
 
107
    BAD_GATEWAY: "Bad Gateway",
 
108
    SERVICE_UNAVAILABLE: "Service Unavailable",
 
109
    GATEWAY_TIMEOUT: "Gateway Time-out",
 
110
    HTTP_VERSION_NOT_SUPPORTED: "HTTP Version not supported",
 
111
    INSUFFICIENT_STORAGE_SPACE: "Insufficient Storage Space",
 
112
    NOT_EXTENDED: "Not Extended"
 
113
    }
 
114
 
 
115
# No __all__ necessary -- everything is exported