The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Catmandu::IdGenerator - A base class for modules that needs to generate identifiers

SYNOPSIS

    package MyPackage;

    use Moo;

    with 'Catmandu::IdGenerator';

    sub generate {
       return int(rand(999999)) . "-" . time;
    }

    package main;

    my $x = MyPackage->new;

    for (1..100) {
       printf "id: %s\n" m $x->generate;
    }

SEE ALSO

Catmandu::IdGenerator::Mock , Catmandu::IdGenerator::UUID