Finance::Bank::SCSB::TW::CurrencyExchangeRateCollection - Finance::Bank::SCSB::TW::CurrencyExchangeRateCollection documentation


Finance-Bank-SCSB-TW documentation Contained in the Finance-Bank-SCSB-TW distribution.

Index


Code Index:

NAME

Top

Finance::Bank::SCSB::TW::CurrencyExchangeRateCollection

SYNOPSIS

Top

    my $rates = Finance::Bank::SCSB::TW::currency_exchange_rate;

    my $usd_rates = $rates->for_currency('usd');

METHODS

Top

for_currency($name)

Given a currency $name, return a sub-set (as an arrayref) of the original exchange rate table.

For a list of currency names, see the table in this page: https://ibank.scsb.com.tw/netbank.portal?_nfpb=true&_pageLabel=page_other12&_nfls=fals

WARNING

Top

This is code for online banking, and that means your money, and that means BE CAREFUL. You are encouraged, nay, expected, to audit the source of this module yourself to reassure yourself that I am not doing anything untoward with your banking data. This software is useful to me, but is provided under NO GUARANTEE, explicit or implied.

AUTHOR

Top

Kang-min Liu <gugod@gugod.org>

Based on Finance::Bank::LloydTSB by Simon Cozens simon@cpan.org, and Finance::Bank::Fubon::TW by Autrijus Tang autrijus@autrijus.org

COPYRIGHT

Top


Finance-Bank-SCSB-TW documentation Contained in the Finance-Bank-SCSB-TW distribution.

package Finance::Bank::SCSB::TW::CurrencyExchangeRateCollection;
use strict;
use warnings;

sub for_currency {
    my $self = shift;
    my $currency_name = shift;

    my @ret = ();
    for my $c (@$self) {
        if ($c->{en_currency_name} =~ /\Q${currency_name}\E/i) {
            push @ret, $c;
        }
    }

    return \@ret;
}


1;

__END__