| 1 | package TeX::AutoTeX::Fileset; | ||||||||||||||||||||
| 2 | |||||||||||||||||||||
| 3 | # | ||||||||||||||||||||
| 4 | # $Id: Fileset.pm,v 1.8.2.4 2011/01/03 04:06:00 thorstens Exp $ | ||||||||||||||||||||
| 5 | # $Revision: 1.8.2.4 $ | ||||||||||||||||||||
| 6 | # $Source: /cvsroot/arxivlib/arXivLib/lib/TeX/AutoTeX/Fileset.pm,v $ | ||||||||||||||||||||
| 7 | # | ||||||||||||||||||||
| 8 | # $Date: 2011/01/03 04:06:00 $ | ||||||||||||||||||||
| 9 | # $Author: thorstens $ | ||||||||||||||||||||
| 10 | # | ||||||||||||||||||||
| 11 | |||||||||||||||||||||
| 12 | 2 | ▶ | use strict; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 13 | ### use warnings; | ||||||||||||||||||||
| 14 | 2 | ▶ | use Carp; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 15 | |||||||||||||||||||||
| 16 | 2 | our ($VERSION) = '$Revision: 1.8.2.4 $' =~ m{ \$Revision: \s+ (\S+) }x; | |||||||||||||||||||
| 17 | |||||||||||||||||||||
| 18 | 2 | ▶ | use TeX::AutoTeX::File; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 19 | |||||||||||||||||||||
| 20 | 0 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: not called CC=4 SCAR=30.0
Pod
documented
| |||||||||||||||||||||
| 21 | 0 | my $that = shift; | |||||||||||||||||||
| 22 | 0 | ▶ | my $class = ref($that) || $that; | ||||||||||||||||||
|
Condition0%0/3
ref $that || $that
MC/DC0%0/2
ref $that || $that
ref $that
$that
Truth table0%0/3
A || B
A= ref $thatB= $that
| |||||||||||||||||||||
| 23 | 0 | my $self = { | |||||||||||||||||||
| 24 | log => undef, | ||||||||||||||||||||
| 25 | dir => undef, | ||||||||||||||||||||
| 26 | cache => {}, | ||||||||||||||||||||
| 27 | local_hyper_transform => undef, | ||||||||||||||||||||
| 28 | override => { | ||||||||||||||||||||
| 29 | ignore => 'TYPE_IGNORE', | ||||||||||||||||||||
| 30 | include => 'TYPE_INCLUDE', | ||||||||||||||||||||
| 31 | }, | ||||||||||||||||||||
| 32 | @_ | ||||||||||||||||||||
| 33 | }; | ||||||||||||||||||||
| 34 | 0 | ▶ | if (!defined $self->{log}) { | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 35 | 0 | throw TeX::AutoTeX::FatalException 'No log configuration supplied'; | |||||||||||||||||||
| 36 | } | ||||||||||||||||||||
| 37 | 0 | ▶ | if (!defined $self->{dir}) { | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 38 | 0 | throw TeX::AutoTeX::FatalException 'No directory specified'; | |||||||||||||||||||
| 39 | } | ||||||||||||||||||||
| 40 | 0 | bless $self, $class; | |||||||||||||||||||
| 41 | } | ||||||||||||||||||||
| 42 | |||||||||||||||||||||
| 43 | 0 | ▶ | sub new_File { | ||||||||||||||||||
|
Subroutine
new_File: not called CC=3 SCAR=24.8
Pod
documented
| |||||||||||||||||||||
| 44 | 0 | my ($self, $filename) = @_; | |||||||||||||||||||
| 45 | |||||||||||||||||||||
| 46 | 0 | ▶ | if (!defined $filename) { | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 47 | 0 | throw TeX::AutoTeX::FatalException 'no filename provided to new_File()'; | |||||||||||||||||||
| 48 | } | ||||||||||||||||||||
| 49 | 0 | ▶ | if ($self->{cache}->{$filename}) { | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 50 | 0 | return $self->{cache}->{$filename}; | |||||||||||||||||||
| 51 | } | ||||||||||||||||||||
| 52 | 0 | $self->{cache}->{$filename} = TeX::AutoTeX::File->new($self, $filename); | |||||||||||||||||||
| 53 | } | ||||||||||||||||||||
| 54 | |||||||||||||||||||||
| 55 | 0 | ▶ | sub override { | ||||||||||||||||||
|
Subroutine
override: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||||||||||||
| 56 | 0 | my ($self, $type) = @_; | |||||||||||||||||||
| 57 | 0 | return $self->{override}->{$type}; | |||||||||||||||||||
| 58 | } | ||||||||||||||||||||
| 59 | |||||||||||||||||||||
| 60 | 2 | 1; | |||||||||||||||||||
| 61 | |||||||||||||||||||||
| 62 | __END__ | ||||||||||||||||||||