Class: OFX::CreditCardStatementMessageSet
- Inherits:
-
MessageSet
- Object
- MessageSet
- OFX::CreditCardStatementMessageSet
- Defined in:
- lib/ofx/credit_card_statement_message_set.rb,
lib/ofx/1.0.2/credit_card_statement_message_set.rb
Class Method Summary collapse
Instance Method Summary collapse
- #ofx_102_message_set_name ⇒ Object
- #precedence ⇒ Object
- #request_or_response_from_ofx_102_tag_name(response_or_request_name) ⇒ Object
- #version ⇒ Object
Methods inherited from MessageSet
from_ofx_102_message_set_hash, #requests, #responses, #to_ofx_102_s
Class Method Details
.from_ofx_102_hash(message_set_hash) ⇒ Object
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 |
# File 'lib/ofx/1.0.2/credit_card_statement_message_set.rb', line 34 def self.from_ofx_102_hash() = CreditCardStatementMessageSet.new .each_pair() do |transaction_name, transaction_hash| case transaction_name when "CCSTMTTRNRQ" then .requests << CreditCardStatementRequest.from_ofx_102_hash(transaction_hash) when "CCSTMTTRNRS" then .responses << CreditCardStatementResponse.from_ofx_102_hash(transaction_hash) when "CCSTMTENDTRNRQ" then .requests << CreditCardClosingStatementRequest.from_ofx_102_hash(transaction_hash) when "CCSTMTENDTRNRS" then .responses << CreditCardClosingStatementResponse.from_ofx_102_hash(transaction_hash) else raise NotImplementedError, transaction_name end end return end |
Instance Method Details
#ofx_102_message_set_name ⇒ Object
20 21 22 |
# File 'lib/ofx/1.0.2/credit_card_statement_message_set.rb', line 20 def 'CREDITCARD' end |
#precedence ⇒ Object
20 21 22 |
# File 'lib/ofx/credit_card_statement_message_set.rb', line 20 def precedence 4 end |
#request_or_response_from_ofx_102_tag_name(response_or_request_name) ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/ofx/1.0.2/credit_card_statement_message_set.rb', line 24 def request_or_response_from_ofx_102_tag_name(response_or_request_name) case response_or_request_name when "CCSTMTTRNRQ" then CreditCardStatementRequest.new when "CCSTMTTRNRS" then CreditCardStatementResponse.new when "CCSTMTENDTRNRQ" then CreditCardClosingStatementRequest.new when "CCSTMTENDTRNRS" then CreditCardClosingStatementResponse.new else raise NotImplementedError, response_or_request_name end end |
#version ⇒ Object
23 24 25 |
# File 'lib/ofx/credit_card_statement_message_set.rb', line 23 def version 1 end |