Class: PensioAPI::FundingList
- Inherits:
-
Object
- Object
- PensioAPI::FundingList
- Defined in:
- lib/pensio_api/funding_list.rb
Instance Attribute Summary collapse
-
#acquirer ⇒ Object
readonly
Returns the value of attribute acquirer.
-
#amount ⇒ Object
readonly
Returns the value of attribute amount.
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#download_link ⇒ Object
readonly
Returns the value of attribute download_link.
-
#filename ⇒ Object
readonly
Returns the value of attribute filename.
-
#funding_date ⇒ Object
readonly
Returns the value of attribute funding_date.
Class Method Summary collapse
Instance Method Summary collapse
- #download(options = {}) ⇒ Object
-
#initialize(funding_list_body) ⇒ FundingList
constructor
A new instance of FundingList.
Constructor Details
#initialize(funding_list_body) ⇒ FundingList
Returns a new instance of FundingList.
15 16 17 18 19 20 21 22 23 24 |
# File 'lib/pensio_api/funding_list.rb', line 15 def initialize(funding_list_body) @raw = funding_list_body @filename = @raw['Filename'] @amount = @raw['Amount'] @acquirer = @raw['Acquirer'] @funding_date = Date.parse(@raw['FundingDate']) @created_at = Date.parse(@raw['CreatedDate']) @download_link = @raw['DownloadLink'].strip end |
Instance Attribute Details
#acquirer ⇒ Object (readonly)
Returns the value of attribute acquirer.
5 6 7 |
# File 'lib/pensio_api/funding_list.rb', line 5 def acquirer @acquirer end |
#amount ⇒ Object (readonly)
Returns the value of attribute amount.
4 5 6 |
# File 'lib/pensio_api/funding_list.rb', line 4 def amount @amount end |
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
7 8 9 |
# File 'lib/pensio_api/funding_list.rb', line 7 def created_at @created_at end |
#download_link ⇒ Object (readonly)
Returns the value of attribute download_link.
8 9 10 |
# File 'lib/pensio_api/funding_list.rb', line 8 def download_link @download_link end |
#filename ⇒ Object (readonly)
Returns the value of attribute filename.
3 4 5 |
# File 'lib/pensio_api/funding_list.rb', line 3 def filename @filename end |
#funding_date ⇒ Object (readonly)
Returns the value of attribute funding_date.
6 7 8 |
# File 'lib/pensio_api/funding_list.rb', line 6 def funding_date @funding_date end |
Class Method Details
.all(options = {}) ⇒ Object
10 11 12 13 |
# File 'lib/pensio_api/funding_list.rb', line 10 def self.all(={}) request = Request.new('/merchant/API/fundingList', ) Responses::FundingList.new(request) end |
Instance Method Details
#download(options = {}) ⇒ Object
26 27 28 |
# File 'lib/pensio_api/funding_list.rb', line 26 def download(={}) @result ||= FundingListRequest.new(@download_link, ).result end |