Venus::Fault

Fault Class

Fault Class for Perl 5

method: explain method: frames method: throw method: trace

package main;

use Venus::Fault;

my $fault = Venus::Fault->new;

# $fault->throw;

This package represents a generic system error (exception object).

The explain method returns the error message and is used in stringification operations.

explain() (string)

{ since => '1.80', }

=example-1 explain

# given: synopsis;

my $explain = $fault->explain;

# "Exception! in ...

The frames method returns the compiled and stashed stack trace data.

frames() (arrayref)

{ since => '1.80', }

=example-1 frames

# given: synopsis;

my $frames = $fault->frames;

# [
#   ...
#   [
#     "main",
#     "t/Venus_Fault.t",
#     ...
#   ],
# ]

The throw method throws an error if the invocant is an object, or creates an error object using the arguments provided and throws the created object.

throw(string $message) (Venus::Fault)

{ since => '1.80', }

=example-1 throw

# given: synopsis;

my $throw = $fault->throw;

# bless({ ... }, 'Venus::Fault')

The trace method compiles a stack trace and returns the object. By default it skips the first frame.

trace(number $offset, number $limit) (Venus::Fault)

{ since => '1.80', }

=example-1 trace

# given: synopsis;

my $trace = $fault->trace;

# bless({ ... }, 'Venus::Fault')

This package overloads the eq operator.

This package overloads the ne operator.

This package overloads the qr operator.

This package overloads the "" operator.

This package overloads the ~~ operator.

t/Venus.t: present: authors t/Venus.t: present: license

31 POD Errors

The following errors were encountered while parsing the POD:

Around line 14:

Unknown directive: =name

Around line 22:

Unknown directive: =tagline

Around line 30:

Unknown directive: =abstract

Around line 38:

Unknown directive: =includes

Around line 49:

Unknown directive: =synopsis

Around line 68:

Unknown directive: =description

Around line 76:

Unknown directive: =method

Around line 81:

Unknown directive: =signature

Around line 85:

Unknown directive: =metadata

Around line 109:

Unknown directive: =method

Around line 113:

Unknown directive: =signature

Around line 117:

Unknown directive: =metadata

Around line 150:

Unknown directive: =method

Around line 155:

Unknown directive: =signature

Around line 159:

Unknown directive: =metadata

Around line 183:

Unknown directive: =method

Around line 188:

Unknown directive: =signature

Around line 192:

Unknown directive: =metadata

Around line 225:

=cut found outside a pod block. Skipping to next block.

Around line 244:

=cut found outside a pod block. Skipping to next block.

Around line 255:

Unknown directive: =operator

Around line 271:

=cut found outside a pod block. Skipping to next block.

Around line 281:

Unknown directive: =operator

Around line 297:

=cut found outside a pod block. Skipping to next block.

Around line 307:

Unknown directive: =operator

Around line 323:

=cut found outside a pod block. Skipping to next block.

Around line 333:

Unknown directive: =operator

Around line 349:

=cut found outside a pod block. Skipping to next block.

Around line 359:

Unknown directive: =operator

Around line 375:

=cut found outside a pod block. Skipping to next block.

Around line 381:

Unknown directive: =partials