logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

MooX::MethodProxyArgs - Invoke code to populate static arguments.

Authors

       See "AUTHORS" in MooX::BuildArgs.

Description

       This module munges the class's input arguments by replacing any method proxy values found with the result
       of calling the methods.

       This is done using Data::MethodProxy.  See that module for more information on how method proxies work.

License

       See "LICENSE" in MooX::BuildArgs.

perl v5.40.0                                       2024-12-31                         MooX::MethodProxyArgs(3pm)

Name

       MooX::MethodProxyArgs - Invoke code to populate static arguments.

See Also

       •   MooX::BuildArgs

       •   MooX::BuildArgsHooks

       •   MooX::Rebuild

       •   MooX::SingleArg

Support

       See "SUPPORT" in MooX::BuildArgs.

Synopsis

           package Foo;
           use Moo;
           with 'MooX::MethodProxyArgs';
           has bar => (
               is => 'ro',
           );

           package main;

           sub divide {
               my ($class, $number, $divisor) = @_;
               return $number / $divisor;
           }

           my $foo = Foo->new( bar => ['$proxy', 'main', 'divide', 10, 2 ] );

           print $foo->bar(); # 5

See Also