CPAN::Common::Index::Mux::Ordered(3pm)

CPAN::Common::Index::Mux::Ordered3pm

Consult indices in order and return the first result

Usage

    use CPAN::Common::Index::Mux::Ordered;
    use Data::Dumper;
    $index = CPAN::Common::Index::Mux::Ordered->assemble(
        MetaDB => {},
        Mirror => { mirror => "http://cpan.cpantesters.org" },
    );

Version

version 0.010

Overview

This module multiplexes multiple CPAN::Common::Index objects, returning results in order.

For exact match queries, the first result is returned. For search queries, results from each index object are concatenated.

Attributes

resolvers

    An array reference of CPAN::Common::Index::* objects

Methods

assemble

    $index = CPAN::Common::Index::Mux::Ordered->assemble(
        MetaDB => {},
        Mirror => { mirror => "http://www.cpan.org" },
    );

This class method provides a shorthand for constructing a multiplexer. The arguments must be pairs of subclass suffixes and arguments. For example, "MetaDB" means to use "CPAN::Common::Index::MetaDB". Empty arguments must be given as an empty hash reference.

Releases

4 releases since Debian 10 (Buster); the text changed 2 times.

  1. 10
  2. 11
  3. 12–13

Author

David Golden <[email protected]>

From libcpan-common-index-perl 0.010-2 in Debian 13 (Trixie). Parsed by carta from the page's man source.