Status
Description:
[ CCode ( cprefix = "SOUP_STATUS_" , type_id = "soup_status_get_type ()" ) ]
public enum Status
public enum Status
These represent the known HTTP status code values, plus various network and internal errors.
Note that no libsoup functions take or return this type directly; any function that works with status codes will accept unrecognized status codes as well.
Prior to 2.44 this type was called SoupKnownStatusCode, but the individual values have always had the names they have now.
Namespace: Soup
Package: libsoup-2.4
Content:
Enum values:
- ACCEPTED - 202 Accepted (HTTP)
- BAD_GATEWAY - 502 Bad Gateway (HTTP)
- BAD_REQUEST - 400 Bad Request (HTTP)
- CANCELLED - Message was cancelled locally
- CANT_CONNECT - Unable to connect to remote host
- CANT_CONNECT_PROXY - Unable to connect to proxy
- CANT_RESOLVE - Unable to resolve destination host name
- CANT_RESOLVE_PROXY - Unable to resolve proxy host name
- CONFLICT - 409 Conflict (HTTP)
- CONTINUE - 100 Continue (HTTP)
- CREATED - 201 Created (HTTP)
- EXPECTATION_FAILED - 417 Expectation Failed (HTTP)
- FAILED_DEPENDENCY - 424 Failed Dependency (WebDAV)
- FORBIDDEN - 403 Forbidden (HTTP)
- FOUND - 302 Found (HTTP)
- GATEWAY_TIMEOUT - 504 Gateway Timeout (HTTP)
- GONE - 410 Gone (HTTP)
- HTTP_VERSION_NOT_SUPPORTED - 505 HTTP Version Not Supported (HTTP)
- INSUFFICIENT_STORAGE - 507 Insufficient Storage (WebDAV)
- INTERNAL_SERVER_ERROR - 500 Internal Server Error (HTTP)
- INVALID_RANGE - shorter alias for REQUESTED_RANGE_NOT_SATISFIABLE
- IO_ERROR - A network error occurred, or the other end closed the connection unexpectedly
- LENGTH_REQUIRED - 411 Length Required (HTTP)
- LOCKED - 423 Locked (WebDAV)
- MALFORMED - Malformed data (usually a programmer error)
- METHOD_NOT_ALLOWED - 405 Method Not Allowed (HTTP)
- MOVED_PERMANENTLY - 301 Moved Permanently (HTTP)
- MOVED_TEMPORARILY - 302 Moved Temporarily (old name, RFC 2068)
- MULTIPLE_CHOICES - 300 Multiple Choices (HTTP)
- MULTI_STATUS - 207 Multi-Status (WebDAV)
- NONE - No status available.
- NON_AUTHORITATIVE - 203 Non-Authoritative Information (HTTP)
- NOT_ACCEPTABLE - 406 Not Acceptable (HTTP)
- NOT_APPEARING_IN_THIS_PROTOCOL - 306 [Unused] (HTTP)
- NOT_EXTENDED - 510 Not Extended (RFC 2774)
- NOT_FOUND - 404 Not Found (HTTP)
- NOT_IMPLEMENTED - 501 Not Implemented (HTTP)
- NOT_MODIFIED - 304 Not Modified (HTTP)
- NO_CONTENT - 204 No Content (HTTP)
- OK - 200 Success (HTTP).
- PARTIAL_CONTENT - 206 Partial Content (HTTP)
- PAYMENT_REQUIRED - 402 Payment Required (HTTP)
- PERMANENT_REDIRECT
- PRECONDITION_FAILED - 412 Precondition Failed (HTTP)
- PROCESSING - 102 Processing (WebDAV)
- PROXY_AUTHENTICATION_REQUIRED - 407 Proxy Authentication Required (HTTP)
- PROXY_UNAUTHORIZED - shorter alias for PROXY_AUTHENTICATION_REQUIRED
- REQUESTED_RANGE_NOT_SATISFIABLE - 416 Requested Range Not Satisfiable (HTTP)
- REQUEST_ENTITY_TOO_LARGE - 413 Request Entity Too Large (HTTP)
- REQUEST_TIMEOUT - 408 Request Timeout (HTTP)
- REQUEST_URI_TOO_LONG - 414 Request-URI Too Long (HTTP)
- RESET_CONTENT - 205 Reset Content (HTTP)
- SEE_OTHER - 303 See Other (HTTP)
- SERVICE_UNAVAILABLE - 503 Service Unavailable (HTTP)
- SSL_FAILED - SSL/TLS negotiation failed
- SWITCHING_PROTOCOLS - 101 Switching Protocols (HTTP)
- TEMPORARY_REDIRECT - 307 Temporary Redirect (HTTP)
- TLS_FAILED - Used internally
- TOO_MANY_REDIRECTS - There were too many redirections
- TRY_AGAIN - Used internally
- UNAUTHORIZED - 401 Unauthorized (HTTP)
- UNPROCESSABLE_ENTITY - 422 Unprocessable Entity (WebDAV)
- UNSUPPORTED_MEDIA_TYPE - 415 Unsupported Media Type (HTTP)
- USE_PROXY - 305 Use Proxy (HTTP)
Static methods:
- public static unowned string get_phrase (uint status_code)
Looks up the stock HTTP description of
status_code
. - public static uint proxify (uint status_code)
Turns CANT_RESOLVE into CANT_RESOLVE_PROXY and CANT_CONNECT into CANT_CONNECT_PROXY.