Class: ZSS::Message::Address
- Inherits:
-
Object
- Object
- ZSS::Message::Address
- Defined in:
- lib/zss/message/message_address.rb
Instance Attribute Summary collapse
-
#sid ⇒ Object
Returns the value of attribute sid.
-
#sversion ⇒ Object
Returns the value of attribute sversion.
-
#verb ⇒ Object
Returns the value of attribute verb.
Instance Method Summary collapse
-
#initialize(args = {}) ⇒ Address
constructor
A new instance of Address.
- #to_s ⇒ Object
Constructor Details
#initialize(args = {}) ⇒ Address
Returns a new instance of Address.
10 11 12 13 14 |
# File 'lib/zss/message/message_address.rb', line 10 def initialize args = {} @sid = args[:sid].try(:upcase) @verb = args[:verb].try(:upcase) @sversion = args[:sversion].try(:upcase) || '*' end |
Instance Attribute Details
#sid ⇒ Object
Returns the value of attribute sid.
6 7 8 |
# File 'lib/zss/message/message_address.rb', line 6 def sid @sid end |
#sversion ⇒ Object
Returns the value of attribute sversion.
6 7 8 |
# File 'lib/zss/message/message_address.rb', line 6 def sversion @sversion end |
#verb ⇒ Object
Returns the value of attribute verb.
6 7 8 |
# File 'lib/zss/message/message_address.rb', line 6 def verb @verb end |
Instance Method Details
#to_s ⇒ Object
16 17 18 |
# File 'lib/zss/message/message_address.rb', line 16 def to_s "#{sid}:#{sversion}##{verb}" end |