Business-US_Amort
view release on metacpan or search on metacpan
lib/Business/US_Amort.pm view on Meta::CPAN
=over
=item principal
The principal amount of the loan.
=item interest_rate
The annual rate, expressed like 8.3, not like .083.
Note that if you're defining callbacks, you can change this attribute
at any time in your callbacks, to change the rate of interest from
then on.
=item term
The term of the loan, in years, not months.
=item callback_before_monthly_calc
If set, this should be a coderef to a routine to call at the B<beginning>
of each month, B<before any> calculations are done.
lib/Business/US_Amort.pm view on Meta::CPAN
iterator from entering any infinite loops, even in pathological cases.
Currently the C<run> method sets this to twelve plus twice the number
of months that it's expected this loan will take.
Increase as necessary.
=back
=head2 ITERATION ATTRIBUTES
These are attributes of little or no interest once C<run> is done, but
may be of interest to callbacks while C<run> is running, or may
be of interest in examining snapshots in C<table>.
=over
=item _month_count
This is how many months we are into the loan. The first month is 1.
=item _abort
If you want callbacks to be able to halt the iteration for some
reason, you can have them set C<_abort> to true. You may also choose
to set C<error> to something helpful.
=item _monthly_payment
The amount to be paid to toward the principal each month. At the start
of the loan, this is set to whatever C<initial_monthly_payment> is
figured to be, but you can manipulate C<_monthly_payment> with
callbacks to change how much actually gets paid when.
=item _remainder
The balance on the loan.
=item _date
The given month's date, if known, in the format "YYYY-MM". Unless you'd
set the C<start_date> to something, this will be undef.
( run in 1.239 second using v1.01-cache-2.11-cpan-9b1e4054eb1 )