ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/SCRAM/src/BuildSystem/ToolMap.pm
Revision: 1.4
Committed: Tue Nov 14 15:18:42 2000 UTC (24 years, 5 months ago) by williamc
Content type: text/plain
Branch: MAIN
CVS Tags: V0_19_7, V0_19_6, V0_19_6p1, V0_19_5, SFATEST, V0_19_4, V0_19_4_pre3, V0_19_4_pre2, V0_19_4_pre1, V0_19_3, V0_19_2, V0_19_1, V0_19_0, V0_18_5, V0_18_4, V_18_3_TEST, VO_18_3, V0_18_2, V0_18_1
Branch point for: SCRAM_V1_BRANCH, V0_19_4_B
Changes since 1.3: +4 -5 lines
Log Message:
imported

File Contents

# User Rev Content
1 williamc 1.2 #
2     # ToolMap.pm
3     #
4     # Originally Written by Christopher Williams
5     #
6     # Description
7     # -----------
8     # Object to describe build transformations
9     #
10     # Interface
11     # ---------
12     # new() : A new ToolMapper object
13     # name() : the name of the toolmap
14     # types() : Return the types
15     # cleardefaults() : clear the default set
16 williamc 1.4 # defaulttypes() : return list of types to make the default
17 williamc 1.2 # rulesfile() : return list of names of makefiles to include to describe
18     # suitable make rules
19    
20     package BuildSystem::ToolMap;
21     require 5.004;
22    
23     sub new {
24     my $class=shift;
25     $self={};
26     bless $self, $class;
27     return $self;
28     }
29    
30     sub name {
31     my $self=shift;
32     if ( @_ ) {
33     $self->{name}=shift;
34     }
35     return $self->{name};
36     }
37    
38     sub types {
39     my $self=shift;
40     if ( @_ ) {
41     push @{$self->{types}}, @_;
42     }
43 williamc 1.4 return $self->{types};
44 williamc 1.2 }
45    
46     sub defaulttypes {
47     my $self=shift;
48     if ( @_ ) {
49     push @{$self->{defaulttypes}}, @_;
50     }
51 williamc 1.4 return $self->{defaulttypes};
52 williamc 1.2 }
53    
54     sub rulesfile {
55     my $self=shift;
56     if ( @_ ) {
57     push @{$self->{rulesfile}}, @_;
58     }
59 williamc 1.4 return $self->{rulesfile};
60 williamc 1.2 }
61    
62     sub cleardefaults {
63     my $self;
64     $self->{defaulttypes}=();
65     }
66    
67     # -- Support routines
68     sub init {
69     }