enum

SF::Http::Response::Status

Inherits Enum / Comparable / Value / Object

Enumerate all the valid status codes for a response

Constants

Ok = 200

Most common code returned when operation was successful

Created = 201

The resource has successfully been created

Accepted = 202

The request has been accepted, but will be processed later by the server

NoContent = 204

The server didn't send any data in return

ResetContent = 205

The server informs the client that it should clear the view (form) that caused the request to be sent

PartialContent = 206

The server has sent a part of the resource, as a response to a partial GET request

MultipleChoices = 300

The requested page can be accessed from several locations

MovedPermanently = 301

The requested page has permanently moved to a new location

MovedTemporarily = 302

The requested page has temporarily moved to a new location

NotModified = 304

For conditional requests, means the requested page hasn't changed and doesn't need to be refreshed

BadRequest = 400

The server couldn't understand the request (syntax error)

Unauthorized = 401

The requested page needs an authentication to be accessed

Forbidden = 403

The requested page cannot be accessed at all, even with authentication

NotFound = 404

The requested page doesn't exist

RangeNotSatisfiable = 407

The server can't satisfy the partial GET request (with a "Range" header field)

InternalServerError = 500

The server encountered an unexpected error

NotImplemented = 501

The server doesn't implement a requested feature

BadGateway = 502

The gateway server has received an error from the source server

ServiceNotAvailable = 503

The server is temporarily unavailable (overloaded, in maintenance, ...)

GatewayTimeout = 504

The gateway server couldn't receive a response from the source server

VersionNotSupported = 505

The server doesn't support the requested HTTP version

InvalidResponse = 1000

Response is not a valid HTTP one

ConnectionFailed = 1001

Connection with server failed

Instance methods

accepted?

Returns true if this enum value equals Accepted

Source
bad_gateway?

Returns true if this enum value equals BadGateway

Source
bad_request?

Returns true if this enum value equals BadRequest

Source
connection_failed?

Returns true if this enum value equals ConnectionFailed

Source
created?

Returns true if this enum value equals Created

Source
forbidden?

Returns true if this enum value equals Forbidden

Source
gateway_timeout?

Returns true if this enum value equals GatewayTimeout

Source
internal_server_error?

Returns true if this enum value equals InternalServerError

Source
invalid_response?

Returns true if this enum value equals InvalidResponse

Source
moved_permanently?

Returns true if this enum value equals MovedPermanently

Source
moved_temporarily?

Returns true if this enum value equals MovedTemporarily

Source
multiple_choices?

Returns true if this enum value equals MultipleChoices

Source
no_content?

Returns true if this enum value equals NoContent

Source
not_found?

Returns true if this enum value equals NotFound

Source
not_implemented?

Returns true if this enum value equals NotImplemented

Source
not_modified?

Returns true if this enum value equals NotModified

Source
ok?

Returns true if this enum value equals Ok

Source
partial_content?

Returns true if this enum value equals PartialContent

Source
range_not_satisfiable?

Returns true if this enum value equals RangeNotSatisfiable

Source
reset_content?

Returns true if this enum value equals ResetContent

Source
service_not_available?

Returns true if this enum value equals ServiceNotAvailable

Source
unauthorized?

Returns true if this enum value equals Unauthorized

Source
version_not_supported?

Returns true if this enum value equals VersionNotSupported

Source