line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Plack::Middleware::XFramework; |
2
|
7
|
|
|
7
|
|
89519
|
use strict; |
|
7
|
|
|
|
|
18
|
|
|
7
|
|
|
|
|
213
|
|
3
|
7
|
|
|
7
|
|
36
|
use warnings; |
|
7
|
|
|
|
|
13
|
|
|
7
|
|
|
|
|
228
|
|
4
|
7
|
|
|
7
|
|
88
|
use parent qw/Plack::Middleware/; |
|
7
|
|
|
|
|
11
|
|
|
7
|
|
|
|
|
53
|
|
5
|
|
|
|
|
|
|
|
6
|
7
|
|
|
7
|
|
455
|
use Plack::Util; |
|
7
|
|
|
|
|
14
|
|
|
7
|
|
|
|
|
181
|
|
7
|
7
|
|
|
7
|
|
48
|
use Plack::Util::Accessor qw( framework ); |
|
7
|
|
|
|
|
12
|
|
|
7
|
|
|
|
|
47
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub call { |
10
|
11
|
|
|
11
|
1
|
35
|
my $self = shift; |
11
|
|
|
|
|
|
|
|
12
|
11
|
|
|
|
|
63
|
my $res = $self->app->( @_ ); |
13
|
|
|
|
|
|
|
$self->response_cb($res, sub { |
14
|
11
|
|
|
11
|
|
24
|
my $res = shift; |
15
|
11
|
50
|
|
|
|
44
|
if ($self->framework) { |
16
|
11
|
|
|
|
|
39
|
Plack::Util::header_set $res->[1], 'X-Framework' => $self->framework; |
17
|
|
|
|
|
|
|
} |
18
|
11
|
|
|
|
|
164
|
}); |
19
|
|
|
|
|
|
|
} |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
1; |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
__END__ |