NAME
Asterisk::LCR::Comparer::XERAND - More advanced rate comparer for Asterisk::LCR
SUMMARY
This comparer is a bit cleverer than Asterisk::LCR::Comparer::Dummy.
It does currency conversion using Finance::Currency::Convert::XE, and then adjust cost per minute using a traffic simulator.
Currently the traffic simulator is a bit simplistic: it generates a call length between 0 and 200 seconds (to have an everage of 100 seconds call length).
In the future there will be a more sophisticated simulator capable of running rates against past traffic CDRs to measure real cost.
ATTRIBUTES
none.
METHODS
$self->sortme ($object1, $object2);
Simply compares $object1->rate() with $object2->rate().
Doesn't care about time increments or even rate currency(!).
Pretty dumb... it would be nice to have better rate comparers but it's a start and can be overriden...