Class: Rack::JsonSchema::BaseRequestHandler
- Inherits:
-
Object
- Object
- Rack::JsonSchema::BaseRequestHandler
- Defined in:
- lib/rack/json_schema/base_request_handler.rb
Overview
Base class for providing some utility methods to handle Rack env and JSON Schema
Direct Known Subclasses
Mock::RequestHandler, RequestValidation::Validator, ResponseValidation::Validator
Class Method Summary collapse
-
.call(*args, **kwargs) ⇒ Object
Utility wrapper method.
Instance Method Summary collapse
-
#initialize(env: nil, schema: nil) ⇒ BaseRequestHandler
constructor
A new instance of BaseRequestHandler.
Constructor Details
#initialize(env: nil, schema: nil) ⇒ BaseRequestHandler
Returns a new instance of BaseRequestHandler.
12 13 14 15 |
# File 'lib/rack/json_schema/base_request_handler.rb', line 12 def initialize(env: nil, schema: nil) @env = env @schema = schema end |
Class Method Details
.call(*args, **kwargs) ⇒ Object
Utility wrapper method
6 7 8 |
# File 'lib/rack/json_schema/base_request_handler.rb', line 6 def self.call(*args, **kwargs) new(*args, **kwargs).call end |