Class: Jets::Mega::Request::Source
- Inherits:
-
Object
- Object
- Jets::Mega::Request::Source
- Defined in:
- lib/jets/mega/request/source.rb
Instance Method Summary collapse
- #body ⇒ Object
- #content_length ⇒ Object
-
#initialize(event) ⇒ Source
constructor
A new instance of Source.
Constructor Details
Instance Method Details
#body ⇒ Object
9 10 11 12 13 14 15 |
# File 'lib/jets/mega/request/source.rb', line 9 def body if @source_request.body.respond_to?(:read) body = @source_request.body.read @source_request.body.rewind end body end |
#content_length ⇒ Object
17 18 19 |
# File 'lib/jets/mega/request/source.rb', line 17 def content_length @source_request.content_length.to_i end |