Class: EndiciaLabelServer::Parsers::UserSignUpParser
- Inherits:
-
ParserBase
- Object
- Ox::Sax
- ParserBase
- EndiciaLabelServer::Parsers::UserSignUpParser
- Defined in:
- lib/endicia_label_server/parsers/user_sign_up_parser.rb
Instance Attribute Summary collapse
-
#account_id ⇒ Object
Returns the value of attribute account_id.
-
#confirmation_number ⇒ Object
Returns the value of attribute confirmation_number.
-
#token ⇒ Object
Returns the value of attribute token.
Attributes inherited from ParserBase
#current_attributes, #error_description, #status_code, #switches
Instance Method Summary collapse
Methods inherited from ParserBase
#attr, #element_tracker_switch, #end_element, #initialize, #reset_current_attributes!, #start_element, #switch_active?
Constructor Details
This class inherits a constructor from EndiciaLabelServer::Parsers::ParserBase
Instance Attribute Details
#account_id ⇒ Object
Returns the value of attribute account_id.
4 5 6 |
# File 'lib/endicia_label_server/parsers/user_sign_up_parser.rb', line 4 def account_id @account_id end |
#confirmation_number ⇒ Object
Returns the value of attribute confirmation_number.
4 5 6 |
# File 'lib/endicia_label_server/parsers/user_sign_up_parser.rb', line 4 def confirmation_number @confirmation_number end |
#token ⇒ Object
Returns the value of attribute token.
4 5 6 |
# File 'lib/endicia_label_server/parsers/user_sign_up_parser.rb', line 4 def token @token end |
Instance Method Details
#success? ⇒ Boolean
19 20 21 |
# File 'lib/endicia_label_server/parsers/user_sign_up_parser.rb', line 19 def success? !['0', 0].include? confirmation_number end |
#value(value) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/endicia_label_server/parsers/user_sign_up_parser.rb', line 6 def value(value) super string_value = value.as_s if switch_active? :ConfirmationNumber self.confirmation_number = string_value elsif switch_active? :AccountID self.account_id = string_value elsif switch_active? :Token self.token = string_value end end |