Skip to content

muir/Sort-MergeSort

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NAME
    Sort::MergeSort - merge pre-sorted input streams

SYNOPSIS
     use Sort::MergeSort;

     my $terator = mergesort($comparefunc, @iterators);

DESCRIPTION
    Given a comparison function and a bunch of iterators that produce data
    that is already sorted, "mergesort()" will provide an iterator that
    produces sorted and merged data from all of the input iterators.

    Sort::MergeSort also works with filehandles. It doesn't care. If it's
    only input is a filehandle, it will return a filehandle. In all other
    situations it will return an iterator.

    The $comparefunc takes two arguments. It does not use the implicit $a &
    $b that perl sort uses.

    The iterators are treated as file handles so any filehandle or
    Sort::MergeSort::Iterator will do as input.

EXAMPLE
     use Sort::MergeSort;

SEE ALSO
    Sort::MergeSort::Iterator

LICENSE
    Copyright (C) 2008,2009 David Sharnoff. Copyright (C) 2013 Google, Inc.

    This package may be used and redistributed under the terms of either the
    Artistic 2.0 or LGPL 2.1 license.

About

The perl Sort::MergeSort module on CPAN

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages