Hi all,

I would like to write a module for inclusion in the DateTime namespace. The
purpose of the module is to provide extra comparison methods between
DateTime::Span objects. I'm basically wanting to reimplement the ideas in
the existing package Date::Interval using DateTime as the underlying date
representation. The docs of Date::Interval give a good rundown on the
interface I would propose...

http://search.cpan.org/~ktorp/Interval.0.03/Interval.pm

Or, to spare you reading all that, here's what I would like to do in a
nutshell...

my $spancmp1 = new DateTime::Span::Compare(start => $dt1, end => $dt2);
my $spancmp2 = new DateTime::Span::Compare(start => $dt3, end => $dt4);
if ( $spancmp1->left_overlaps($spancmp2) ) {
    # ... left_overlaps is one of 13 comparison methods made available
}

I have a couple of questions for the list: First, are there any objections
to the use of the name DateTime::Span::Compare for this module.

Second, I am planning make this module a subclass of DateTime::Span. Are
there any problems with this approach I may be unaware of?

Thanks in advance.

f

Reply via email to