Exception: Rackful::HTTPSimpleStatus Abstract

Inherits:
HTTPStatus
  • Object
show all
Defined in:
lib/rackful/httpstatus.rb

Overview

This class is abstract.

Base class for HTTP status codes with only a simple text message, or no message at all.

Direct Known Subclasses

HTTP400BadRequest, HTTP403Forbidden, HTTP404NotFound, HTTP409Conflict, HTTP410Gone, HTTP411LengthRequired, HTTP422UnprocessableEntity, HTTP501NotImplemented, HTTP503ServiceUnavailable

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (HTTPSimpleStatus) initialize(message = nil)

Returns a new instance of HTTPSimpleStatus



109
110
111
112
113
# File 'lib/rackful/httpstatus.rb', line 109

def initialize message = nil
  /HTTP(\d\d\d)\w+\z/ === self.class.to_s
  status = $1.to_i
  super( status, message )
end

Instance Attribute Details

- (void) headers (readonly) Originally defined in class HTTPStatus

Returns the value of attribute headers

- (void) status (readonly) Originally defined in class HTTPStatus

Returns the value of attribute status

- (void) to_rackful (readonly) Originally defined in class HTTPStatus

Returns the value of attribute to_rackful