perl-Carp-Proxy-0.15-alt1.noarch.rpm


Advertisement

Description

perl-Carp-Proxy - Diagnostic delegation

Property Value
Distribution ALT Linux Sisyphus
Repository Autoimports noarch
Package name perl-Carp-Proxy
Package version 0.15
Package release alt1
Package architecture noarch
Package type rpm
Installed size 98.03 KB
Download size 98.03 KB
Official Mirror ftp.altlinux.org
Error messages in Perl are commonly coded with idioms like:
die 'explanation'
if not $assertion;
The idiom is attractive when the explanation is simple.  If an
explanation grows to more than a few words, or if it requires
calculation, then the surrounding flow becomes disrupted.  The
solution, of course, is to offload failing assertions to a subroutine.
Subroutines that perform diagnosis, compose error messages and throw
exceptions tend to have repeated code at the beginning and end, with
unique content somewhere in the middle.  Carp::Proxy proposes a
wrapper subroutine, called a Proxy, to factor out the repeated sections.
fatal 'user_subroutine'
if not $assertion;
Proxys, like fatal(), serve as elaborate, customizable replacements
for warn(), die() and members of the Carp:: family like
confess().  If we look at warn(), die(), confess() and the like,
we notice that they are all just different variations on two themes:
- Add locational context to a user-supplied message.
- Throw some kind of exception.
Carp::Proxy parameterizes the two themes into attributes of an
exception object that is created whenever a Proxy is called.  The
Proxy passes the object to a user-defined "Handler" subroutine which
is responsible for constructing the diagnostic message.  When the
Handler returns, the Proxy optionally adds "Context" (a stacktrace) to
the message and performs "Disposition", typically by calling die().
When the object is constructed it captures the state of Perl's error
variables, for later examination by the Handler.  The object provides
methods that aid in message composition.  Attributes control message
formatting, stacktrace generation and how Disposition will be handled.
The object overloads Perl's stringification operator with a message
rendering method, causing uncaught exceptions to be nicely formatted.
Exceptions that are caught can be modified and re-thrown.

Alternatives

Package Version Architecture Repository
perl-Carp-Proxy - - -

Requires

Name Value
/usr/share/perl5 -
perl(Config.pm) -
perl(Cwd.pm) -
perl(English.pm) -
perl(Moose.pm) -
perl(Pod/Usage.pm) -
perl(Readonly.pm) -
perl(Sub/Name.pm) -
perl(YAML/XS.pm) -
perl(overload.pm) -
perl(subs.pm) -
perl-base >= 1:5.10.0
rpmlib(PayloadIsLzma) -

Provides

Name Value
perl(Carp/Proxy.pm) = 0.150
perl-Carp-Proxy = 0.15-alt1

Download

Type URL
Binary Package perl-Carp-Proxy-0.15-alt1.noarch.rpm
Source Package perl-Carp-Proxy-0.15-alt1.src.rpm

Install Howto

  1. Add the following line to /etc/apt/sources.list:
    
    rpm [Sisyphus] http://ftp.altlinux.org/pub/distributions/ALTLinux/autoimports/Sisyphus noarch autoimports
    rpm [Sisyphus] http://ftp.altlinux.org/pub/distributions/ALTLinux/autoimports/Sisyphus noarch autoimports
    
  2. Update the package index:
    # sudo apt-get update
  3. Install perl-Carp-Proxy rpm package:
    # sudo apt-get install perl-Carp-Proxy

Files

Path
/usr/share/doc/perl-Carp-Proxy-0.15/Changes
/usr/share/doc/perl-Carp-Proxy-0.15/README
/usr/share/perl5/Carp/.perlcriticrc
/usr/share/perl5/Carp/Proxy.pm

See Also

Package Description
perl-Carp-REPL-0.18-alt1_11.noarch.rpm Read-eval-print-loop on die and/or warn
perl-Carp-Reply-0.08-alt1.noarch.rpm get a repl on exceptions in your program
perl-Carp-Source-1.101420-alt1.noarch.rpm Warn of errors with stack backtrace and source context
perl-Carp-Syslog-0.01-alt1.noarch.rpm Send warn and die messages to syslog
perl-Carp-Trace-0.12-alt1.noarch.rpm perl module Carp-Trace
perl-Carton-1.0.12-alt1.noarch.rpm Perl module dependency manager (aka Bundler for Perl)
perl-Carton-scripts-1.0.12-alt1.noarch.rpm Carton scripts
perl-Cassandra-Lite-0.4.0-alt1.noarch.rpm Simple way to access Cassandra 0.7/0.8
perl-Catalyst-Action-Firebug-0.01-alt1.noarch.rpm Catalyst action for embedding Firebug Lite tag
perl-Catalyst-Action-Fixup-XHTML-0.05-alt1.noarch.rpm Catalyst action which serves application/xhtml+xml content if the browser accepts it
perl-Catalyst-Action-FromPSGI-0.001006-alt1.noarch.rpm Use a PSGI app as a Catalyst action
perl-Catalyst-Action-REST-1.21-alt1_4.noarch.rpm Automated REST Method Dispatching
perl-Catalyst-Action-RenderView-ErrorHandler-0.100166-alt1.noarch.rpm Custom errorhandling in deployed applications
perl-Catalyst-Action-RenderView-ErrorHandler-Action-Email-0.04-alt1.noarch.rpm Catalyst ErrorHandler Action for Email
perl-Catalyst-Action-Serialize-SimpleExcel-0.015-alt1.noarch.rpm Serialize to Excel files
Advertisement
Advertisement