Class: ValidatedNumber
- Inherits:
-
Object
- Object
- ValidatedNumber
- Defined in:
- lib/sms_service/sms_get_validated_numbers_response.rb
Instance Attribute Summary collapse
-
#number ⇒ Object
Returns the value of attribute number.
-
#validated_until ⇒ Object
Returns the value of attribute validated_until.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(number, validated_until) ⇒ ValidatedNumber
constructor
A new instance of ValidatedNumber.
- #to_s ⇒ Object
Constructor Details
#initialize(number, validated_until) ⇒ ValidatedNumber
Returns a new instance of ValidatedNumber.
37 38 39 40 |
# File 'lib/sms_service/sms_get_validated_numbers_response.rb', line 37 def initialize(number, validated_until) @number = number @validated_until = validated_until end |
Instance Attribute Details
#number ⇒ Object
Returns the value of attribute number.
35 36 37 |
# File 'lib/sms_service/sms_get_validated_numbers_response.rb', line 35 def number @number end |
#validated_until ⇒ Object
Returns the value of attribute validated_until.
35 36 37 |
# File 'lib/sms_service/sms_get_validated_numbers_response.rb', line 35 def validated_until @validated_until end |
Class Method Details
.build_from_xml(xml_doc) ⇒ Object
42 43 44 45 46 47 |
# File 'lib/sms_service/sms_get_validated_numbers_response.rb', line 42 def self.build_from_xml(xml_doc) number = xml_doc.xpath("number").to_s validated_until = xml_doc.xpath("validUntil").to_s return ValidatedNumber.new(number, validated_until) end |
Instance Method Details
#to_s ⇒ Object
49 50 51 |
# File 'lib/sms_service/sms_get_validated_numbers_response.rb', line 49 def to_s self.inspect end |