| 1 | package VFS::File; | ||||||||||
| 2 | |||||||||||
| 3 | 1 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 1 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | |||||||||||
| 6 | 0 | ▶ | sub new { | ||||||||
|
Subroutine
new: not called CC=2 SCAR=17.9
Pod
undocumented
| |||||||||||
| 7 | 0 | my $class = shift; | |||||||||
| 8 | 0 | ▶ | my $self = ($#_ == 0) ? { %{ (shift) } } : { @_ }; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 9 | 0 | return bless $self, $class; | |||||||||
| 10 | } | ||||||||||
| 11 | |||||||||||
| 12 | 0 | ▶ | sub commit { | ||||||||
|
Subroutine
commit: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 13 | 0 | die "Commit called on basic file object - subclass this!"; | |||||||||
| 14 | } | ||||||||||
| 15 | |||||||||||
| 16 | 0 | ▶ | sub read { | ||||||||
|
Subroutine
read: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 17 | 0 | my ($self) = @_; | |||||||||
| 18 | 0 | return ""; | |||||||||
| 19 | } | ||||||||||
| 20 | |||||||||||
| 21 | 0 | ▶ | sub write { | ||||||||
|
Subroutine
write: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 22 | 0 | my ($self, $data) = @_; | |||||||||
| 23 | 0 | $self->{Data} = $data; | |||||||||
| 24 | 0 | $self->commit; # Should update version. | |||||||||
| 25 | 0 | return 1; | |||||||||
| 26 | } | ||||||||||
| 27 | |||||||||||
| 28 | 1 | 1; | |||||||||
| 29 | __END__ | ||||||||||