Class: Pragma::Operation::Response::BadRequest
- Inherits:
-
Pragma::Operation::Response
- Object
- Pragma::Operation::Response
- Pragma::Operation::Response::BadRequest
- Defined in:
- lib/pragma/operation/response/bad_request.rb
Overview
Represents the 400 Bad Request HTTP response.
Constant Summary
Constants inherited from Pragma::Operation::Response
Instance Attribute Summary
Attributes inherited from Pragma::Operation::Response
Instance Method Summary collapse
-
#initialize(entity: Error.new(error_type: :bad_request, error_message: 'This request is malformed.'), headers: {}) ⇒ BadRequest
constructor
A new instance of BadRequest.
Methods inherited from Pragma::Operation::Response
#decorate_with, #failure?, #success?
Constructor Details
#initialize(entity: Error.new(error_type: :bad_request, error_message: 'This request is malformed.'), headers: {}) ⇒ BadRequest
Returns a new instance of BadRequest.
8 9 10 11 12 13 |
# File 'lib/pragma/operation/response/bad_request.rb', line 8 def initialize( entity: Error.new(error_type: :bad_request, error_message: 'This request is malformed.'), headers: {} ) super(status: 400, entity: entity, headers: headers) end |