Class: Quaff::CSeq
- Inherits:
-
Object
- Object
- Quaff::CSeq
- Defined in:
- lib/call.rb
Overview
:nodoc:
Instance Attribute Summary collapse
-
#num ⇒ Object
readonly
Returns the value of attribute num.
Instance Method Summary collapse
- #increment ⇒ Object
-
#initialize(cseq_str) ⇒ CSeq
constructor
A new instance of CSeq.
- #to_s ⇒ Object
Constructor Details
#initialize(cseq_str) ⇒ CSeq
Returns a new instance of CSeq.
10 11 12 13 |
# File 'lib/call.rb', line 10 def initialize cseq_str @num, @method = cseq_str.split @num = @num.to_i end |
Instance Attribute Details
#num ⇒ Object (readonly)
Returns the value of attribute num.
9 10 11 |
# File 'lib/call.rb', line 9 def num @num end |
Instance Method Details
#increment ⇒ Object
15 16 17 18 |
# File 'lib/call.rb', line 15 def increment @num = @num + 1 to_s end |
#to_s ⇒ Object
20 21 22 |
# File 'lib/call.rb', line 20 def to_s "#{@num.to_s} #{@method}" end |