Venus::Box

Box Class

Box Class for Perl 5

method: new method: unbox

package main;

use Venus::Box;

my $box = Venus::Box->new(
  value => {},
);

# $box->keys->count->unbox;

This package provides a pure Perl boxing mechanism for wrapping objects and values, and chaining method calls across all objects.

Venus::Role::Buildable Venus::Role::Proxyable

The new method constructs an instance of the package.

new(any @args) (Venus::Box)

{ since => '4.15', }

The unbox method returns the un-boxed underlying object. This is a virtual method that dispatches to __handle__unbox. This method supports dispatching, i.e. providing a method name and arguments whose return value will be acted on by this method.

unbox(string $method, any @args) (any)

{ since => '0.01', }

=example-1 unbox

# given: synopsis;

my $unbox = $box->unbox;

# bless({ value => {} }, "Venus::Hash")

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

18 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 47:

Unknown directive: =synopsis

Around line 69:

Unknown directive: =description

Around line 78:

Unknown directive: =integrates

Around line 87:

Unknown directive: =method

Around line 91:

Unknown directive: =signature

Around line 95:

Unknown directive: =metadata

Around line 113:

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

Around line 133:

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

Around line 155:

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

Around line 167:

Unknown directive: =method

Around line 174:

Unknown directive: =signature

Around line 178:

Unknown directive: =metadata

Around line 210:

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

Around line 220:

Unknown directive: =partials