Class: Urushiol::Txresp
- Inherits:
-
Object
- Object
- Urushiol::Txresp
- Defined in:
- lib/txresp.rb
Instance Method Summary collapse
- #body(body) ⇒ Object
- #get_source ⇒ Object
- #header(hdr) ⇒ Object
-
#initialize ⇒ Txresp
constructor
A new instance of Txresp.
- #message(msg) ⇒ Object
- #protocol(proto) ⇒ Object
- #status_code(status) ⇒ Object
Constructor Details
#initialize ⇒ Txresp
Returns a new instance of Txresp.
4 5 6 |
# File 'lib/txresp.rb', line 4 def initialize @resp = "\ntxresp" end |
Instance Method Details
#body(body) ⇒ Object
24 25 26 |
# File 'lib/txresp.rb', line 24 def body(body) @resp << " -body \"#{body}\"" end |
#get_source ⇒ Object
28 29 30 |
# File 'lib/txresp.rb', line 28 def get_source @resp end |
#header(hdr) ⇒ Object
20 21 22 |
# File 'lib/txresp.rb', line 20 def header(hdr) @resp << " -hdr \"#{hdr}\"" end |
#message(msg) ⇒ Object
8 9 10 |
# File 'lib/txresp.rb', line 8 def (msg) @resp << " -msg #{msg}" end |
#protocol(proto) ⇒ Object
12 13 14 |
# File 'lib/txresp.rb', line 12 def protocol(proto) @resp << " -proto #{proto}" end |
#status_code(status) ⇒ Object
16 17 18 |
# File 'lib/txresp.rb', line 16 def status_code(status) @resp << " -status #{status}" end |