Class: OFX::Document
- Inherits:
-
Object
- Object
- OFX::Document
- Defined in:
- lib/ofx/document.rb,
lib/ofx/1.0.2/document.rb
Instance Attribute Summary collapse
-
#header ⇒ Object
Returns the value of attribute header.
-
#message_sets ⇒ Object
readonly
Returns the value of attribute message_sets.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ Document
constructor
A new instance of Document.
Constructor Details
Instance Attribute Details
#header ⇒ Object
Returns the value of attribute header.
21 22 23 |
# File 'lib/ofx/document.rb', line 21 def header @header end |
#message_sets ⇒ Object (readonly)
Returns the value of attribute message_sets.
22 23 24 |
# File 'lib/ofx/document.rb', line 22 def @message_sets end |
Class Method Details
.from_ofx_102_hash(document_hash) ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/ofx/1.0.2/document.rb', line 20 def self.from_ofx_102_hash(document_hash) contents = document_hash['OFX'] raise 'The top of the document was not an <OFX> tag.' unless contents document = OFX::Document.new contents.each_pair() do |, | document. << OFX::MessageSet.(, ) end document..sort! { |left, right| left.precedence <=> right.precedence } return document end |