Class: Isono::Rack::Response
- Inherits:
-
Object
- Object
- Isono::Rack::Response
- Defined in:
- lib/isono/rack.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#ctx ⇒ Object
readonly
Returns the value of attribute ctx.
Instance Method Summary collapse
-
#initialize(ctx) ⇒ Response
constructor
A new instance of Response.
- #progress(msg) ⇒ Object
- #responded? ⇒ Boolean
- #response(msg) ⇒ Object
Constructor Details
#initialize(ctx) ⇒ Response
Returns a new instance of Response.
48 49 50 51 |
# File 'lib/isono/rack.rb', line 48 def initialize(ctx) raise TypeError unless ctx.is_a?(NodeModules::RpcChannel::ResponseContext) @ctx = ctx end |
Instance Attribute Details
#ctx ⇒ Object (readonly)
Returns the value of attribute ctx.
45 46 47 |
# File 'lib/isono/rack.rb', line 45 def ctx @ctx end |
Instance Method Details
#progress(msg) ⇒ Object
57 58 59 |
# File 'lib/isono/rack.rb', line 57 def progress(msg) @ctx.progress(msg) end |
#responded? ⇒ Boolean
53 54 55 |
# File 'lib/isono/rack.rb', line 53 def responded? @ctx.responded? end |
#response(msg) ⇒ Object
61 62 63 |
# File 'lib/isono/rack.rb', line 61 def response(msg) @ctx.response(msg) end |