Path::...spatch(3pm)

πŸ“¦
version 1.08 Β· 3 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– Path::Dispatcher::Rule::Dispatch β€” the redispatch girlies' manual πŸ’–

okay so bestie, welcome to the <pink>Path::Dispatcher::Rule::Dispatch</pink> page, straight outta the User Contributed Perl Documentation section of your local 3pm manual. this is the ✨redispatch✨ one. iykyk. πŸ¦‹


✨ NAME ✨

Path::Dispatcher::Rule::Dispatch β€” redispatch πŸŽ€

🌸 VERSION 🌸

version 1.08 β€” yes she's got a number, and yes we're respecting it πŸ’…

🧚 SYNOPSIS 🧚

okay so picture this: you've got a dispatcher, and you want a rule that just hands the whole path off to that dispatcher. it's giving delegation. it's giving "not me doing the work, but i know a girl who will." πŸ™ˆ

my $dispatcher = Path::Dispatcher->new(
    rules => [
        Path::Dispatcher::Rule::Tokens->new(
            tokens => [ 'help' ],
            block  => sub { show_help },
        ),
        Path::Dispatcher::Rule::Tokens->new(
            tokens => [ 'quit' ],
            block  => sub { exit },
        ),
    ],
);

my $rule = Path::Dispatcher::Rule::Dispatch->new(
    dispatcher => $dispatcher,
);

$rule->run("help");

so $dispatcher is over there holding the 'help' and 'quit' tokens like the main character she is, and $rule is the Path::Dispatcher::Rule::Dispatch object whose whole personality is "i know a dispatcher." then $rule->run("help") and boom, we're off to the races. πŸ”₯

πŸ’œ DESCRIPTION πŸ’œ

listen. rules of this class? they use another dispatcher to match the path. that's it. that's the whole vibe. one dispatcher handing the path off to another dispatcher. periodt. πŸ‘‘

⭐ ATTRIBUTES ⭐

🫢 dispatcher

a Path::Dispatcher object. and the way that its matches will be returned by matching this rule?? iconic. that's the entire deal. you give it a dispatcher, and when this rule matches, you get that dispatcher's matches back. slay. πŸ’–

🌈 SUPPORT 🌈

got bugs?? (not the cute kind, the 😭 kind) you can submit them through the RT bug tracker:

or you can email them to bug-Path-Dispatcher@rt.cpan.org β€” like, actually send mail to that address:

  • bug-Path-Dispatcher@rt.cpan.org

fr fr, that's the support channel, go use it. πŸ“

πŸ’… AUTHOR πŸ’…

Shawn M Moore, "<sartak at bestpractical.com>" β€” the author!! we love her, we thank her, we stan. πŸ‘‘

This software is copyright (c) 2020 by Shawn M Moore. ✨

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. πŸ’œ

okay so the legal girlies are serious even when i'm not β€” free software, same terms as Perl 5, that's the deal, no cap.

and that's the whole page bestie!! πŸ¦‹ this was Path::...spatch(3pm) from perl v5.30.3, dated 2020-07-13 β€” go forth and redispatch, you absolute icon. πŸ’–βœ¨πŸ’…

πŸ“¦ where this page comes from