Venus::Fault
Fault Class
Fault Class for Perl 5
method: explain method: frames method: new 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 new method constructs an instance of the package.
new(any @args) (Venus::Fault)
{ since => '4.15', }
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
36 POD Errors
The following errors were encountered while parsing the POD:
- Around line 15:
Unknown directive: =name
- Around line 23:
Unknown directive: =tagline
- Around line 31:
Unknown directive: =abstract
- Around line 39:
Unknown directive: =includes
- Around line 51:
Unknown directive: =synopsis
- Around line 70:
Unknown directive: =description
- Around line 78:
Unknown directive: =method
- Around line 83:
Unknown directive: =signature
- Around line 87:
Unknown directive: =metadata
- Around line 111:
Unknown directive: =method
- Around line 115:
Unknown directive: =signature
- Around line 119:
Unknown directive: =metadata
- Around line 152:
Unknown directive: =method
- Around line 156:
Unknown directive: =signature
- Around line 160:
Unknown directive: =metadata
- Around line 178:
=cut found outside a pod block. Skipping to next block.
- Around line 198:
=cut found outside a pod block. Skipping to next block.
- Around line 209:
Unknown directive: =method
- Around line 214:
Unknown directive: =signature
- Around line 218:
Unknown directive: =metadata
- Around line 242:
Unknown directive: =method
- Around line 247:
Unknown directive: =signature
- Around line 251:
Unknown directive: =metadata
- Around line 284:
=cut found outside a pod block. Skipping to next block.
- Around line 303:
=cut found outside a pod block. Skipping to next block.
- Around line 314:
Unknown directive: =operator
- Around line 330:
=cut found outside a pod block. Skipping to next block.
- Around line 340:
Unknown directive: =operator
- Around line 356:
=cut found outside a pod block. Skipping to next block.
- Around line 366:
Unknown directive: =operator
- Around line 382:
=cut found outside a pod block. Skipping to next block.
- Around line 392:
Unknown directive: =operator
- Around line 408:
=cut found outside a pod block. Skipping to next block.
- Around line 418:
Unknown directive: =operator
- Around line 434:
=cut found outside a pod block. Skipping to next block.
- Around line 440:
Unknown directive: =partials