ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/SCRAM/src/BuildSystem/BuildReport.pm
Revision: 1.2
Committed: Wed Sep 13 11:17:15 2000 UTC (24 years, 7 months ago) by williamc
Content type: text/plain
Branch: MAIN
Changes since 1.1: +5 -5 lines
Log Message:
Use status rather than pass

File Contents

# User Rev Content
1 williamc 1.1 #
2     # BuildReport.pm
3     #
4     # Originally Written by Christopher Williams
5     #
6     # Description
7     #
8     # Interface
9     # ---------
10     # new() : A new BuildReport object
11 williamc 1.2 # status() : Build exit status
12 williamc 1.1 # error([message]) : Add an error message - set pass to fail, return message
13     # list
14    
15     package BuildSystem::BuildReport;
16     require 5.004;
17    
18     sub new {
19     my $class=shift;
20     my $self={};
21     bless $self, $class;
22     return $self;
23     }
24    
25 williamc 1.2 sub status {
26 williamc 1.1 my $self=shift;
27     if ( @_ ) {
28 williamc 1.2 $self->{status}=shift;
29 williamc 1.1 }
30 williamc 1.2 return $self->{status};
31 williamc 1.1 }
32    
33     sub error {
34     my $self=shift;
35 williamc 1.2 $self->{status}=1;
36 williamc 1.1 if ( @_ ) {
37     push @{$self->{message}}, shift;
38     }
39     return @{$self->{message}};
40     }