Money::PaymentPreparer - change sum to bills and coins.


Money-PaymentPreparer documentation  | view source Contained in the Money-PaymentPreparer distribution.

Index


NAME

Top

Money::PaymentPreparer - change sum to bills and coins.

VERSION

Top

Version 0.03

SYNOPSIS

Top

 use Money::PaymentPreparer;

 my @my_bills  = qw (200 100 50 20 10 5 2 1);

 my $object = PaymentPreparer->new();
 $object->set_bill(@my_bills);
 $object->add(153);
 $object->add(68);
 %result = $object->get();

DESCRIPTION

Top

This module change sum (i.e. payment) to collection of bills and coins and keep it all in one hash returned by add or get.

new

creates the object.

set_bill

gets @list of nominations bills and coins. In Europe it should looks like this:

@my_table = qw (500 200 100 50 20 10 5 2 1);

add

value to change. It returns %hash of nominals with numbers of bills.

get

returns %hash of nominals with numbers of bills.

TO DO

Top

Support for decimal values.

Check for indivisible values.

AUTHOR

Top

Łukasz M±drzycki, <uksza@cpan.org>.

BUGS

Top

Who knows...

ACKNOWLEDGEMENTS

Top

All Perl family.

COPYRIGHT & LICENSE

Top


Money-PaymentPreparer documentation  | view source Contained in the Money-PaymentPreparer distribution.