File::Rsync::Mirror::Recentfile::Done - intervals of already rsynced timespans
my $done = File::Rsync::Mirror::Recentfile::Done->new; $done->register ( $recent_events, [3,4,5,9] ); # registers elements 3-5 and 9 my $boolean = $done->covered ( $epoch );
Keeping track of already rsynced timespans.
Constructor. On every argument pair the key is a method name and the value is an argument to that method name.
Boolean to turn on a bit verbosity.
The first form returns true if both timestamps $epoch1 and $epoch2 in floating point notation have been registered within one interval, otherwise false.
The second form returns true if this timestamp has been registered.
Integrates all intervals in $obj2 into $obj1. Overlapping intervals are conflated/folded/consolidated. Sort order is preserved as decreasing.
The first arrayref is a list of hashes that contain a key called
epoch which is a string looking like a number. The second arrayref is a list if integers which point to elements in the first arrayref to be registered.
The second form registers all events in $recent_events_arrayref.
Forgets everything ever done and gives way for a new round of mirroring. Usually called when the dirtymark on upstream has changed.
Copyright 2008, 2009 Andreas König.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.