line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Protocol::SPDY::Frame::Control::WINDOW_UPDATE; |
2
|
|
|
|
|
|
|
$Protocol::SPDY::Frame::Control::WINDOW_UPDATE::VERSION = '1.001'; |
3
|
3
|
|
|
3
|
|
12
|
use strict; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
92
|
|
4
|
3
|
|
|
3
|
|
12
|
use warnings; |
|
3
|
|
|
|
|
3
|
|
|
3
|
|
|
|
|
74
|
|
5
|
3
|
|
|
3
|
|
8
|
use parent qw(Protocol::SPDY::Frame::Control); |
|
3
|
|
|
|
|
3
|
|
|
3
|
|
|
|
|
10
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=head1 NAME |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
Protocol::SPDY::Frame::Control::SynStream - stream creation request packet for SPDY protocol |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
=head1 VERSION |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
version 1.001 |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=head1 SYNOPSIS |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
=head1 DESCRIPTION |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
See L and L. |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
=cut |
22
|
|
|
|
|
|
|
|
23
|
3
|
|
|
3
|
|
180
|
use Protocol::SPDY::Constants ':all'; |
|
3
|
|
|
|
|
3
|
|
|
3
|
|
|
|
|
1090
|
|
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
=head2 type_name |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
The string type for this frame ('WINDOW_UPDATE'). |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
=cut |
30
|
|
|
|
|
|
|
|
31
|
0
|
|
|
0
|
1
|
|
sub type_name { 'WINDOW_UPDATE' } |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
=head2 from_data |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
Instantiate from the given data. |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
=cut |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
sub from_data { |
40
|
0
|
|
|
0
|
1
|
|
my $class = shift; |
41
|
0
|
|
|
|
|
|
my %args = @_; |
42
|
0
|
|
|
|
|
|
my ($stream_id, $window_delta) = unpack "N1N1", substr $args{data}, 0, 8, ''; |
43
|
0
|
|
|
|
|
|
$stream_id &= ~0x80000000; |
44
|
0
|
|
|
|
|
|
$window_delta &= ~0x80000000; |
45
|
|
|
|
|
|
|
|
46
|
0
|
|
|
|
|
|
$class->new( |
47
|
|
|
|
|
|
|
%args, |
48
|
|
|
|
|
|
|
stream_id => $stream_id, |
49
|
|
|
|
|
|
|
window_delta => $window_delta, |
50
|
|
|
|
|
|
|
); |
51
|
|
|
|
|
|
|
} |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=head2 stream_id |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
Which stream we're updating the window for. |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=cut |
58
|
|
|
|
|
|
|
|
59
|
0
|
|
|
0
|
1
|
|
sub stream_id { shift->{stream_id} } |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head2 window_delta |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Change in window size (always positive). |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=cut |
66
|
|
|
|
|
|
|
|
67
|
0
|
|
|
0
|
1
|
|
sub window_delta { shift->{window_delta} } |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=head2 as_packet |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
Returns byte representation for this frame. |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=cut |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
sub as_packet { |
76
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
77
|
0
|
|
|
|
|
|
my $payload = pack 'N1N1', $self->stream_id & ~0x80000000, $self->window_delta & ~0x80000000; |
78
|
0
|
|
|
|
|
|
return $self->SUPER::as_packet( |
79
|
|
|
|
|
|
|
payload => $payload, |
80
|
|
|
|
|
|
|
); |
81
|
|
|
|
|
|
|
} |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
=head2 to_string |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
String representation, for debugging. |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
=cut |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
sub to_string { |
90
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
91
|
0
|
|
|
|
|
|
$self->SUPER::to_string . ', stream ' . $self->stream_id . ', delta ' . $self->window_delta; |
92
|
|
|
|
|
|
|
} |
93
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
1; |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
__END__ |