Initial commit of OpenSPARC T2 design and verification files.
[OpenSPARC-T2-DV] / tools / perl-5.8.0 / lib / site_perl / 5.8.0 / Pastel / Root.pm
CommitLineData
86530b38
AT
1# Perl module for Pastel::Root
2# Author: Malay < curiouser@ccmp.ap.nic.in >
3# Copyright Malay
4# You may distribute this module under the same terms as perl itself
5
6# POD documentation - main docs before the code
7
8=head1 NAME
9
10Pastel::Root - Root class for Pastel library the constructor new in inherited by all Pastel classes. All the initialization is done by the _init() function of each class.
11
12=head1 SYNOPSIS
13
14This is an virtual base class and not to instantiated directly.
15
16=head1 DESCRIPTION
17
18This class is a virtual base class. The new in inherited in all the classes. This class is not to be instantiated directly. Look into the individual classes in the library for the constructor call.
19
20=head1 CONTACT
21
22Malay <curiouser@ccmb.ap.nic.in>
23
24=cut
25
26# Let the code begin...
27
28
29package Pastel::Root;
30@ISA = qw (Pastel::Mixin::Mixin); # Get the _rearrange function
31use Pastel::Mixin::Mixin;
32
33use strict;
34
35sub new {
36 my $class = shift;
37 my $self = {};
38 bless $self, ref($class) || $class;
39 $self->_init(@_); # Call the _init() function of the caller
40 return $self;
41}
42
43sub DESTROY {
44 my $self = shift;
45 foreach my $key (keys %{$self}){
46 delete $self->{$key};
47 }
48 }
49
501;