line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package PLS::Server::Request::Workspace::ApplyEdit; |
2
|
|
|
|
|
|
|
|
3
|
9
|
|
|
9
|
|
110
|
use strict; |
|
9
|
|
|
|
|
17
|
|
|
9
|
|
|
|
|
229
|
|
4
|
9
|
|
|
9
|
|
46
|
use warnings; |
|
9
|
|
|
|
|
18
|
|
|
9
|
|
|
|
|
202
|
|
5
|
|
|
|
|
|
|
|
6
|
9
|
|
|
9
|
|
45
|
use parent 'PLS::Server::Request'; |
|
9
|
|
|
|
|
18
|
|
|
9
|
|
|
|
|
51
|
|
7
|
|
|
|
|
|
|
|
8
|
9
|
|
|
9
|
|
405
|
use URI; |
|
9
|
|
|
|
|
18
|
|
|
9
|
|
|
|
|
1302
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 NAME |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
PLS::Server::Request::Workspace::ApplyEdit |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
=head1 DESCRIPTION |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
This is a message from the server to the client requesting that |
17
|
|
|
|
|
|
|
an edit be made to one or more sections of one or more documents. |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
=cut |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub new |
22
|
|
|
|
|
|
|
{ |
23
|
0
|
|
|
0
|
0
|
|
my ($class, %args) = @_; |
24
|
|
|
|
|
|
|
|
25
|
0
|
|
|
|
|
|
my $uri = URI::file->new($args{path})->as_string; |
26
|
0
|
|
|
|
|
|
my $text = $args{text}; |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
my $self = { |
29
|
|
|
|
|
|
|
method => 'workspace/applyEdit', |
30
|
|
|
|
|
|
|
params => { |
31
|
|
|
|
|
|
|
edit => { |
32
|
|
|
|
|
|
|
changes => { |
33
|
|
|
|
|
|
|
$uri => [ |
34
|
|
|
|
|
|
|
{ |
35
|
|
|
|
|
|
|
range => { |
36
|
|
|
|
|
|
|
start => {line => 0, character => 0}, |
37
|
0
|
|
|
|
|
|
end => {line => $args{lines}, character => 0} |
38
|
|
|
|
|
|
|
}, |
39
|
|
|
|
|
|
|
newText => $$text |
40
|
|
|
|
|
|
|
} |
41
|
|
|
|
|
|
|
] |
42
|
|
|
|
|
|
|
} |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
}; |
46
|
|
|
|
|
|
|
|
47
|
0
|
|
|
|
|
|
return bless $self, $class; |
48
|
|
|
|
|
|
|
} ## end sub new |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
1; |