DateTime-Event-Cron-Quartz

 view release on metacpan or  search on metacpan

lib/DateTime/Event/Cron/Quartz/TreeSet.pm  view on Meta::CPAN

    my $tail_set = $set->tail_set(15);

    # check if the set contains an element
    if ($set->contains(40)) {
        print "set contains element with value of 40\n";
    }


=head1 DESCRIPTION

This package implements the set. This package guarantees that the sorted set
will be in ascending element order. Elements in this set are unique.
Package provides some functionality from
L<http://java.sun.com/j2se/1.4.2/docs/api/java/util/TreeSet.html>


=head1 SUBROUTINES/METHODS

=over

=item new($list)

Returns a DateTime::Event::Cron::Quartz::TreeSet object which
contains the list of values if $list parameter was provided

=item size()

Returns the number of elements in this set (its cardinality).

=item first_item()

Returns the first (lowest) element currently in this sorted set.

=item last_item()

Returns the last (gratest) element currently in this sorted set.

=item contains($element)

Returns true if this set contains the specified element.

=item tail_set($from_element)

Returns a view of the portion of this set whose
elements are greater than or equal to $from_element.
The returned sorted set supports all TreeSet methods.

=item to_array()

Returns an ordered array of elements


=back


=head1 INCOMPATIBILITIES

TreeSet works only with numbers. strings/objects are not allowed


=head1 BUGS AND LIMITATIONS

This is not a complete implementation of TreeSet. Only basic functionality
used by DateTime::Event::Cron::Quartz provided. Can not be used separately.


=head1 AUTHOR

Vadim Loginov <vadim.loginov@gmail.com>


=head1 COPYRIGHT AND LICENSE

Based on the source code and documentation of OpenSymphony
L<http://www.opensymphony.com/team.jsp> Quartz 1.4.2 project licensed
under the Apache License, Version 2.0

Copyright (c) 2009 Vadim Loginov.

This module is free software; you can redistribute it
and/or modify it under the same terms as Perl itself.


=head1 VERSION

0.05

=head1 SEE ALSO

DateTime::Event::Cron::Quartz(3),
L<http://java.sun.com/j2se/1.4.2/docs/api/java/util/TreeSet.html>



( run in 1.870 second using v1.01-cache-2.11-cpan-39bf76dae61 )