Name

Class::Plain::Base - Provide Constructor

Description

This module provides a constructor new.

Class Methods

new

my $object = Class::Plain::Base->new(%args);

my $object = Class::Plain::Base->new(\%args);

Create a new object. The implementation is the following.

sub new {
  my $class = shift;
  
  my $self = ref $_[0] ? {%{$_[0]}} : {@_};
  
  bless $self, ref $class || $class;
}