line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# Copyright 2014-2016 - Giovanni Simoni |
2
|
|
|
|
|
|
|
# |
3
|
|
|
|
|
|
|
# This file is part of PFT. |
4
|
|
|
|
|
|
|
# |
5
|
|
|
|
|
|
|
# PFT is free software: you can redistribute it and/or modify it under the |
6
|
|
|
|
|
|
|
# terms of the GNU General Public License as published by the Free |
7
|
|
|
|
|
|
|
# Software Foundation, either version 3 of the License, or (at your |
8
|
|
|
|
|
|
|
# option) any later version. |
9
|
|
|
|
|
|
|
# |
10
|
|
|
|
|
|
|
# PFT is distributed in the hope that it will be useful, but WITHOUT ANY |
11
|
|
|
|
|
|
|
# WARRANTY; without even the implied warranty of MERCHANTABILITY or |
12
|
|
|
|
|
|
|
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
13
|
|
|
|
|
|
|
# for more details. |
14
|
|
|
|
|
|
|
# |
15
|
|
|
|
|
|
|
# You should have received a copy of the GNU General Public License along |
16
|
|
|
|
|
|
|
# with PFT. If not, see . |
17
|
|
|
|
|
|
|
# |
18
|
|
|
|
|
|
|
package PFT::Content::Attachment v1.4.1; |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=encoding utf8 |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
=head1 NAME |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
PFT::Content::Attachment - Binary attachment |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
=head1 SYNOPSIS |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
use PFT::Content::Attachment; |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
my $f1 = PFT::Content::Attachment->new({ |
31
|
|
|
|
|
|
|
tree => $tree, |
32
|
|
|
|
|
|
|
path => $path, |
33
|
|
|
|
|
|
|
name => $name, # optional, defaults to basename($path) |
34
|
|
|
|
|
|
|
}); |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=head1 DESCRIPTION |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
Extends C. |
39
|
|
|
|
|
|
|
Retains the same interface. |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=cut |
42
|
|
|
|
|
|
|
|
43
|
5
|
|
|
5
|
|
39
|
use utf8; |
|
5
|
|
|
|
|
10
|
|
|
5
|
|
|
|
|
29
|
|
44
|
5
|
|
|
5
|
|
183
|
use v5.16; |
|
5
|
|
|
|
|
18
|
|
45
|
5
|
|
|
5
|
|
26
|
use strict; |
|
5
|
|
|
|
|
16
|
|
|
5
|
|
|
|
|
109
|
|
46
|
5
|
|
|
5
|
|
51
|
use warnings; |
|
5
|
|
|
|
|
13
|
|
|
5
|
|
|
|
|
197
|
|
47
|
|
|
|
|
|
|
|
48
|
5
|
|
|
5
|
|
1285
|
use parent 'PFT::Content::Blob'; |
|
5
|
|
|
|
|
964
|
|
|
5
|
|
|
|
|
28
|
|
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
1 |