blib/lib/WebForms.pm

filter: Statementstmt 32.6% 743 / 2275 Branchbran 0.0% 0 / 922 Conditioncond 0.0% 0 / 248 MC/DCmcdc 0.0% 0 / 142 Subroutinesub 35.3% 250 / 707 Podpod 0.0% 0 / 366 totaltotal 21.3% 993 / 4660 CC 549 SCAR 30.7
CC
549
Cov
22%
confirm_is_true_accept
182.0
confirm_is_false_accept
182.0
assign_confirm_event
132.0
CRAP 21.5
↑ Summary
1 ÿþ# WebForms.pm 2.1.1 - The Back-End Part of WebForms Core Technology, Owned by Elanat (https://elanat.net)
2 # Compatible with WebFormsJS version 2.1
3
4 package WebForms;
5 1 our $VERSION = '2.1.1';
6 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
9
10 1 ▶use constant GS => chr(29);
Subroutine BEGIN: called CC=1 SCAR=0.0
11 1 ▶use constant US => chr(31);
Subroutine BEGIN: called CC=1 SCAR=0.0
12
13 0 ▶sub new {
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
14 0 my ($class) = @_;
15 0 my $self = {
16 web_forms_data => "",
17 };
18 0 bless $self, $class;
19 0 return $self;
20 }
21
22 0 ▶sub _add {
Subroutine _add: not called CC=4 SCAR=30.0
23 0 my ($self, $name, $value) = @_;
24 0 ▶ if (length($self->{web_forms_data}) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (length $self->{"web_forms_data"} > 0) 0 0 0
25 0 $self->{web_forms_data} .= "\n";
26 }
27 0 $self->{web_forms_data} .= $name;
28 0 ▶ if (@_ > 2) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ > 2) 0 0 0
29 0 ▶ $self->{web_forms_data} .= "=" . (defined $value ? $value : "");
Branch: 1 branch
BranchTrueFalseTotal
defined $value ? : 0 0 0
30 }
31 }
32
33 0 ▶sub _add_to_up {
Subroutine _add_to_up: not called CC=3 SCAR=24.8
34 0 my ($self, $name, $value) = @_;
35 0 ▶ my $line = defined $value ? "$name=$value" : $name;
Branch: 1 branch
BranchTrueFalseTotal
defined $value ? : 0 0 0
36 0 ▶ if (length($self->{web_forms_data}) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (length $self->{"web_forms_data"} > 0) 0 0 0
37 0 $line .= "\n";
38 }
39 0 $self->{web_forms_data} = $line . $self->{web_forms_data};
40 }
41
42 0 ▶sub _get_line_by_index {
Subroutine _get_line_by_index: not called CC=5 SCAR=34.0
43 0 my ($self, $index) = @_;
44 0 ▶ return "" if length($self->{web_forms_data}) == 0;
Branch: 1 branch
BranchTrueFalseTotal
if length $self->{"web_forms_data"} == 0 0 0 0
45 0 my @lines = split(/\n/, $self->{web_forms_data}, -1);
46 0 ▶ $index = scalar(@lines) + $index if $index < 0;
Branch: 1 branch
BranchTrueFalseTotal
if $index < 0 0 0 0
47 0 ▶ return "" if $index < 0 || $index >= scalar(@lines);
Branch: 1 branch
BranchTrueFalseTotal
if $index < 0 or $index >= scalar @lines 0 0 0
Condition0%0/3
$index < 0 or $index >= scalar @lines
l!l&&r!l&&!r
000
MC/DC0%0/2
$index < 0 or $index >= scalar @lines
$index < 0 $index >= scalar @lines
Truth table0%0/3
A or B
A= $index < 0B= $index >= scalar @lines
ABresult
1X1
011
000
48 0 return $lines[$index];
49 }
50
51 0 ▶sub _update_line_by_index {
Subroutine _update_line_by_index: not called CC=7 SCAR=40.3
52 0 my ($self, $index, $name, $value) = @_;
53 0 ▶ return if length($self->{web_forms_data}) == 0;
Branch: 1 branch
BranchTrueFalseTotal
if length $self->{"web_forms_data"} == 0 0 0 0
54 0 my @lines = split(/\n/, $self->{web_forms_data}, -1);
55 0 ▶ $index = scalar(@lines) + $index if $index < 0;
Branch: 1 branch
BranchTrueFalseTotal
if $index < 0 0 0 0
56 0 ▶ return if $index < 0 || $index >= scalar(@lines);
Branch: 1 branch
BranchTrueFalseTotal
if $index < 0 or $index >= scalar @lines 0 0 0
Condition0%0/3
$index < 0 or $index >= scalar @lines
l!l&&r!l&&!r
000
MC/DC0%0/2
$index < 0 or $index >= scalar @lines
$index < 0 $index >= scalar @lines
Truth table0%0/3
A or B
A= $index < 0B= $index >= scalar @lines
ABresult
1X1
011
000
57 0 ▶ $lines[$index] = $name . (!defined($value) || $value eq '' ? "" : "=" . $value);
Branch: 1 branch
BranchTrueFalseTotal
!defined($value) || $value eq '' ? : 0 0 0
Condition0%0/3
not defined $value or $value eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $value or $value eq ""
not defined $value $value eq ""
Truth table0%0/3
not(A) or B
A= not defined $valueB= $value eq ""
ABresult
1X1
011
000
58 0 $self->{web_forms_data} = join("\n", @lines);
59 }
60
61 # For Extension
62 0 ▶sub add_line {
Subroutine add_line: not called CC=1 SCAR=6.9
Pod undocumented
63 0 my ($self, $name, $value) = @_;
64 0 $self->_add($name, $value);
65 }
66
67 # Add
68 # Creates the Data if it does not exist; otherwise, Appends the New Value to the Existing Value.
69 0 ▶sub add_id {
Subroutine add_id: not called CC=1 SCAR=6.9
Pod undocumented
70 0 my ($self, $input_place, $id) = @_;
71 0 $self->_add("ai" . $input_place, $id);
72 }
73
74 0 ▶sub add_name {
Subroutine add_name: not called CC=1 SCAR=6.9
Pod undocumented
75 0 my ($self, $input_place, $name) = @_;
76 0 $self->_add("an" . $input_place, $name);
77 }
78
79 0 ▶sub add_value {
Subroutine add_value: not called CC=1 SCAR=6.9
Pod undocumented
80 0 my ($self, $input_place, $value) = @_;
81 0 $self->_add("av" . $input_place, $value);
82 }
83
84 0 ▶sub add_class {
Subroutine add_class: not called CC=1 SCAR=6.9
Pod undocumented
85 0 my ($self, $input_place, $class) = @_;
86 0 $self->_add("ac" . $input_place, $class);
87 }
88
89 0 ▶sub add_style {
Subroutine add_style: not called CC=2 SCAR=17.9
Pod undocumented
90 0 my ($self, $input_place, $name_or_style, $value) = @_;
91 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
92 0 $self->_add("as" . $input_place, $name_or_style);
93 } else {
94 0 $self->_add("as" . $input_place, $name_or_style . ':' . $value);
95 }
96 }
97
98 0 ▶sub add_option_tag {
Subroutine add_option_tag: not called CC=3 SCAR=24.8
Pod undocumented
99 0 my ($self, $input_place, $text, $value, $selected) = @_;
100 0 ▶ $selected = 0 if !defined $selected;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $selected 0 0 0
101 0 ▶ $self->_add("ao" . $input_place, $value . GS . $text . ($selected ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$selected ? : 0 0 0
102 }
103
104 0 ▶sub add_check_box_tag {
Subroutine add_check_box_tag: not called CC=3 SCAR=24.8
Pod undocumented
105 0 my ($self, $input_place, $text, $value, $checked) = @_;
106 0 ▶ $checked = 0 if !defined $checked;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $checked 0 0 0
107 0 ▶ $self->_add("ak" . $input_place, $value . GS . $text . ($checked ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$checked ? : 0 0 0
108 }
109
110 0 ▶sub add_title {
Subroutine add_title: not called CC=1 SCAR=6.9
Pod undocumented
111 0 my ($self, $input_place, $title) = @_;
112 0 $self->_add("al" . $input_place, $title);
113 }
114
115 0 ▶sub add_label {
Subroutine add_label: not called CC=1 SCAR=6.9
Pod undocumented
116 0 my ($self, $input_place, $label) = @_;
117 0 $self->_add("aA" . $input_place, $label);
118 }
119
120 0 ▶sub add_text {
Subroutine add_text: not called CC=1 SCAR=6.9
Pod undocumented
121 0 my ($self, $input_place, $text) = @_;
122 0 $text =~ s/\n/\$[ln];/g;
123 0 $self->_add("at" . $input_place, $text);
124 }
125
126 0 ▶sub add_text_to_up {
Subroutine add_text_to_up: not called CC=1 SCAR=6.9
Pod undocumented
127 0 my ($self, $input_place, $text) = @_;
128 0 $text =~ s/\n/\$[ln];/g;
129 0 $self->_add("pt" . $input_place, $text);
130 }
131
132 0 ▶sub add_attribute {
Subroutine add_attribute: not called CC=5 SCAR=34.0
Pod undocumented
133 0 my ($self, $input_place, $attribute, $value, $splitter) = @_;
134 0 ▶ $value = "" if !defined $value;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $value 0 0 0
135 0 ▶ $splitter = "\0" if !defined $splitter;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $splitter 0 0 0
136 0 ▶ my $splitter_str = ($splitter ne "\0") ? $splitter : "";
Branch: 1 branch
BranchTrueFalseTotal
$splitter ne "\000" ? : 0 0 0
137 0 ▶ my $value_part = ($value ne "") ? GS . $value : "";
Branch: 1 branch
BranchTrueFalseTotal
$value ne '' ? : 0 0 0
138 0 $self->_add("aa" . $input_place, $attribute . GS . $splitter_str . $value_part);
139 }
140
141 0 ▶sub add_tag {
Subroutine add_tag: not called CC=3 SCAR=24.8
Pod undocumented
142 0 my ($self, $input_place, $tag_name, $id) = @_;
143 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
144 0 ▶ my $id_part = ($id ne "") ? GS . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
145 0 $self->_add("nt" . $input_place, $tag_name . $id_part);
146 }
147
148 0 ▶sub add_tag_to_up {
Subroutine add_tag_to_up: not called CC=3 SCAR=24.8
Pod undocumented
149 0 my ($self, $input_place, $tag_name, $id) = @_;
150 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
151 0 ▶ my $id_part = ($id ne "") ? GS . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
152 0 $self->_add("ut" . $input_place, $tag_name . $id_part);
153 }
154
155 0 ▶sub add_tag_before {
Subroutine add_tag_before: not called CC=3 SCAR=24.8
Pod undocumented
156 0 my ($self, $input_place, $tag_name, $id) = @_;
157 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
158 0 ▶ my $id_part = ($id ne "") ? GS . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
159 0 $self->_add("bt" . $input_place, $tag_name . $id_part);
160 }
161
162 0 ▶sub add_tag_after {
Subroutine add_tag_after: not called CC=3 SCAR=24.8
Pod undocumented
163 0 my ($self, $input_place, $tag_name, $id) = @_;
164 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
165 0 ▶ my $id_part = ($id ne "") ? GS . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
166 0 $self->_add("ft" . $input_place, $tag_name . $id_part);
167 }
168
169 0 ▶sub add_hidden {
Subroutine add_hidden: not called CC=3 SCAR=24.8
Pod undocumented
170 0 my ($self, $input_place, $name, $value, $id) = @_;
171 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
172 0 ▶ my $id_part = ($id ne "") ? GS . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
173 0 $self->_add("ah" . $input_place, $name . GS . $value . $id_part);
174 }
175
176 # Set
177 # Creates the Data if it does not exist; otherwise, Replaces the Existing Value with the New Value.
178 0 ▶sub set_id {
Subroutine set_id: not called CC=1 SCAR=6.9
Pod undocumented
179 0 my ($self, $input_place, $id) = @_;
180 0 $self->_add("si" . $input_place, $id);
181 }
182
183 0 ▶sub set_name {
Subroutine set_name: not called CC=1 SCAR=6.9
Pod undocumented
184 0 my ($self, $input_place, $name) = @_;
185 0 $self->_add("sn" . $input_place, $name);
186 }
187
188 0 ▶sub set_value {
Subroutine set_value: not called CC=1 SCAR=6.9
Pod undocumented
189 0 my ($self, $input_place, $value) = @_;
190 0 $self->_add("sv" . $input_place, $value);
191 }
192
193 0 ▶sub set_class {
Subroutine set_class: not called CC=1 SCAR=6.9
Pod undocumented
194 0 my ($self, $input_place, $class) = @_;
195 0 $self->_add("sc" . $input_place, $class);
196 }
197
198 0 ▶sub set_style {
Subroutine set_style: not called CC=2 SCAR=17.9
Pod undocumented
199 0 my ($self, $input_place, $name_or_style, $value) = @_;
200 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
201 0 $self->_add("ss" . $input_place, $name_or_style);
202 } else {
203 0 $self->_add("ss" . $input_place, $name_or_style . ':' . $value);
204 }
205 }
206
207 0 ▶sub set_option_tag {
Subroutine set_option_tag: not called CC=3 SCAR=24.8
Pod undocumented
208 0 my ($self, $input_place, $text, $value, $selected) = @_;
209 0 ▶ $selected = 0 if !defined $selected;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $selected 0 0 0
210 0 ▶ $self->_add("so" . $input_place, $value . GS . $text . ($selected ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$selected ? : 0 0 0
211 }
212
213 0 ▶sub set_checked {
Subroutine set_checked: not called CC=3 SCAR=24.8
Pod undocumented
214 0 my ($self, $input_place, $checked) = @_;
215 0 ▶ $checked = 0 if !defined $checked;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $checked 0 0 0
216 0 ▶ $self->_add("sk" . $input_place, $checked ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$checked ? : 0 0 0
217 }
218
219 0 ▶sub set_check_box_tag {
Subroutine set_check_box_tag: not called CC=3 SCAR=24.8
Pod undocumented
220 0 my ($self, $input_place, $text, $value, $checked) = @_;
221 0 ▶ $checked = 0 if !defined $checked;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $checked 0 0 0
222 0 ▶ $self->_add("sk" . $input_place, $value . GS . $text . ($checked ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$checked ? : 0 0 0
223 }
224
225 0 ▶sub set_title {
Subroutine set_title: not called CC=1 SCAR=6.9
Pod undocumented
226 0 my ($self, $input_place, $title) = @_;
227 0 $self->_add("sl" . $input_place, $title);
228 }
229
230 0 ▶sub set_label {
Subroutine set_label: not called CC=1 SCAR=6.9
Pod undocumented
231 0 my ($self, $input_place, $label) = @_;
232 0 $self->_add("sA" . $input_place, $label);
233 }
234
235 0 ▶sub set_text {
Subroutine set_text: not called CC=1 SCAR=6.9
Pod undocumented
236 0 my ($self, $input_place, $text) = @_;
237 0 $text =~ s/\n/\$[ln];/g;
238 0 $self->_add("st" . $input_place, $text);
239 }
240
241 0 ▶sub set_attribute {
Subroutine set_attribute: not called CC=3 SCAR=24.8
Pod undocumented
242 0 my ($self, $input_place, $attribute, $value) = @_;
243 0 ▶ $value = "" if !defined $value;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $value 0 0 0
244 0 ▶ my $value_part = ($value ne "") ? GS . $value : "";
Branch: 1 branch
BranchTrueFalseTotal
$value ne '' ? : 0 0 0
245 0 $self->_add("sa" . $input_place, $attribute . GS . $value_part);
246 }
247
248 0 ▶sub set_width {
Subroutine set_width: not called CC=2 SCAR=17.9
Pod undocumented
249 0 my ($self, $input_place, $width) = @_;
250 0 ▶ my $final_width = ($width =~ /^-?\d+$/) ? "${width}px" : $width;
Branch: 1 branch
BranchTrueFalseTotal
$width =~ /^-?\d+$/u ? : 0 0 0
251 0 $self->_add("sw" . $input_place, $final_width);
252 }
253
254 0 ▶sub set_height {
Subroutine set_height: not called CC=2 SCAR=17.9
Pod undocumented
255 0 my ($self, $input_place, $height) = @_;
256 0 ▶ my $final_height = ($height =~ /^-?\d+$/) ? "${height}px" : $height;
Branch: 1 branch
BranchTrueFalseTotal
$height =~ /^-?\d+$/u ? : 0 0 0
257 0 $self->_add("sh" . $input_place, $final_height);
258 }
259
260 0 ▶sub set_background_color {
Subroutine set_background_color: not called CC=1 SCAR=6.9
Pod undocumented
261 0 my ($self, $input_place, $color) = @_;
262 0 $self->_add("bc" . $input_place, $color);
263 }
264
265 0 ▶sub set_text_color {
Subroutine set_text_color: not called CC=1 SCAR=6.9
Pod undocumented
266 0 my ($self, $input_place, $color) = @_;
267 0 $self->_add("tc" . $input_place, $color);
268 }
269
270 0 ▶sub set_font_name {
Subroutine set_font_name: not called CC=1 SCAR=6.9
Pod undocumented
271 0 my ($self, $input_place, $name) = @_;
272 0 $self->_add("fn" . $input_place, $name);
273 }
274
275 0 ▶sub set_font_size {
Subroutine set_font_size: not called CC=2 SCAR=17.9
Pod undocumented
276 0 my ($self, $input_place, $size) = @_;
277 0 ▶ my $final_size = ($size =~ /^-?\d+$/) ? "${size}px" : $size;
Branch: 1 branch
BranchTrueFalseTotal
$size =~ /^-?\d+$/u ? : 0 0 0
278 0 $self->_add("fs" . $input_place, $final_size);
279 }
280
281 0 ▶sub set_font_bold {
Subroutine set_font_bold: not called CC=2 SCAR=17.9
Pod undocumented
282 0 my ($self, $input_place, $bold) = @_;
283 0 ▶ $self->_add("fb" . $input_place, $bold ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$bold ? : 0 0 0
284 }
285
286 0 ▶sub set_visible {
Subroutine set_visible: not called CC=2 SCAR=17.9
Pod undocumented
287 0 my ($self, $input_place, $visible) = @_;
288 0 ▶ $self->_add("vi" . $input_place, $visible ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$visible ? : 0 0 0
289 }
290
291 0 ▶sub set_text_align {
Subroutine set_text_align: not called CC=1 SCAR=6.9
Pod undocumented
292 0 my ($self, $input_place, $align) = @_;
293 0 $self->_add("ta" . $input_place, $align);
294 }
295
296 0 ▶sub set_read_only {
Subroutine set_read_only: not called CC=2 SCAR=17.9
Pod undocumented
297 0 my ($self, $input_place, $read_only) = @_;
298 0 ▶ $self->_add("sr" . $input_place, $read_only ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$read_only ? : 0 0 0
299 }
300
301 0 ▶sub set_disabled {
Subroutine set_disabled: not called CC=2 SCAR=17.9
Pod undocumented
302 0 my ($self, $input_place, $disabled) = @_;
303 0 ▶ $self->_add("sd" . $input_place, $disabled ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$disabled ? : 0 0 0
304 }
305
306 0 ▶sub set_focus {
Subroutine set_focus: not called CC=2 SCAR=17.9
Pod undocumented
307 0 my ($self, $input_place, $focus) = @_;
308 0 ▶ $self->_add("sf" . $input_place, $focus ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$focus ? : 0 0 0
309 }
310
311 0 ▶sub set_min_length {
Subroutine set_min_length: not called CC=1 SCAR=6.9
Pod undocumented
312 0 my ($self, $input_place, $length) = @_;
313 0 $self->_add("mn" . $input_place, "$length");
314 }
315
316 0 ▶sub set_max_length {
Subroutine set_max_length: not called CC=1 SCAR=6.9
Pod undocumented
317 0 my ($self, $input_place, $length) = @_;
318 0 $self->_add("mx" . $input_place, "$length");
319 }
320
321 0 ▶sub set_selected_value {
Subroutine set_selected_value: not called CC=1 SCAR=6.9
Pod undocumented
322 0 my ($self, $input_place, $value) = @_;
323 0 $self->_add("ts" . $input_place, $value);
324 }
325
326 0 ▶sub set_selected_index {
Subroutine set_selected_index: not called CC=1 SCAR=6.9
Pod undocumented
327 0 my ($self, $input_place, $index) = @_;
328 0 $self->_add("ti" . $input_place, "$index");
329 }
330
331 0 ▶sub set_checked_value {
Subroutine set_checked_value: not called CC=2 SCAR=17.9
Pod undocumented
332 0 my ($self, $input_place, $value, $checked) = @_;
333 0 ▶ $self->_add("ks" . $input_place, $value . GS . ($checked ? "1" : "0"));
Branch: 1 branch
BranchTrueFalseTotal
$checked ? : 0 0 0
334 }
335
336 0 ▶sub set_checked_index {
Subroutine set_checked_index: not called CC=2 SCAR=17.9
Pod undocumented
337 0 my ($self, $input_place, $index, $checked) = @_;
338 0 ▶ $self->_add("ki" . $input_place, "$index" . GS . ($checked ? "1" : "0"));
Branch: 1 branch
BranchTrueFalseTotal
$checked ? : 0 0 0
339 }
340
341 # Insert
342 # Creates the Data only if it does not exist; otherwise, does nothing.
343 0 ▶sub insert_id {
Subroutine insert_id: not called CC=1 SCAR=6.9
Pod undocumented
344 0 my ($self, $input_place, $id) = @_;
345 0 $self->_add("ii" . $input_place, $id);
346 }
347
348 0 ▶sub insert_name {
Subroutine insert_name: not called CC=1 SCAR=6.9
Pod undocumented
349 0 my ($self, $input_place, $name) = @_;
350 0 $self->_add("in" . $input_place, $name);
351 }
352
353 0 ▶sub insert_value {
Subroutine insert_value: not called CC=1 SCAR=6.9
Pod undocumented
354 0 my ($self, $input_place, $value) = @_;
355 0 $self->_add("iv" . $input_place, $value);
356 }
357
358 0 ▶sub insert_class {
Subroutine insert_class: not called CC=1 SCAR=6.9
Pod undocumented
359 0 my ($self, $input_place, $class) = @_;
360 0 $self->_add("ic" . $input_place, $class);
361 }
362
363 0 ▶sub insert_style {
Subroutine insert_style: not called CC=2 SCAR=17.9
Pod undocumented
364 0 my ($self, $input_place, $name_or_style, $value) = @_;
365 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
366 0 $self->_add("is" . $input_place, $name_or_style);
367 } else {
368 0 $self->_add("is" . $input_place, $name_or_style . ':' . $value);
369 }
370 }
371
372 0 ▶sub insert_option_tag {
Subroutine insert_option_tag: not called CC=3 SCAR=24.8
Pod undocumented
373 0 my ($self, $input_place, $text, $value, $selected) = @_;
374 0 ▶ $selected = 0 if !defined $selected;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $selected 0 0 0
375 0 ▶ $self->_add("io" . $input_place, $value . GS . $text . ($selected ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$selected ? : 0 0 0
376 }
377
378 0 ▶sub insert_check_box_tag {
Subroutine insert_check_box_tag: not called CC=3 SCAR=24.8
Pod undocumented
379 0 my ($self, $input_place, $text, $value, $checked) = @_;
380 0 ▶ $checked = 0 if !defined $checked;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $checked 0 0 0
381 0 ▶ $self->_add("ik" . $input_place, $value . GS . $text . ($checked ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$checked ? : 0 0 0
382 }
383
384 0 ▶sub insert_title {
Subroutine insert_title: not called CC=1 SCAR=6.9
Pod undocumented
385 0 my ($self, $input_place, $title) = @_;
386 0 $self->_add("il" . $input_place, $title);
387 }
388
389 0 ▶sub insert_label {
Subroutine insert_label: not called CC=1 SCAR=6.9
Pod undocumented
390 0 my ($self, $input_place, $label) = @_;
391 0 $self->_add("iA" . $input_place, $label);
392 }
393
394 0 ▶sub insert_text {
Subroutine insert_text: not called CC=1 SCAR=6.9
Pod undocumented
395 0 my ($self, $input_place, $text) = @_;
396 0 $text =~ s/\n/\$[ln];/g;
397 0 $self->_add("it" . $input_place, $text);
398 }
399
400 0 ▶sub insert_attribute {
Subroutine insert_attribute: not called CC=5 SCAR=34.0
Pod undocumented
401 0 my ($self, $input_place, $attribute, $value, $splitter) = @_;
402 0 ▶ $value = "" if !defined $value;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $value 0 0 0
403 0 ▶ $splitter = "\0" if !defined $splitter;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $splitter 0 0 0
404 0 ▶ my $splitter_str = ($splitter ne "\0") ? $splitter : "";
Branch: 1 branch
BranchTrueFalseTotal
$splitter ne "\000" ? : 0 0 0
405 0 ▶ my $value_part = ($value ne "") ? GS . $value : "";
Branch: 1 branch
BranchTrueFalseTotal
$value ne '' ? : 0 0 0
406 0 $self->_add("ia" . $input_place, $attribute . GS . $splitter_str . $value_part);
407 }
408
409 # Delete
410 0 ▶sub delete_id {
Subroutine delete_id: not called CC=1 SCAR=6.9
Pod undocumented
411 0 my ($self, $input_place) = @_;
412 0 $self->_add("di" . $input_place);
413 }
414
415 0 ▶sub delete_name {
Subroutine delete_name: not called CC=1 SCAR=6.9
Pod undocumented
416 0 my ($self, $input_place) = @_;
417 0 $self->_add("dn" . $input_place);
418 }
419
420 0 ▶sub delete_value {
Subroutine delete_value: not called CC=1 SCAR=6.9
Pod undocumented
421 0 my ($self, $input_place) = @_;
422 0 $self->_add("dv" . $input_place);
423 }
424
425 0 ▶sub delete_class {
Subroutine delete_class: not called CC=1 SCAR=6.9
Pod undocumented
426 0 my ($self, $input_place, $class_name) = @_;
427 0 $self->_add("dc" . $input_place, $class_name);
428 }
429
430 0 ▶sub delete_style {
Subroutine delete_style: not called CC=1 SCAR=6.9
Pod undocumented
431 0 my ($self, $input_place, $style_name) = @_;
432 0 $self->_add("ds" . $input_place, $style_name);
433 }
434
435 0 ▶sub delete_option_tag {
Subroutine delete_option_tag: not called CC=1 SCAR=6.9
Pod undocumented
436 0 my ($self, $input_place, $value) = @_;
437 0 $self->_add("do" . $input_place, $value);
438 }
439
440 0 ▶sub delete_all_option_tag {
Subroutine delete_all_option_tag: not called CC=1 SCAR=6.9
Pod undocumented
441 0 my ($self, $input_place) = @_;
442 0 $self->_add("do" . $input_place, "*");
443 }
444
445 0 ▶sub delete_check_box_tag {
Subroutine delete_check_box_tag: not called CC=1 SCAR=6.9
Pod undocumented
446 0 my ($self, $input_place, $value) = @_;
447 0 $self->_add("dk" . $input_place, $value);
448 }
449
450 0 ▶sub delete_all_check_box_tag {
Subroutine delete_all_check_box_tag: not called CC=1 SCAR=6.9
Pod undocumented
451 0 my ($self, $input_place) = @_;
452 0 $self->_add("dk" . $input_place, "*");
453 }
454
455 0 ▶sub delete_title {
Subroutine delete_title: not called CC=1 SCAR=6.9
Pod undocumented
456 0 my ($self, $input_place) = @_;
457 0 $self->_add("dl" . $input_place);
458 }
459
460 0 ▶sub delete_label {
Subroutine delete_label: not called CC=1 SCAR=6.9
Pod undocumented
461 0 my ($self, $input_place) = @_;
462 0 $self->_add("dA" . $input_place);
463 }
464
465 0 ▶sub delete_text {
Subroutine delete_text: not called CC=1 SCAR=6.9
Pod undocumented
466 0 my ($self, $input_place) = @_;
467 0 $self->_add("dt" . $input_place);
468 }
469
470 0 ▶sub delete_attribute {
Subroutine delete_attribute: not called CC=1 SCAR=6.9
Pod undocumented
471 0 my ($self, $input_place, $attribute) = @_;
472 0 $self->_add("da" . $input_place, $attribute);
473 }
474
475 0 ▶sub delete {
Subroutine delete: not called CC=1 SCAR=6.9
Pod undocumented
476 0 my ($self, $input_place) = @_;
477 0 $self->_add("de" . $input_place);
478 }
479
480 0 ▶sub delete_parent {
Subroutine delete_parent: not called CC=1 SCAR=6.9
Pod undocumented
481 0 my ($self, $input_place) = @_;
482 0 $self->_add("dp" . $input_place);
483 }
484
485 # Tag
486 0 ▶sub swap_tag {
Subroutine swap_tag: not called CC=1 SCAR=6.9
Pod undocumented
487 0 my ($self, $input_place, $output_place) = @_;
488 0 $self->_add("sp" . $input_place, $output_place);
489 }
490
491 0 ▶sub set_reflection {
Subroutine set_reflection: not called CC=1 SCAR=6.9
Pod undocumented
492 0 my ($self, $input_place, $tag) = @_;
493 0 $self->_add("sR" . $input_place, $tag);
494 }
495
496 0 ▶sub set_reflection_by_output_place {
Subroutine set_reflection_by_output_place: not called CC=1 SCAR=6.9
Pod undocumented
497 0 my ($self, $input_place, $output_place) = @_;
498 0 $self->_add("iR" . $input_place, $output_place);
499 }
500
501 0 ▶sub set_morph {
Subroutine set_morph: not called CC=1 SCAR=6.9
Pod undocumented
502 0 my ($self, $input_place, $tag) = @_;
503 0 $self->_add("sM" . $input_place, $tag);
504 }
505
506 0 ▶sub set_morph_by_output_place {
Subroutine set_morph_by_output_place: not called CC=1 SCAR=6.9
Pod undocumented
507 0 my ($self, $input_place, $output_place) = @_;
508 0 $self->_add("iM" . $input_place, $output_place);
509 }
510
511 # Browser
512 0 ▶sub change_url {
Subroutine change_url: not called CC=1 SCAR=6.9
Pod undocumented
513 0 my ($self, $url) = @_;
514 0 $self->_add("cu", $url);
515 }
516
517 0 ▶sub set_head_title {
Subroutine set_head_title: not called CC=1 SCAR=6.9
Pod undocumented
518 0 my ($self, $title) = @_;
519 0 $self->_add("ht", $title);
520 }
521
522 0 ▶sub clipboard_write_text {
Subroutine clipboard_write_text: not called CC=1 SCAR=6.9
Pod undocumented
523 0 my ($self, $text) = @_;
524 0 $self->_add("nw", $text);
525 }
526
527 0 ▶sub scroll_to {
Subroutine scroll_to: not called CC=1 SCAR=6.9
Pod undocumented
528 0 my ($self, $x, $y) = @_;
529 0 $self->_add("ws", "$x" . GS . "$y");
530 }
531
532 0 ▶sub history_go {
Subroutine history_go: not called CC=1 SCAR=6.9
Pod undocumented
533 0 my ($self, $steps) = @_;
534 0 $self->_add("wg", "$steps");
535 }
536
537 0 ▶sub reload_page {
Subroutine reload_page: not called CC=1 SCAR=6.9
Pod undocumented
538 0 my ($self) = @_;
539 0 $self->_add("lr");
540 }
541
542 0 ▶sub redirect {
Subroutine redirect: not called CC=1 SCAR=6.9
Pod undocumented
543 0 my ($self, $path) = @_;
544 0 $self->_add("lh", $path);
545 }
546
547 # Increase
548 0 ▶sub increase_min_length {
Subroutine increase_min_length: not called CC=1 SCAR=6.9
Pod undocumented
549 0 my ($self, $input_place, $value) = @_;
550 0 $self->_add("+n" . $input_place, "$value");
551 }
552
553 0 ▶sub increase_max_length {
Subroutine increase_max_length: not called CC=1 SCAR=6.9
Pod undocumented
554 0 my ($self, $input_place, $value) = @_;
555 0 $self->_add("+x" . $input_place, "$value");
556 }
557
558 0 ▶sub increase_font_size {
Subroutine increase_font_size: not called CC=1 SCAR=6.9
Pod undocumented
559 0 my ($self, $input_place, $value) = @_;
560 0 $self->_add("+f" . $input_place, "$value");
561 }
562
563 0 ▶sub increase_width {
Subroutine increase_width: not called CC=1 SCAR=6.9
Pod undocumented
564 0 my ($self, $input_place, $value) = @_;
565 0 $self->_add("+w" . $input_place, "$value");
566 }
567
568 0 ▶sub increase_height {
Subroutine increase_height: not called CC=1 SCAR=6.9
Pod undocumented
569 0 my ($self, $input_place, $value) = @_;
570 0 $self->_add("+h" . $input_place, "$value");
571 }
572
573 0 ▶sub increase_value {
Subroutine increase_value: not called CC=1 SCAR=6.9
Pod undocumented
574 0 my ($self, $input_place, $value) = @_;
575 0 $self->_add("+v" . $input_place, "$value");
576 }
577
578 # Decrease
579 0 ▶sub decrease_min_length {
Subroutine decrease_min_length: not called CC=1 SCAR=6.9
Pod undocumented
580 0 my ($self, $input_place, $value) = @_;
581 0 $self->_add("-n" . $input_place, "$value");
582 }
583
584 0 ▶sub decrease_max_length {
Subroutine decrease_max_length: not called CC=1 SCAR=6.9
Pod undocumented
585 0 my ($self, $input_place, $value) = @_;
586 0 $self->_add("-x" . $input_place, "$value");
587 }
588
589 0 ▶sub decrease_font_size {
Subroutine decrease_font_size: not called CC=1 SCAR=6.9
Pod undocumented
590 0 my ($self, $input_place, $value) = @_;
591 0 $self->_add("-f" . $input_place, "$value");
592 }
593
594 0 ▶sub decrease_width {
Subroutine decrease_width: not called CC=1 SCAR=6.9
Pod undocumented
595 0 my ($self, $input_place, $value) = @_;
596 0 $self->_add("-w" . $input_place, "$value");
597 }
598
599 0 ▶sub decrease_height {
Subroutine decrease_height: not called CC=1 SCAR=6.9
Pod undocumented
600 0 my ($self, $input_place, $value) = @_;
601 0 $self->_add("-h" . $input_place, "$value");
602 }
603
604 0 ▶sub decrease_value {
Subroutine decrease_value: not called CC=1 SCAR=6.9
Pod undocumented
605 0 my ($self, $input_place, $value) = @_;
606 0 $self->_add("-v" . $input_place, "$value");
607 }
608
609 # Event
610 # ConstructorName: mouseevent, keyboardevent, uievent, focusevent, inputevent, event
611 # All Method in "Event" Section Only Support Dynamic Args Once. To Support Invoking Dynamic Arguments on a Momentary Basis, Use "EventListener" Section Methods.
612 0 ▶sub trigger_event {
Subroutine trigger_event: not called CC=3 SCAR=24.8
Pod undocumented
613 0 my ($self, $input_place, $html_event_listener, $constructor_name) = @_;
614 0 ▶ $constructor_name = "" if !defined $constructor_name;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $constructor_name 0 0 0
615 0 ▶ my $constructor_part = ($constructor_name ne "") ? GS . $constructor_name : "";
Branch: 1 branch
BranchTrueFalseTotal
$constructor_name ne '' ? : 0 0 0
616 0 $self->_add("TE" . $input_place, $html_event_listener . $constructor_part);
617 }
618
619 0 ▶sub set_post_event {
Subroutine set_post_event: not called CC=4 SCAR=30.0
Pod undocumented
620 0 my ($self, $input_place, $html_event, $output_place) = @_;
621 0 ▶ if (@_ == 3) {
Branch: 2 branches
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
elsif (@_ == 4 and $output_place eq '+') { } 0 0 0
622 0 $self->_add("Ep" . $input_place, $html_event);
623 ▶ } elsif (@_ == 4 && $output_place eq "+") {
Condition0%0/3
@_ == 4 and $output_place eq "+"
!ll&&!rl&&r
000
MC/DC0%0/2
@_ == 4 and $output_place eq "+"
@_ == 4 $output_place eq "+"
Truth table0%0/3
A and B
A= @_ == 4B= $output_place eq "+"
ABresult
0X0
100
111
624 0 $self->_add("Ep" . $input_place, $html_event . GS . "+");
625 } else {
626 0 $self->_add("Ep" . $input_place, $html_event . GS . $output_place);
627 }
628 }
629
630 0 ▶sub set_post_event_listener {
Subroutine set_post_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
631 0 my ($self, $input_place, $html_event_listener, $output_place) = @_;
632 0 ▶ if (@_ == 3) {
Branch: 2 branches
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
elsif (@_ == 4 and $output_place eq '+') { } 0 0 0
633 0 $self->_add("EP" . $input_place, $html_event_listener);
634 ▶ } elsif (@_ == 4 && $output_place eq "+") {
Condition0%0/3
@_ == 4 and $output_place eq "+"
!ll&&!rl&&r
000
MC/DC0%0/2
@_ == 4 and $output_place eq "+"
@_ == 4 $output_place eq "+"
Truth table0%0/3
A and B
A= @_ == 4B= $output_place eq "+"
ABresult
0X0
100
111
635 0 $self->_add("EP" . $input_place, $html_event_listener . GS . "+");
636 } else {
637 0 $self->_add("EP" . $input_place, $html_event_listener . GS . $output_place);
638 }
639 }
640
641 0 ▶sub set_get_event {
Subroutine set_get_event: not called CC=4 SCAR=30.0
Pod undocumented
642 0 my ($self, $input_place, $html_event, $path_or_output, $output_place) = @_;
643 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
644 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
645 0 $self->_add("Eg" . $input_place, $html_event . GS . $path);
646 } else {
647 0 $self->_add("Eg" . $input_place, $html_event . GS . $path . GS . $output_place);
648 }
649 }
650
651 0 ▶sub set_get_event_listener {
Subroutine set_get_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
652 0 my ($self, $input_place, $html_event_listener, $path_or_output, $output_place) = @_;
653 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
654 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
655 0 $self->_add("EG" . $input_place, $html_event_listener . GS . $path);
656 } else {
657 0 $self->_add("EG" . $input_place, $html_event_listener . GS . $path . GS . $output_place);
658 }
659 }
660
661 0 ▶sub set_put_event {
Subroutine set_put_event: not called CC=4 SCAR=30.0
Pod undocumented
662 0 my ($self, $input_place, $html_event, $path_or_output, $output_place) = @_;
663 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
664 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
665 0 $self->_add("Et" . $input_place, $html_event . GS . $path);
666 } else {
667 0 $self->_add("Et" . $input_place, $html_event . GS . $path . GS . $output_place);
668 }
669 }
670
671 0 ▶sub set_put_event_listener {
Subroutine set_put_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
672 0 my ($self, $input_place, $html_event_listener, $path_or_output, $output_place) = @_;
673 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
674 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
675 0 $self->_add("ET" . $input_place, $html_event_listener . GS . $path);
676 } else {
677 0 $self->_add("ET" . $input_place, $html_event_listener . GS . $path . GS . $output_place);
678 }
679 }
680
681 0 ▶sub set_patch_event {
Subroutine set_patch_event: not called CC=4 SCAR=30.0
Pod undocumented
682 0 my ($self, $input_place, $html_event, $path_or_output, $output_place) = @_;
683 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
684 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
685 0 $self->_add("Ea" . $input_place, $html_event . GS . $path);
686 } else {
687 0 $self->_add("Ea" . $input_place, $html_event . GS . $path . GS . $output_place);
688 }
689 }
690
691 0 ▶sub set_patch_event_listener {
Subroutine set_patch_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
692 0 my ($self, $input_place, $html_event_listener, $path_or_output, $output_place) = @_;
693 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
694 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
695 0 $self->_add("EA" . $input_place, $html_event_listener . GS . $path);
696 } else {
697 0 $self->_add("EA" . $input_place, $html_event_listener . GS . $path . GS . $output_place);
698 }
699 }
700
701 0 ▶sub set_delete_event {
Subroutine set_delete_event: not called CC=4 SCAR=30.0
Pod undocumented
702 0 my ($self, $input_place, $html_event, $path_or_output, $output_place) = @_;
703 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
704 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
705 0 $self->_add("El" . $input_place, $html_event . GS . $path);
706 } else {
707 0 $self->_add("El" . $input_place, $html_event . GS . $path . GS . $output_place);
708 }
709 }
710
711 0 ▶sub set_delete_event_listener {
Subroutine set_delete_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
712 0 my ($self, $input_place, $html_event_listener, $path_or_output, $output_place) = @_;
713 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
714 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
715 0 $self->_add("EL" . $input_place, $html_event_listener . GS . $path);
716 } else {
717 0 $self->_add("EL" . $input_place, $html_event_listener . GS . $path . GS . $output_place);
718 }
719 }
720
721 0 ▶sub set_options_event {
Subroutine set_options_event: not called CC=4 SCAR=30.0
Pod undocumented
722 0 my ($self, $input_place, $html_event, $path_or_output, $output_place) = @_;
723 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
724 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
725 0 $self->_add("Eo" . $input_place, $html_event . GS . $path);
726 } else {
727 0 $self->_add("Eo" . $input_place, $html_event . GS . $path . GS . $output_place);
728 }
729 }
730
731 0 ▶sub set_options_event_listener {
Subroutine set_options_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
732 0 my ($self, $input_place, $html_event_listener, $path_or_output, $output_place) = @_;
733 0 ▶ my $path = (!defined $path_or_output || $path_or_output eq "") ? "#" : $path_or_output;
Branch: 1 branch
BranchTrueFalseTotal
!defined($path_or_output) || $path_or_output eq '' ? : 0 0 0
Condition0%0/3
not defined $path_or_output or $path_or_output eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path_or_output or $path_or_output eq ""
not defined $path_or_output $path_or_output eq ""
Truth table0%0/3
not(A) or B
A= not defined $path_or_outputB= $path_or_output eq ""
ABresult
1X1
011
000
734 0 ▶ if (@_ == 3) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 3) { } 0 0 0
735 0 $self->_add("EO" . $input_place, $html_event_listener . GS . $path);
736 } else {
737 0 $self->_add("EO" . $input_place, $html_event_listener . GS . $path . GS . $output_place);
738 }
739 }
740
741 0 ▶sub set_head_event {
Subroutine set_head_event: not called CC=3 SCAR=24.8
Pod undocumented
742 0 my ($self, $input_place, $html_event, $path) = @_;
743 0 ▶ $path = "#" if !defined $path || $path eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $path or $path eq "" 0 0 0
Condition0%0/3
not defined $path or $path eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path or $path eq ""
not defined $path $path eq ""
Truth table0%0/3
not(A) or B
A= not defined $pathB= $path eq ""
ABresult
1X1
011
000
744 0 $self->_add("Eh" . $input_place, $html_event . GS . $path);
745 }
746
747 0 ▶sub set_head_event_listener {
Subroutine set_head_event_listener: not called CC=3 SCAR=24.8
Pod undocumented
748 0 my ($self, $input_place, $html_event_listener, $path) = @_;
749 0 ▶ $path = "#" if !defined $path || $path eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $path or $path eq "" 0 0 0
Condition0%0/3
not defined $path or $path eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path or $path eq ""
not defined $path $path eq ""
Truth table0%0/3
not(A) or B
A= not defined $pathB= $path eq ""
ABresult
1X1
011
000
750 0 $self->_add("EH" . $input_place, $html_event_listener . GS . $path);
751 }
752
753 # IsMultiPart: If this value is true, the data will be sent based on the Form and with the "content" key.
754 0 ▶sub set_send_event {
Subroutine set_send_event: not called CC=9 SCAR=45.0
Pod undocumented
755 0 my ($self, $input_place, $html_event, $data, $path, $method, $is_multi_part, $content_type, $output_place) = @_;
756 0 ▶ $path = "#" if !defined $path || $path eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $path or $path eq "" 0 0 0
Condition0%0/3
not defined $path or $path eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path or $path eq ""
not defined $path $path eq ""
Truth table0%0/3
not(A) or B
A= not defined $pathB= $path eq ""
ABresult
1X1
011
000
757 0 ▶ $method = "POST" if !defined $method;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $method 0 0 0
758 0 ▶ $is_multi_part = 0 if !defined $is_multi_part;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $is_multi_part 0 0 0
759 0 ▶ $content_type = "text/plain" if !defined $content_type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $content_type 0 0 0
760 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
761
762 0 my $processed_data = $data;
763 0 $processed_data =~ s/\n/\$[ln];/g;
764 0 $processed_data =~ s/"/\$[dq];/g;
765 0 $processed_data =~ s/'/\$[sq];/g;
766
767 0 ▶ my $output_part = ($output_place ne "") ? $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
768 0 ▶ $self->_add("En" . $input_place, $html_event . GS . $processed_data . GS . $path . GS . $method . GS . ($is_multi_part ? "1" : "0") . GS . $content_type . GS . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$is_multi_part ? : 0 0 0
769 }
770
771 0 ▶sub set_send_event_listener {
Subroutine set_send_event_listener: not called CC=9 SCAR=45.0
Pod undocumented
772 0 my ($self, $input_place, $html_event_listener, $data, $path, $method, $is_multi_part, $content_type, $output_place) = @_;
773 0 ▶ $path = "#" if !defined $path || $path eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $path or $path eq "" 0 0 0
Condition0%0/3
not defined $path or $path eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $path or $path eq ""
not defined $path $path eq ""
Truth table0%0/3
not(A) or B
A= not defined $pathB= $path eq ""
ABresult
1X1
011
000
774 0 ▶ $method = "POST" if !defined $method;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $method 0 0 0
775 0 ▶ $is_multi_part = 0 if !defined $is_multi_part;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $is_multi_part 0 0 0
776 0 ▶ $content_type = "text/plain" if !defined $content_type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $content_type 0 0 0
777 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
778
779 0 my $processed_data = $data;
780 0 $processed_data =~ s/\n/\$[ln];/g;
781
782 0 ▶ my $output_part = ($output_place ne "") ? $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
783 0 ▶ $self->_add("EN" . $input_place, $html_event_listener . GS . $processed_data . GS . $path . GS . $method . GS . ($is_multi_part ? "1" : "0") . GS . $content_type . GS . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$is_multi_part ? : 0 0 0
784 }
785
786 0 ▶sub set_comment_event {
Subroutine set_comment_event: not called CC=3 SCAR=24.8
Pod undocumented
787 0 my ($self, $input_place, $html_event, $index, $output_place) = @_;
788 0 ▶ $index = "" if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
789 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
790 0 $self->_add("Eb" . $input_place, $html_event . GS . $index . GS . $output_place);
791 }
792
793 0 ▶sub set_comment_event_listener {
Subroutine set_comment_event_listener: not called CC=3 SCAR=24.8
Pod undocumented
794 0 my ($self, $input_place, $html_event_listener, $index, $output_place) = @_;
795 0 ▶ $index = "" if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
796 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
797 0 $self->_add("EB" . $input_place, $html_event_listener . GS . $index . GS . $output_place);
798 }
799
800 0 ▶sub set_wasm_event {
Subroutine set_wasm_event: not called CC=5 SCAR=34.0
Pod undocumented
801 0 my ($self, $input_place, $html_event, $wasm_language, $wasm_url, $method_name, $args, $output_place) = @_;
802 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
803 0 my $args_join = "";
804 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
805 0 $args_join = "[" . join(US, @$args);
806 }
807 0 $self->_add("Ey" . $input_place, $html_event . GS . $wasm_language . GS . $wasm_url . GS . $method_name . GS . $args_join . GS . $output_place);
808 }
809
810 0 ▶sub set_wasm_event_listener {
Subroutine set_wasm_event_listener: not called CC=5 SCAR=34.0
Pod undocumented
811 0 my ($self, $input_place, $html_event_listener, $wasm_language, $wasm_url, $method_name, $args, $output_place) = @_;
812 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
813 0 my $args_join = "";
814 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
815 0 $args_join = "[" . join(US, @$args);
816 }
817 0 $self->_add("EY" . $input_place, $html_event_listener . GS . $wasm_language . GS . $wasm_url . GS . $method_name . GS . $args_join . GS . $output_place);
818 }
819
820 0 ▶sub set_web_socket_event {
Subroutine set_web_socket_event: not called CC=1 SCAR=6.9
Pod undocumented
821 0 my ($self, $input_place, $html_event, $path) = @_;
822 0 $self->_add("Ew" . $input_place, $html_event . GS . $path);
823 }
824
825 0 ▶sub set_web_socket_event_listener {
Subroutine set_web_socket_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
826 0 my ($self, $input_place, $html_event_listener, $path) = @_;
827 0 $self->_add("EW" . $input_place, $html_event_listener . GS . $path);
828 }
829
830 0 ▶sub set_sse_event {
Subroutine set_sse_event: not called CC=10 SCAR=47.0
Pod undocumented
831 0 my ($self, $input_place, $html_event, $path, $should_reconnect_or_output, $reconnect_try_timeout_or_nil, $output_place) = @_;
832 0 my $should_reconnect = 1;
833 0 my $reconnect_try_timeout = 3000;
834 0 my $out_place = "";
835
836 0 ▶ if (@_ == 5) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 5) { } 0 0 0
837 0 ▶ $should_reconnect = $should_reconnect_or_output // 1;
Condition0%0/2
$should_reconnect_or_output // 1
l!l
00
MC/DC0%0/1
$should_reconnect_or_output // 1
$should_reconnect_or_output
Truth table0%0/2
A
A= $should_reconnect_or_output
Aresult
11
00
838 0 ▶ $reconnect_try_timeout = $reconnect_try_timeout_or_nil // 3000;
Condition0%0/2
$reconnect_try_timeout_or_nil // 3000
l!l
00
MC/DC0%0/1
$reconnect_try_timeout_or_nil // 3000
$reconnect_try_timeout_or_nil
Truth table0%0/2
A
A= $reconnect_try_timeout_or_nil
Aresult
11
00
839 } else {
840 0 ▶ $should_reconnect = $should_reconnect_or_output // 1;
Condition0%0/2
$should_reconnect_or_output // 1
l!l
00
MC/DC0%0/1
$should_reconnect_or_output // 1
$should_reconnect_or_output
Truth table0%0/2
A
A= $should_reconnect_or_output
Aresult
11
00
841 0 ▶ $reconnect_try_timeout = $reconnect_try_timeout_or_nil // 3000;
Condition0%0/2
$reconnect_try_timeout_or_nil // 3000
l!l
00
MC/DC0%0/1
$reconnect_try_timeout_or_nil // 3000
$reconnect_try_timeout_or_nil
Truth table0%0/2
A
A= $reconnect_try_timeout_or_nil
Aresult
11
00
842 0 ▶ $out_place = $output_place // "";
Condition0%0/2
$output_place // ""
l!l
00
MC/DC0%0/1
$output_place // ""
$output_place
Truth table0%0/2
A
A= $output_place
Aresult
11
00
843 }
844
845 0 ▶ if ($out_place eq "") {
Branch: 1 branch
BranchTrueFalseTotal
if ($out_place eq '') { } 0 0 0
846 0 ▶ $self->_add("Ee" . $input_place, $html_event . GS . $path . GS . ($should_reconnect ? "1" : "0") . GS . $reconnect_try_timeout);
Branch: 1 branch
BranchTrueFalseTotal
$should_reconnect ? : 0 0 0
847 } else {
848 0 ▶ $self->_add("Ee" . $input_place, $html_event . GS . $path . GS . ($should_reconnect ? "1" : "0") . GS . $reconnect_try_timeout . GS . $out_place);
Branch: 1 branch
BranchTrueFalseTotal
$should_reconnect ? : 0 0 0
849 }
850 }
851
852 0 ▶sub set_sse_event_listener {
Subroutine set_sse_event_listener: not called CC=10 SCAR=47.0
Pod undocumented
853 0 my ($self, $input_place, $html_event_listener, $path, $should_reconnect_or_output, $reconnect_try_timeout_or_nil, $output_place) = @_;
854 0 my $should_reconnect = 1;
855 0 my $reconnect_try_timeout = 3000;
856 0 my $out_place = "";
857
858 0 ▶ if (@_ == 5) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_ == 5) { } 0 0 0
859 0 ▶ $should_reconnect = $should_reconnect_or_output // 1;
Condition0%0/2
$should_reconnect_or_output // 1
l!l
00
MC/DC0%0/1
$should_reconnect_or_output // 1
$should_reconnect_or_output
Truth table0%0/2
A
A= $should_reconnect_or_output
Aresult
11
00
860 0 ▶ $reconnect_try_timeout = $reconnect_try_timeout_or_nil // 3000;
Condition0%0/2
$reconnect_try_timeout_or_nil // 3000
l!l
00
MC/DC0%0/1
$reconnect_try_timeout_or_nil // 3000
$reconnect_try_timeout_or_nil
Truth table0%0/2
A
A= $reconnect_try_timeout_or_nil
Aresult
11
00
861 } else {
862 0 ▶ $should_reconnect = $should_reconnect_or_output // 1;
Condition0%0/2
$should_reconnect_or_output // 1
l!l
00
MC/DC0%0/1
$should_reconnect_or_output // 1
$should_reconnect_or_output
Truth table0%0/2
A
A= $should_reconnect_or_output
Aresult
11
00
863 0 ▶ $reconnect_try_timeout = $reconnect_try_timeout_or_nil // 3000;
Condition0%0/2
$reconnect_try_timeout_or_nil // 3000
l!l
00
MC/DC0%0/1
$reconnect_try_timeout_or_nil // 3000
$reconnect_try_timeout_or_nil
Truth table0%0/2
A
A= $reconnect_try_timeout_or_nil
Aresult
11
00
864 0 ▶ $out_place = $output_place // "";
Condition0%0/2
$output_place // ""
l!l
00
MC/DC0%0/1
$output_place // ""
$output_place
Truth table0%0/2
A
A= $output_place
Aresult
11
00
865 }
866
867 0 ▶ if ($out_place eq "") {
Branch: 1 branch
BranchTrueFalseTotal
if ($out_place eq '') { } 0 0 0
868 0 ▶ $self->_add("EE" . $input_place, $html_event_listener . GS . $path . GS . ($should_reconnect ? "1" : "0") . GS . $reconnect_try_timeout);
Branch: 1 branch
BranchTrueFalseTotal
$should_reconnect ? : 0 0 0
869 } else {
870 0 ▶ $self->_add("EE" . $input_place, $html_event_listener . GS . $path . GS . ($should_reconnect ? "1" : "0") . GS . $reconnect_try_timeout . GS . $out_place);
Branch: 1 branch
BranchTrueFalseTotal
$should_reconnect ? : 0 0 0
871 }
872 }
873
874 0 ▶sub set_front_event {
Subroutine set_front_event: not called CC=5 SCAR=34.0
Pod undocumented
875 0 my ($self, $input_place, $html_event, $module_path, $args, $output_place) = @_;
876 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
877 0 my $args_join = "";
878 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
879 0 $args_join = GS . "[" . join(US, @$args);
880 }
881 0 $self->_add("Ej" . $input_place, $html_event . GS . $module_path . GS . $output_place . $args_join);
882 }
883
884 0 ▶sub set_front_event_listener {
Subroutine set_front_event_listener: not called CC=5 SCAR=34.0
Pod undocumented
885 0 my ($self, $input_place, $html_event_listener, $module_path, $args, $output_place) = @_;
886 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
887 0 my $args_join = "";
888 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
889 0 $args_join = GS . "[" . join(US, @$args);
890 }
891 0 $self->_add("EJ" . $input_place, $html_event_listener . GS . $module_path . GS . $output_place . $args_join);
892 }
893
894 0 ▶sub set_master_pages_event {
Subroutine set_master_pages_event: not called CC=2 SCAR=17.9
Pod undocumented
895 0 my ($self, $input_place, $html_event, $output_place) = @_;
896 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
897 0 $self->_add("Eu" . $input_place, $html_event . GS . $output_place);
898 }
899
900 0 ▶sub set_master_pages_event_listener {
Subroutine set_master_pages_event_listener: not called CC=2 SCAR=17.9
Pod undocumented
901 0 my ($self, $input_place, $html_event_listener, $output_place) = @_;
902 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
903 0 $self->_add("EU" . $input_place, $html_event_listener . GS . $output_place);
904 }
905
906 0 ▶sub set_prevent_default_event {
Subroutine set_prevent_default_event: not called CC=1 SCAR=6.9
Pod undocumented
907 0 my ($self, $input_place, $html_event) = @_;
908 0 $self->_add("Ed" . $input_place, $html_event);
909 }
910
911 0 ▶sub set_prevent_default_event_listener {
Subroutine set_prevent_default_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
912 0 my ($self, $input_place, $html_event_listener) = @_;
913 0 $self->_add("ED" . $input_place, $html_event_listener);
914 }
915
916 0 ▶sub set_stop_propagation_event {
Subroutine set_stop_propagation_event: not called CC=1 SCAR=6.9
Pod undocumented
917 0 my ($self, $input_place, $html_event) = @_;
918 0 $self->_add("Es" . $input_place, $html_event);
919 }
920
921 0 ▶sub set_stop_propagation_event_listener {
Subroutine set_stop_propagation_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
922 0 my ($self, $input_place, $html_event_listener) = @_;
923 0 $self->_add("ES" . $input_place, $html_event_listener);
924 }
925
926 0 ▶sub set_method_event {
Subroutine set_method_event: not called CC=4 SCAR=30.0
Pod undocumented
927 0 my ($self, $input_place, $html_event, $method_name, $args) = @_;
928 0 my $args_join = "";
929 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
930 0 $args_join = GS . "[" . join(US, @$args);
931 }
932 0 $self->_add("Em" . $input_place, $html_event . GS . $method_name . $args_join);
933 }
934
935 0 ▶sub set_method_event_listener {
Subroutine set_method_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
936 0 my ($self, $input_place, $html_event_listener, $method_name, $args) = @_;
937 0 my $args_join = "";
938 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
939 0 $args_join = GS . "[" . join(US, @$args);
940 }
941 0 $self->_add("EM" . $input_place, $html_event_listener . GS . $method_name . $args_join);
942 }
943
944 0 ▶sub set_module_method_event {
Subroutine set_module_method_event: not called CC=4 SCAR=30.0
Pod undocumented
945 0 my ($self, $input_place, $html_event, $method_name, $args) = @_;
946 0 my $args_join = "";
947 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
948 0 $args_join = GS . "[" . join(US, @$args);
949 }
950 0 $self->_add("Ex" . $input_place, $html_event . GS . $method_name . $args_join);
951 }
952
953 0 ▶sub set_module_method_event_listener {
Subroutine set_module_method_event_listener: not called CC=4 SCAR=30.0
Pod undocumented
954 0 my ($self, $input_place, $html_event_listener, $method_name, $args) = @_;
955 0 my $args_join = "";
956 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
957 0 $args_join = GS . "[" . join(US, @$args);
958 }
959 0 $self->_add("EX" . $input_place, $html_event_listener . GS . $method_name . $args_join);
960 }
961
962 0 ▶sub assign_confirm_event {
Subroutine assign_confirm_event: not called CC=11 SCAR=48.8
Pod undocumented
963 0 my ($self, $input_place, $html_event, $text, $type, $title, $ok_text, $cancel_text) = @_;
964 0 ▶ $text = "Are you sure you want to proceed?" if !defined $text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $text 0 0 0
965 0 ▶ $type = "none" if !defined $type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $type 0 0 0
966 0 ▶ $title = "Confirm" if !defined $title;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $title 0 0 0
967 0 ▶ $ok_text = "OK" if !defined $ok_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $ok_text 0 0 0
968 0 ▶ $cancel_text = "Cancel" if !defined $cancel_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $cancel_text 0 0 0
969
970 0 ▶ my $text_part = ($text eq "Are you sure you want to proceed?" ? "" : $text);
Branch: 1 branch
BranchTrueFalseTotal
$text eq 'Are you sure you want to proceed?' ? : 0 0 0
971 0 ▶ my $type_part = ($type eq "none" ? "" : $type);
Branch: 1 branch
BranchTrueFalseTotal
$type eq 'none' ? : 0 0 0
972 0 ▶ my $title_part = ($title eq "Confirm" ? "" : $title);
Branch: 1 branch
BranchTrueFalseTotal
$title eq 'Confirm' ? : 0 0 0
973 0 ▶ my $ok_part = ($ok_text eq "OK" ? "" : $ok_text);
Branch: 1 branch
BranchTrueFalseTotal
$ok_text eq 'OK' ? : 0 0 0
974 0 ▶ my $cancel_part = ($cancel_text eq "Cancel" ? "" : $cancel_text);
Branch: 1 branch
BranchTrueFalseTotal
$cancel_text eq 'Cancel' ? : 0 0 0
975
976 0 $self->_add("Ef" . $input_place, $html_event . GS . $text_part . GS . $type_part . GS . $title_part . GS . $ok_part . GS . $cancel_part);
977 }
978
979 0 ▶sub remove_post_event {
Subroutine remove_post_event: not called CC=1 SCAR=6.9
Pod undocumented
980 0 my ($self, $input_place, $html_event) = @_;
981 0 $self->_add("Rp" . $input_place, $html_event);
982 }
983
984 0 ▶sub remove_post_event_listener {
Subroutine remove_post_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
985 0 my ($self, $input_place, $html_event_listener) = @_;
986 0 $self->_add("RP" . $input_place, $html_event_listener);
987 }
988
989 0 ▶sub remove_get_event {
Subroutine remove_get_event: not called CC=1 SCAR=6.9
Pod undocumented
990 0 my ($self, $input_place, $html_event) = @_;
991 0 $self->_add("Rg" . $input_place, $html_event);
992 }
993
994 0 ▶sub remove_get_event_listener {
Subroutine remove_get_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
995 0 my ($self, $input_place, $html_event_listener) = @_;
996 0 $self->_add("RG" . $input_place, $html_event_listener);
997 }
998
999 0 ▶sub remove_put_event {
Subroutine remove_put_event: not called CC=1 SCAR=6.9
Pod undocumented
1000 0 my ($self, $input_place, $html_event) = @_;
1001 0 $self->_add("Rt" . $input_place, $html_event);
1002 }
1003
1004 0 ▶sub remove_put_event_listener {
Subroutine remove_put_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1005 0 my ($self, $input_place, $html_event_listener) = @_;
1006 0 $self->_add("RT" . $input_place, $html_event_listener);
1007 }
1008
1009 0 ▶sub remove_patch_event {
Subroutine remove_patch_event: not called CC=1 SCAR=6.9
Pod undocumented
1010 0 my ($self, $input_place, $html_event) = @_;
1011 0 $self->_add("Ra" . $input_place, $html_event);
1012 }
1013
1014 0 ▶sub remove_patch_event_listener {
Subroutine remove_patch_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1015 0 my ($self, $input_place, $html_event_listener) = @_;
1016 0 $self->_add("RA" . $input_place, $html_event_listener);
1017 }
1018
1019 0 ▶sub remove_delete_event {
Subroutine remove_delete_event: not called CC=1 SCAR=6.9
Pod undocumented
1020 0 my ($self, $input_place, $html_event) = @_;
1021 0 $self->_add("Rl" . $input_place, $html_event);
1022 }
1023
1024 0 ▶sub remove_delete_event_listener {
Subroutine remove_delete_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1025 0 my ($self, $input_place, $html_event_listener) = @_;
1026 0 $self->_add("RL" . $input_place, $html_event_listener);
1027 }
1028
1029 0 ▶sub remove_options_event {
Subroutine remove_options_event: not called CC=1 SCAR=6.9
Pod undocumented
1030 0 my ($self, $input_place, $html_event) = @_;
1031 0 $self->_add("Ro" . $input_place, $html_event);
1032 }
1033
1034 0 ▶sub remove_options_event_listener {
Subroutine remove_options_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1035 0 my ($self, $input_place, $html_event_listener) = @_;
1036 0 $self->_add("RO" . $input_place, $html_event_listener);
1037 }
1038
1039 0 ▶sub remove_head_event {
Subroutine remove_head_event: not called CC=1 SCAR=6.9
Pod undocumented
1040 0 my ($self, $input_place, $html_event) = @_;
1041 0 $self->_add("Rh" . $input_place, $html_event);
1042 }
1043
1044 0 ▶sub remove_head_event_listener {
Subroutine remove_head_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1045 0 my ($self, $input_place, $html_event_listener) = @_;
1046 0 $self->_add("RH" . $input_place, $html_event_listener);
1047 }
1048
1049 0 ▶sub remove_send_event {
Subroutine remove_send_event: not called CC=1 SCAR=6.9
Pod undocumented
1050 0 my ($self, $input_place, $html_event) = @_;
1051 0 $self->_add("Rn" . $input_place, $html_event);
1052 }
1053
1054 0 ▶sub remove_send_event_listener {
Subroutine remove_send_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1055 0 my ($self, $input_place, $html_event_listener) = @_;
1056 0 $self->_add("RN" . $input_place, $html_event_listener);
1057 }
1058
1059 0 ▶sub remove_comment_event {
Subroutine remove_comment_event: not called CC=1 SCAR=6.9
Pod undocumented
1060 0 my ($self, $input_place, $html_event) = @_;
1061 0 $self->_add("Rb" . $input_place, $html_event);
1062 }
1063
1064 0 ▶sub remove_comment_event_listener {
Subroutine remove_comment_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1065 0 my ($self, $input_place, $html_event_listener) = @_;
1066 0 $self->_add("RB" . $input_place, $html_event_listener);
1067 }
1068
1069 0 ▶sub remove_wasm_event {
Subroutine remove_wasm_event: not called CC=1 SCAR=6.9
Pod undocumented
1070 0 my ($self, $input_place, $html_event) = @_;
1071 0 $self->_add("Ry" . $input_place, $html_event);
1072 }
1073
1074 0 ▶sub remove_wasm_event_listener {
Subroutine remove_wasm_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1075 0 my ($self, $input_place, $html_event_listener) = @_;
1076 0 $self->_add("RY" . $input_place, $html_event_listener);
1077 }
1078
1079 0 ▶sub remove_web_socket_event {
Subroutine remove_web_socket_event: not called CC=1 SCAR=6.9
Pod undocumented
1080 0 my ($self, $input_place, $html_event) = @_;
1081 0 $self->_add("Rw" . $input_place, $html_event);
1082 }
1083
1084 0 ▶sub remove_web_socket_event_listener {
Subroutine remove_web_socket_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1085 0 my ($self, $input_place, $html_event_listener) = @_;
1086 0 $self->_add("RW" . $input_place, $html_event_listener);
1087 }
1088
1089 0 ▶sub remove_sse_event {
Subroutine remove_sse_event: not called CC=1 SCAR=6.9
Pod undocumented
1090 0 my ($self, $input_place, $html_event) = @_;
1091 0 $self->_add("Re" . $input_place, $html_event);
1092 }
1093
1094 0 ▶sub remove_sse_event_listener {
Subroutine remove_sse_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1095 0 my ($self, $input_place, $html_event_listener) = @_;
1096 0 $self->_add("RE" . $input_place, $html_event_listener);
1097 }
1098
1099 0 ▶sub remove_front_event {
Subroutine remove_front_event: not called CC=1 SCAR=6.9
Pod undocumented
1100 0 my ($self, $input_place, $html_event) = @_;
1101 0 $self->_add("Rj" . $input_place, $html_event);
1102 }
1103
1104 0 ▶sub remove_front_event_listener {
Subroutine remove_front_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1105 0 my ($self, $input_place, $html_event_listener) = @_;
1106 0 $self->_add("RJ" . $input_place, $html_event_listener);
1107 }
1108
1109 0 ▶sub remove_prevent_default_event {
Subroutine remove_prevent_default_event: not called CC=1 SCAR=6.9
Pod undocumented
1110 0 my ($self, $input_place, $html_event) = @_;
1111 0 $self->_add("Rd" . $input_place, $html_event);
1112 }
1113
1114 0 ▶sub remove_prevent_default_event_listener {
Subroutine remove_prevent_default_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1115 0 my ($self, $input_place, $html_event_listener) = @_;
1116 0 $self->_add("RD" . $input_place, $html_event_listener);
1117 }
1118
1119 0 ▶sub remove_master_pages_event {
Subroutine remove_master_pages_event: not called CC=1 SCAR=6.9
Pod undocumented
1120 0 my ($self, $input_place, $html_event) = @_;
1121 0 $self->_add("Ru" . $input_place, $html_event);
1122 }
1123
1124 0 ▶sub remove_master_pages_event_listener {
Subroutine remove_master_pages_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1125 0 my ($self, $input_place, $html_event_listener) = @_;
1126 0 $self->_add("RU" . $input_place, $html_event_listener);
1127 }
1128
1129 0 ▶sub remove_stop_propagation_event {
Subroutine remove_stop_propagation_event: not called CC=1 SCAR=6.9
Pod undocumented
1130 0 my ($self, $input_place, $html_event) = @_;
1131 0 $self->_add("Rs" . $input_place, $html_event);
1132 }
1133
1134 0 ▶sub remove_stop_propagation_event_listener {
Subroutine remove_stop_propagation_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1135 0 my ($self, $input_place, $html_event_listener) = @_;
1136 0 $self->_add("RS" . $input_place, $html_event_listener);
1137 }
1138
1139 0 ▶sub remove_method_event {
Subroutine remove_method_event: not called CC=1 SCAR=6.9
Pod undocumented
1140 0 my ($self, $input_place, $html_event, $method_name) = @_;
1141 0 $self->_add("Rm" . $input_place, $html_event . GS . $method_name);
1142 }
1143
1144 0 ▶sub remove_method_event_listener {
Subroutine remove_method_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1145 0 my ($self, $input_place, $html_event_listener, $method_name) = @_;
1146 0 $self->_add("RM" . $input_place, $html_event_listener . GS . $method_name);
1147 }
1148
1149 0 ▶sub remove_module_method_event {
Subroutine remove_module_method_event: not called CC=1 SCAR=6.9
Pod undocumented
1150 0 my ($self, $input_place, $html_event, $method_name) = @_;
1151 0 $self->_add("Rx" . $input_place, $html_event . GS . $method_name);
1152 }
1153
1154 0 ▶sub remove_module_method_event_listener {
Subroutine remove_module_method_event_listener: not called CC=1 SCAR=6.9
Pod undocumented
1155 0 my ($self, $input_place, $html_event_listener, $method_name) = @_;
1156 0 $self->_add("RX" . $input_place, $html_event_listener . GS . $method_name);
1157 }
1158
1159 0 ▶sub remove_confirm_event {
Subroutine remove_confirm_event: not called CC=1 SCAR=6.9
Pod undocumented
1160 0 my ($self, $input_place, $html_event) = @_;
1161 0 $self->_add("Rf" . $input_place, $html_event);
1162 }
1163
1164 # Custom Event
1165 # This Method Is Compatible With EventListener And May Not Be Compatible With Events Written As Attributes In Some Browsers.
1166 # Watch: attribute, style, text, children, value
1167 # Compare: greater, less, equal, notequal, includes, startswith, endswith, matches, changed, inrange, lengthgreater, lengthless, lengthequal
1168 # Range: Only Use For Compare With inrange Value. Split By Comma ","
1169 # Key: Only Use For Watch With attribute And style Value
1170 0 ▶sub create_custom_dom_event {
Subroutine create_custom_dom_event: not called CC=4 SCAR=30.0
Pod undocumented
1171 0 my ($self, $input_place, $event_name, $watch, $key, $compare, $value, $range, $immediate, $delay) = @_;
1172 0 ▶ $immediate = 0 if !defined $immediate;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $immediate 0 0 0
1173 0 ▶ $delay = "0" if !defined $delay;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $delay 0 0 0
1174 0 ▶ $self->_add("eC" . $input_place, $event_name . GS . $watch . GS . $key . GS . $compare . GS . $value . GS . $range . GS . ($immediate ? "1" : "0") . GS . $delay);
Branch: 1 branch
BranchTrueFalseTotal
$immediate ? : 0 0 0
1175 }
1176
1177 0 ▶sub enable_scroll_bottom_event {
Subroutine enable_scroll_bottom_event: not called CC=3 SCAR=24.8
Pod undocumented
1178 0 my ($self, $enable) = @_;
1179 0 ▶ $enable = 1 if !defined $enable;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $enable 0 0 0
1180 0 ▶ $self->_add("eb", $enable ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$enable ? : 0 0 0
1181 }
1182
1183 0 ▶sub enable_reached_element_event {
Subroutine enable_reached_element_event: not called CC=4 SCAR=30.0
Pod undocumented
1184 0 my ($self, $input_place, $once, $enable) = @_;
1185 0 ▶ $enable = 1 if !defined $enable;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $enable 0 0 0
1186 0 ▶ $self->_add("er" . $input_place, ($once ? "1" : "0") . GS . ($enable ? "1" : "0"));
Branch: 2 branches
BranchTrueFalseTotal
$once ? : 0 0 0
$enable ? : 0 0 0
1187 }
1188
1189 # Module
1190 0 ▶sub load_module {
Subroutine load_module: not called CC=3 SCAR=24.8
Pod undocumented
1191 0 my ($self, $module_path, $methods) = @_;
1192 0 ▶ $methods = [] if !defined $methods;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $methods 0 0 0
1193 0 ▶ my $methods_part = (scalar(@$methods) > 0) ? GS . "[" . join(US, @$methods) : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @$methods > 0 ? : 0 0 0
1194 0 $self->_add("Ml", $module_path . $methods_part);
1195 }
1196
1197 0 ▶sub unload_module {
Subroutine unload_module: not called CC=1 SCAR=6.9
Pod undocumented
1198 0 my ($self, $module_path) = @_;
1199 0 $self->_add("Mu", $module_path);
1200 }
1201
1202 0 ▶sub delete_module_method {
Subroutine delete_module_method: not called CC=1 SCAR=6.9
Pod undocumented
1203 0 my ($self, $method_name) = @_;
1204 0 $self->_add("Md", $method_name);
1205 }
1206
1207 # Unit Testing
1208 # InputPlace Is Actual, Expected Is Tag/OutputPlace
1209 0 ▶sub assert_equal {
Subroutine assert_equal: not called CC=1 SCAR=6.9
Pod undocumented
1210 0 my ($self, $input_place, $tag) = @_;
1211 0 $tag =~ s/\n/\$[ln];/g;
1212 0 $self->_add("At" . $input_place, $tag);
1213 }
1214
1215 0 ▶sub assert_equal_by_output_place {
Subroutine assert_equal_by_output_place: not called CC=1 SCAR=6.9
Pod undocumented
1216 0 my ($self, $input_place, $output_place) = @_;
1217 0 $self->_add("Ao" . $input_place, $output_place);
1218 }
1219
1220 # Debug
1221 0 ▶sub create_debugger {
Subroutine create_debugger: not called CC=3 SCAR=24.8
Pod undocumented
1222 0 my ($self, $pause) = @_;
1223 0 ▶ $pause = 0 if !defined $pause;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $pause 0 0 0
1224 0 ▶ $self->_add("Dc", $pause ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$pause ? : 0 0 0
1225 }
1226
1227 # Service Worker
1228 # To Use Service Worker, You Need To Add The Elanat Dedicated Module (service-worker.js) On The Client Side
1229 0 ▶sub service_worker_register {
Subroutine service_worker_register: not called CC=3 SCAR=24.8
Pod undocumented
1230 0 my ($self, $path, $scope_path) = @_;
1231 0 ▶ $path = "" if !defined $path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $path 0 0 0
1232 0 ▶ $scope_path = "" if !defined $scope_path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $scope_path 0 0 0
1233 0 $self->_add("wR", $path . GS . $scope_path);
1234 }
1235
1236 0 ▶sub service_worker_pre_cache_static {
Subroutine service_worker_pre_cache_static: not called CC=1 SCAR=6.9
Pod undocumented
1237 0 my ($self, $path_list) = @_;
1238 0 $self->_add("wp", join(GS, @$path_list));
1239 }
1240
1241 0 ▶sub service_worker_dynamic_cache {
Subroutine service_worker_dynamic_cache: not called CC=3 SCAR=24.8
Pod undocumented
1242 0 my ($self, $path, $seconds) = @_;
1243 0 ▶ $seconds = "" if !defined $seconds;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $seconds 0 0 0
1244 0 ▶ $self->_add("wc", $path . ($seconds ne "" ? GS . $seconds : ""));
Branch: 1 branch
BranchTrueFalseTotal
$seconds ne '' ? : 0 0 0
1245 }
1246
1247 0 ▶sub service_worker_delete_dynamic_cache {
Subroutine service_worker_delete_dynamic_cache: not called CC=2 SCAR=17.9
Pod undocumented
1248 0 my ($self, $path) = @_;
1249 0 ▶ if (!defined $path) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $path) { } 0 0 0
1250 0 $self->_add("wd");
1251 } else {
1252 0 $self->_add("wd", $path);
1253 }
1254 }
1255
1256 0 ▶sub service_worker_dynamic_cache_ttl_update {
Subroutine service_worker_dynamic_cache_ttl_update: not called CC=3 SCAR=24.8
Pod undocumented
1257 0 my ($self, $path, $seconds) = @_;
1258 0 ▶ $seconds = "" if !defined $seconds;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $seconds 0 0 0
1259 0 ▶ $self->_add("wt", $path . ($seconds ne "" ? GS . $seconds : ""));
Branch: 1 branch
BranchTrueFalseTotal
$seconds ne '' ? : 0 0 0
1260 }
1261
1262 # Path: Support Wildcard Automatically And Also Support Regex If Use "re:" Before Pattern
1263 # Type: Type Is Cache Strategy. cachefirst, networkfirst, cacheonly, networkonly, stalerevalidate (Fast From Cache, Updates Simultaneously From The Network)
1264 # CacheDynamic: If True, Any Successful Network Response For That Route Will Be Stored In The Dynamic Cache
1265 0 ▶sub service_worker_route_set {
Subroutine service_worker_route_set: not called CC=3 SCAR=24.8
Pod undocumented
1266 0 my ($self, $path, $type, $cache_dynamic) = @_;
1267 0 ▶ $cache_dynamic = 0 if !defined $cache_dynamic;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $cache_dynamic 0 0 0
1268 0 ▶ $self->_add("wr", $path . GS . $type . ($cache_dynamic ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$cache_dynamic ? : 0 0 0
1269 }
1270
1271 0 ▶sub service_worker_route_alias {
Subroutine service_worker_route_alias: not called CC=1 SCAR=6.9
Pod undocumented
1272 0 my ($self, $path, $to) = @_;
1273 0 $self->_add("wa", $path . GS . $to);
1274 }
1275
1276 0 ▶sub service_worker_delete_route_alias {
Subroutine service_worker_delete_route_alias: not called CC=2 SCAR=17.9
Pod undocumented
1277 0 my ($self, $path) = @_;
1278 0 ▶ $path = "" if !defined $path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $path 0 0 0
1279 0 $self->_add("wC", $path);
1280 }
1281
1282 # Delete All Route And Alias
1283 0 ▶sub service_worker_delete_route {
Subroutine service_worker_delete_route: not called CC=2 SCAR=17.9
Pod undocumented
1284 0 my ($self, $path) = @_;
1285 0 ▶ if (!defined $path) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $path) { } 0 0 0
1286 0 $self->_add("wD");
1287 } else {
1288 0 $self->_add("wD", $path);
1289 }
1290 }
1291
1292 # SSE
1293 0 ▶sub disconnect_sse {
Subroutine disconnect_sse: not called CC=2 SCAR=17.9
Pod undocumented
1294 0 my ($self, $path) = @_;
1295 0 ▶ if (!defined $path) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $path) { } 0 0 0
1296 0 $self->_add("Ds");
1297 } else {
1298 0 $self->_add("Ds", $path);
1299 }
1300 }
1301
1302 0 ▶sub disconnect_all_sse {
Subroutine disconnect_all_sse: not called CC=1 SCAR=6.9
Pod undocumented
1303 0 my ($self) = @_;
1304 0 $self->_add("Ds");
1305 }
1306
1307 # State
1308 0 ▶sub add_state {
Subroutine add_state: not called CC=3 SCAR=24.8
Pod undocumented
1309 0 my ($self, $path, $title) = @_;
1310 0 ▶ $path = "" if !defined $path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $path 0 0 0
1311 0 ▶ $title = "" if !defined $title;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $title 0 0 0
1312 0 $self->_add("AS", $path . GS . $title);
1313 }
1314
1315 0 ▶sub save_state {
Subroutine save_state: not called CC=3 SCAR=24.8
Pod undocumented
1316 0 my ($self, $path, $title) = @_;
1317 0 ▶ $path = "" if !defined $path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $path 0 0 0
1318 0 ▶ $title = "" if !defined $title;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $title 0 0 0
1319 0 $self->_add("As", $path . GS . $title);
1320 }
1321
1322 0 ▶sub load_state {
Subroutine load_state: not called CC=1 SCAR=6.9
Pod undocumented
1323 0 my ($self, $path) = @_;
1324 0 $self->_add("ls", $path);
1325 }
1326
1327 0 ▶sub delete_state {
Subroutine delete_state: not called CC=3 SCAR=24.8
Pod undocumented
1328 0 my ($self, $path) = @_;
1329 0 ▶ if (!defined $path) {
Branch: 2 branches
BranchTrueFalseTotal
if (not defined $path) { } 0 0 0
elsif ($path eq '*') { } 0 0 0
1330 0 $self->_add("DS");
1331 } elsif ($path eq "*") {
1332 0 $self->_add("DS", "*");
1333 } else {
1334 0 $self->_add("DS", $path);
1335 }
1336 }
1337
1338 0 ▶sub delete_all_state {
Subroutine delete_all_state: not called CC=1 SCAR=6.9
Pod undocumented
1339 0 my ($self) = @_;
1340 0 $self->_add("DS", "*");
1341 }
1342
1343 # Cookie
1344 0 ▶sub set_cookie {
Subroutine set_cookie: not called CC=3 SCAR=24.8
Pod undocumented
1345 0 my ($self, $key, $value, $seconds, $path) = @_;
1346 0 ▶ $path = "" if !defined $path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $path 0 0 0
1347 0 ▶ $self->_add("sC", $key . GS . $value . GS . "$seconds" . ($path ne "" ? GS . $path : ""));
Branch: 1 branch
BranchTrueFalseTotal
$path ne '' ? : 0 0 0
1348 }
1349
1350 # Save (Session Cache)
1351 0 ▶sub save_id {
Subroutine save_id: not called CC=2 SCAR=17.9
Pod undocumented
1352 0 my ($self, $input_place, $key) = @_;
1353 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1354 0 $self->_add('@gi' . $input_place, $key);
1355 }
1356
1357 0 ▶sub save_name {
Subroutine save_name: not called CC=2 SCAR=17.9
Pod undocumented
1358 0 my ($self, $input_place, $key) = @_;
1359 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1360 0 $self->_add('@gn' . $input_place, $key);
1361 }
1362
1363 0 ▶sub save_value {
Subroutine save_value: not called CC=2 SCAR=17.9
Pod undocumented
1364 0 my ($self, $input_place, $key) = @_;
1365 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1366 0 $self->_add('@gv' . $input_place, $key);
1367 }
1368
1369 0 ▶sub save_value_length {
Subroutine save_value_length: not called CC=2 SCAR=17.9
Pod undocumented
1370 0 my ($self, $input_place, $key) = @_;
1371 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1372 0 $self->_add('@ge' . $input_place, $key);
1373 }
1374
1375 0 ▶sub save_class {
Subroutine save_class: not called CC=2 SCAR=17.9
Pod undocumented
1376 0 my ($self, $input_place, $key) = @_;
1377 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1378 0 $self->_add('@gc' . $input_place, $key);
1379 }
1380
1381 0 ▶sub save_style {
Subroutine save_style: not called CC=2 SCAR=17.9
Pod undocumented
1382 0 my ($self, $input_place, $key) = @_;
1383 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1384 0 $self->_add('@gs' . $input_place, $key);
1385 }
1386
1387 0 ▶sub save_title {
Subroutine save_title: not called CC=2 SCAR=17.9
Pod undocumented
1388 0 my ($self, $input_place, $key) = @_;
1389 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1390 0 $self->_add('@gl' . $input_place, $key);
1391 }
1392
1393 0 ▶sub save_label {
Subroutine save_label: not called CC=2 SCAR=17.9
Pod undocumented
1394 0 my ($self, $input_place, $key) = @_;
1395 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1396 0 $self->_add('@gA' . $input_place, $key);
1397 }
1398
1399 0 ▶sub save_text {
Subroutine save_text: not called CC=2 SCAR=17.9
Pod undocumented
1400 0 my ($self, $input_place, $key) = @_;
1401 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1402 0 $self->_add('@gt' . $input_place, $key);
1403 }
1404
1405 0 ▶sub save_outer_text {
Subroutine save_outer_text: not called CC=2 SCAR=17.9
Pod undocumented
1406 0 my ($self, $input_place, $key) = @_;
1407 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1408 0 $self->_add('@go' . $input_place, $key);
1409 }
1410
1411 0 ▶sub save_text_length {
Subroutine save_text_length: not called CC=2 SCAR=17.9
Pod undocumented
1412 0 my ($self, $input_place, $key) = @_;
1413 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1414 0 $self->_add('@gg' . $input_place, $key);
1415 }
1416
1417 0 ▶sub save_attribute {
Subroutine save_attribute: not called CC=2 SCAR=17.9
Pod undocumented
1418 0 my ($self, $input_place, $attribute, $key) = @_;
1419 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1420 0 $self->_add('@ga' . $input_place, $key . GS . $attribute);
1421 }
1422
1423 0 ▶sub save_width {
Subroutine save_width: not called CC=2 SCAR=17.9
Pod undocumented
1424 0 my ($self, $input_place, $key) = @_;
1425 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1426 0 $self->_add('@gw' . $input_place, $key);
1427 }
1428
1429 0 ▶sub save_height {
Subroutine save_height: not called CC=2 SCAR=17.9
Pod undocumented
1430 0 my ($self, $input_place, $key) = @_;
1431 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1432 0 $self->_add('@gh' . $input_place, $key);
1433 }
1434
1435 0 ▶sub save_read_only {
Subroutine save_read_only: not called CC=2 SCAR=17.9
Pod undocumented
1436 0 my ($self, $input_place, $key) = @_;
1437 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1438 0 $self->_add('@gr' . $input_place, $key);
1439 }
1440
1441 0 ▶sub save_selected_index {
Subroutine save_selected_index: not called CC=2 SCAR=17.9
Pod undocumented
1442 0 my ($self, $input_place, $key) = @_;
1443 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1444 0 $self->_add('@gx' . $input_place, $key);
1445 }
1446
1447 0 ▶sub save_text_align {
Subroutine save_text_align: not called CC=2 SCAR=17.9
Pod undocumented
1448 0 my ($self, $input_place, $key) = @_;
1449 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1450 0 $self->_add('@gT' . $input_place, $key);
1451 }
1452
1453 0 ▶sub save_node_length {
Subroutine save_node_length: not called CC=2 SCAR=17.9
Pod undocumented
1454 0 my ($self, $input_place, $key) = @_;
1455 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1456 0 $self->_add('@gL' . $input_place, $key);
1457 }
1458
1459 0 ▶sub save_visible {
Subroutine save_visible: not called CC=2 SCAR=17.9
Pod undocumented
1460 0 my ($self, $input_place, $key) = @_;
1461 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1462 0 $self->_add('@gV' . $input_place, $key);
1463 }
1464
1465 0 ▶sub save_url {
Subroutine save_url: not called CC=4 SCAR=30.0
Pod undocumented
1466 0 my ($self, $url, $fetch_script, $key) = @_;
1467 0 ▶ $fetch_script = 0 if !defined $fetch_script;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $fetch_script 0 0 0
1468 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1469 0 ▶ $self->_add('@gu', $key . GS . $url . ($fetch_script ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$fetch_script ? : 0 0 0
1470 }
1471
1472 0 ▶sub save_index {
Subroutine save_index: not called CC=2 SCAR=17.9
Pod undocumented
1473 0 my ($self, $input_place, $key) = @_;
1474 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1475 0 $self->_add('@gI' . $input_place, $key);
1476 }
1477
1478 0 ▶sub remove_save {
Subroutine remove_save: not called CC=1 SCAR=6.9
Pod undocumented
1479 0 my ($self, $cache_key) = @_;
1480 0 $self->_add("rs", $cache_key);
1481 }
1482
1483 0 ▶sub remove_all_save {
Subroutine remove_all_save: not called CC=1 SCAR=6.9
Pod undocumented
1484 0 my ($self) = @_;
1485 0 $self->_add("rs", "*");
1486 }
1487
1488 # Calling the SetSave Method Causes Action Control Requests Triggered by Events Using the GET, POST, PUT, PATCH, DELETE, and OPTIONS Methods, as well as Requests Triggered by the Send Event, to be Temporarily Saved on the Active Page, so the Request will not be Sent to the Server Again.
1489 0 ▶sub set_save {
Subroutine set_save: not called CC=1 SCAR=6.9
Pod undocumented
1490 0 my ($self) = @_;
1491 0 $self->_add("cs", "*");
1492 }
1493
1494 0 ▶sub add_save_value {
Subroutine add_save_value: not called CC=1 SCAR=6.9
Pod undocumented
1495 0 my ($self, $cache_key, $value) = @_;
1496 0 $value =~ s/\n/\$[ln];/g;
1497 0 $self->_add("SA", $cache_key . GS . $value);
1498 }
1499
1500 0 ▶sub insert_save_value {
Subroutine insert_save_value: not called CC=1 SCAR=6.9
Pod undocumented
1501 0 my ($self, $cache_key, $value) = @_;
1502 0 $value =~ s/\n/\$[ln];/g;
1503 0 $self->_add("SI", $cache_key . GS . $value);
1504 }
1505
1506 0 ▶sub append_save_value {
Subroutine append_save_value: not called CC=1 SCAR=6.9
Pod undocumented
1507 0 my ($self, $cache_key, $value) = @_;
1508 0 $value =~ s/\n/\$[ln];/g;
1509 0 $self->_add("SP", $cache_key . GS . $value);
1510 }
1511
1512 0 ▶sub replace_save_value {
Subroutine replace_save_value: not called CC=1 SCAR=6.9
Pod undocumented
1513 0 my ($self, $cache_key, $search_value, $value) = @_;
1514 0 my $val_clean = $value;
1515 0 $val_clean =~ s/\n/\$[ln];/g;
1516 0 my $search_clean = $search_value;
1517 0 $search_clean =~ s/\n/\$[ln];/g;
1518 0 $self->_add("SR", $cache_key . GS . $val_clean . GS . $search_clean);
1519 }
1520
1521 # Cache
1522 0 ▶sub cache_id {
Subroutine cache_id: not called CC=2 SCAR=17.9
Pod undocumented
1523 0 my ($self, $input_place, $key) = @_;
1524 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1525 0 $self->_add('@ci' . $input_place, $key);
1526 }
1527
1528 0 ▶sub cache_name {
Subroutine cache_name: not called CC=2 SCAR=17.9
Pod undocumented
1529 0 my ($self, $input_place, $key) = @_;
1530 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1531 0 $self->_add('@cn' . $input_place, $key);
1532 }
1533
1534 0 ▶sub cache_value {
Subroutine cache_value: not called CC=2 SCAR=17.9
Pod undocumented
1535 0 my ($self, $input_place, $key) = @_;
1536 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1537 0 $self->_add('@cv' . $input_place, $key);
1538 }
1539
1540 0 ▶sub cache_value_length {
Subroutine cache_value_length: not called CC=2 SCAR=17.9
Pod undocumented
1541 0 my ($self, $input_place, $key) = @_;
1542 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1543 0 $self->_add('@ce' . $input_place, $key);
1544 }
1545
1546 0 ▶sub cache_class {
Subroutine cache_class: not called CC=2 SCAR=17.9
Pod undocumented
1547 0 my ($self, $input_place, $key) = @_;
1548 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1549 0 $self->_add('@cc' . $input_place, $key);
1550 }
1551
1552 0 ▶sub cache_style {
Subroutine cache_style: not called CC=2 SCAR=17.9
Pod undocumented
1553 0 my ($self, $input_place, $key) = @_;
1554 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1555 0 $self->_add('@cs' . $input_place, $key);
1556 }
1557
1558 0 ▶sub cache_title {
Subroutine cache_title: not called CC=2 SCAR=17.9
Pod undocumented
1559 0 my ($self, $input_place, $key) = @_;
1560 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1561 0 $self->_add('@cl' . $input_place, $key);
1562 }
1563
1564 0 ▶sub cache_label {
Subroutine cache_label: not called CC=2 SCAR=17.9
Pod undocumented
1565 0 my ($self, $input_place, $key) = @_;
1566 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1567 0 $self->_add('@cA' . $input_place, $key);
1568 }
1569
1570 0 ▶sub cache_text {
Subroutine cache_text: not called CC=2 SCAR=17.9
Pod undocumented
1571 0 my ($self, $input_place, $key) = @_;
1572 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1573 0 $self->_add('@ct' . $input_place, $key);
1574 }
1575
1576 0 ▶sub cache_outer_text {
Subroutine cache_outer_text: not called CC=2 SCAR=17.9
Pod undocumented
1577 0 my ($self, $input_place, $key) = @_;
1578 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1579 0 $self->_add('@co' . $input_place, $key);
1580 }
1581
1582 0 ▶sub cache_text_length {
Subroutine cache_text_length: not called CC=2 SCAR=17.9
Pod undocumented
1583 0 my ($self, $input_place, $key) = @_;
1584 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1585 0 $self->_add('@cg' . $input_place, $key);
1586 }
1587
1588 0 ▶sub cache_attribute {
Subroutine cache_attribute: not called CC=2 SCAR=17.9
Pod undocumented
1589 0 my ($self, $input_place, $attribute, $key) = @_;
1590 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1591 0 $self->_add('@ca' . $input_place, $key . GS . $attribute);
1592 }
1593
1594 0 ▶sub cache_width {
Subroutine cache_width: not called CC=2 SCAR=17.9
Pod undocumented
1595 0 my ($self, $input_place, $key) = @_;
1596 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1597 0 $self->_add('@cw' . $input_place, $key);
1598 }
1599
1600 0 ▶sub cache_height {
Subroutine cache_height: not called CC=2 SCAR=17.9
Pod undocumented
1601 0 my ($self, $input_place, $key) = @_;
1602 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1603 0 $self->_add('@ch' . $input_place, $key);
1604 }
1605
1606 0 ▶sub cache_read_only {
Subroutine cache_read_only: not called CC=2 SCAR=17.9
Pod undocumented
1607 0 my ($self, $input_place, $key) = @_;
1608 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1609 0 $self->_add('@cr' . $input_place, $key);
1610 }
1611
1612 0 ▶sub cache_selected_index {
Subroutine cache_selected_index: not called CC=2 SCAR=17.9
Pod undocumented
1613 0 my ($self, $input_place, $key) = @_;
1614 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1615 0 $self->_add('@cx' . $input_place, $key);
1616 }
1617
1618 0 ▶sub cache_text_align {
Subroutine cache_text_align: not called CC=2 SCAR=17.9
Pod undocumented
1619 0 my ($self, $input_place, $key) = @_;
1620 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1621 0 $self->_add('@cT' . $input_place, $key);
1622 }
1623
1624 0 ▶sub cache_node_length {
Subroutine cache_node_length: not called CC=2 SCAR=17.9
Pod undocumented
1625 0 my ($self, $input_place, $key) = @_;
1626 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1627 0 $self->_add('@cL' . $input_place, $key);
1628 }
1629
1630 0 ▶sub cache_visible {
Subroutine cache_visible: not called CC=2 SCAR=17.9
Pod undocumented
1631 0 my ($self, $input_place, $key) = @_;
1632 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1633 0 $self->_add('@cV' . $input_place, $key);
1634 }
1635
1636 0 ▶sub cache_url {
Subroutine cache_url: not called CC=4 SCAR=30.0
Pod undocumented
1637 0 my ($self, $url, $fetch_script, $key) = @_;
1638 0 ▶ $fetch_script = 0 if !defined $fetch_script;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $fetch_script 0 0 0
1639 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1640 0 ▶ $self->_add('@cu', $key . GS . $url . ($fetch_script ? GS . "1" : ""));
Branch: 1 branch
BranchTrueFalseTotal
$fetch_script ? : 0 0 0
1641 }
1642
1643 0 ▶sub cache_index {
Subroutine cache_index: not called CC=2 SCAR=17.9
Pod undocumented
1644 0 my ($self, $input_place, $key) = @_;
1645 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
1646 0 $self->_add('@cI' . $input_place, $key);
1647 }
1648
1649 0 ▶sub remove_cache {
Subroutine remove_cache: not called CC=1 SCAR=6.9
Pod undocumented
1650 0 my ($self, $cache_key) = @_;
1651 0 $self->_add("rd", $cache_key);
1652 }
1653
1654 0 ▶sub remove_all_cache {
Subroutine remove_all_cache: not called CC=1 SCAR=6.9
Pod undocumented
1655 0 my ($self) = @_;
1656 0 $self->_add("rd", "*");
1657 }
1658
1659 # Calling the SetCache Method Causes Action Control Requests Triggered by events using the GET, POST, PUT, PATCH, DELETE, and OPTIONS Methods, as well as Requests Triggered by the Send event, to be Cached, so the Request will not be Sent to the Server Again.
1660 0 ▶sub set_cache {
Subroutine set_cache: not called CC=2 SCAR=17.9
Pod undocumented
1661 0 my ($self, $second) = @_;
1662 0 ▶ if (!defined $second) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $second) { } 0 0 0
1663 0 $self->_add("cd", "*");
1664 } else {
1665 0 $self->_add("cd", "$second");
1666 }
1667 }
1668
1669 0 ▶sub add_cache_value {
Subroutine add_cache_value: not called CC=1 SCAR=6.9
Pod undocumented
1670 0 my ($self, $cache_key, $value) = @_;
1671 0 $value =~ s/\n/\$[ln];/g;
1672 0 $self->_add("CA", $cache_key . GS . $value);
1673 }
1674
1675 0 ▶sub insert_cache_value {
Subroutine insert_cache_value: not called CC=1 SCAR=6.9
Pod undocumented
1676 0 my ($self, $cache_key, $value) = @_;
1677 0 $value =~ s/\n/\$[ln];/g;
1678 0 $self->_add("CI", $cache_key . GS . $value);
1679 }
1680
1681 0 ▶sub append_cache_value {
Subroutine append_cache_value: not called CC=1 SCAR=6.9
Pod undocumented
1682 0 my ($self, $cache_key, $value) = @_;
1683 0 $value =~ s/\n/\$[ln];/g;
1684 0 $self->_add("CP", $cache_key . GS . $value);
1685 }
1686
1687 0 ▶sub replace_cache_value {
Subroutine replace_cache_value: not called CC=1 SCAR=6.9
Pod undocumented
1688 0 my ($self, $cache_key, $search_value, $value) = @_;
1689 0 my $val_clean = $value;
1690 0 $val_clean =~ s/\n/\$[ln];/g;
1691 0 my $search_clean = $search_value;
1692 0 $search_clean =~ s/\n/\$[ln];/g;
1693 0 $self->_add("CR", $cache_key . GS . $val_clean . GS . $search_clean);
1694 }
1695
1696 # Call
1697 0 ▶sub load_url {
Subroutine load_url: not called CC=1 SCAR=6.9
Pod undocumented
1698 0 my ($self, $input_place, $url) = @_;
1699 0 $self->_add("lu" . $input_place, $url);
1700 }
1701
1702 0 ▶sub run_action_controls {
Subroutine run_action_controls: not called CC=6 SCAR=37.4
Pod undocumented
1703 0 my ($self, $action_controls, $without_web_forms_section, $index, $use_current_event) = @_;
1704 0 ▶ $without_web_forms_section = 1 if !defined $without_web_forms_section;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $without_web_forms_section 0 0 0
1705 0 ▶ $index = "" if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1706 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1707 0 ▶ $self->_add("lA", ($use_current_event ? "1" : "0") . GS . ($without_web_forms_section ? "1" : "0") . GS . $index . GS . $action_controls);
Branch: 2 branches
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
$without_web_forms_section ? : 0 0 0
1708 }
1709
1710 0 ▶sub call_script {
Subroutine call_script: not called CC=1 SCAR=6.9
Pod undocumented
1711 0 my ($self, $script_text) = @_;
1712 0 $script_text =~ s/\n/\$[ln];/g;
1713 0 $self->_add("_", $script_text);
1714 }
1715
1716 0 ▶sub call_method {
Subroutine call_method: not called CC=4 SCAR=30.0
Pod undocumented
1717 0 my ($self, $method_name, $args) = @_;
1718 0 my $args_join = "";
1719 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
1720 0 $args_join = GS . "[" . join(US, @$args);
1721 }
1722 0 $self->_add("lm", $method_name . $args_join);
1723 }
1724
1725 0 ▶sub call_module_method {
Subroutine call_module_method: not called CC=4 SCAR=30.0
Pod undocumented
1726 0 my ($self, $method_name, $args) = @_;
1727 0 my $args_join = "";
1728 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
1729 0 $args_join = GS . "[" . join(US, @$args);
1730 }
1731 0 $self->_add("lM", $method_name . $args_join);
1732 }
1733
1734 0 ▶sub call_post_back {
Subroutine call_post_back: not called CC=3 SCAR=24.8
Pod undocumented
1735 0 my ($self, $form_input_place, $output_place) = @_;
1736 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1737 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1738 0 $self->_add("Lp", "1" . GS . $form_input_place . $output_part);
1739 }
1740
1741 0 ▶sub call_comment_back {
Subroutine call_comment_back: not called CC=5 SCAR=34.0
Pod undocumented
1742 0 my ($self, $index, $input_place, $use_current_event) = @_;
1743 0 ▶ $index = "" if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1744 0 ▶ $input_place = "" if !defined $input_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $input_place 0 0 0
1745 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1746 0 ▶ $self->_add("LC", ($use_current_event ? "1" : "0") . GS . "$index" . GS . $input_place);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1747 }
1748
1749 0 ▶sub call_wasm_back {
Subroutine call_wasm_back: not called CC=7 SCAR=40.3
Pod undocumented
1750 0 my ($self, $wasm_language, $wasm_url, $method_name, $args, $output_place, $use_current_event) = @_;
1751 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1752 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1753 0 my $args_join = "";
1754 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
1755 0 $args_join = "[" . join(US, @$args);
1756 }
1757 0 ▶ $self->_add("Ly", ($use_current_event ? "1" : "0") . GS . $wasm_language . GS . $wasm_url . GS . $method_name . GS . $args_join . GS . $output_place);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1758 }
1759
1760 0 ▶sub call_web_socket_back {
Subroutine call_web_socket_back: not called CC=3 SCAR=24.8
Pod undocumented
1761 0 my ($self, $path, $use_current_event) = @_;
1762 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1763 0 ▶ $self->_add("Lw", ($use_current_event ? "1" : "0") . GS . $path);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1764 }
1765
1766 0 ▶sub call_sse_back {
Subroutine call_sse_back: not called CC=8 SCAR=42.8
Pod undocumented
1767 0 my ($self, $path, $output_place, $use_current_event, $should_reconnect, $reconnect_try_timeout) = @_;
1768 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1769 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1770 0 ▶ $should_reconnect = 1 if !defined $should_reconnect;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $should_reconnect 0 0 0
1771 0 ▶ $reconnect_try_timeout = "3000" if !defined $reconnect_try_timeout;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $reconnect_try_timeout 0 0 0
1772 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1773 0 ▶ $self->_add("Ls", ($use_current_event ? "1" : "0") . GS . $path . GS . ($should_reconnect ? "1" : "0") . GS . "$reconnect_try_timeout" . $output_part);
Branch: 2 branches
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
$should_reconnect ? : 0 0 0
1774 }
1775
1776 0 ▶sub call_front {
Subroutine call_front: not called CC=7 SCAR=40.3
Pod undocumented
1777 0 my ($self, $module_path, $args, $output_place, $use_current_event) = @_;
1778 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1779 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1780 0 my $args_join = "";
1781 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
1782 0 $args_join = GS . "[" . join(US, @$args);
1783 }
1784 0 ▶ $self->_add("Lj", ($use_current_event ? "1" : "0") . GS . $module_path . GS . $output_place . $args_join);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1785 }
1786
1787 0 ▶sub call_get_back {
Subroutine call_get_back: not called CC=5 SCAR=34.0
Pod undocumented
1788 0 my ($self, $path, $output_place, $use_current_event) = @_;
1789 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1790 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1791 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1792 0 ▶ $self->_add("Lg", ($use_current_event ? "1" : "0") . GS . $path . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1793 }
1794
1795 0 ▶sub call_put_back {
Subroutine call_put_back: not called CC=5 SCAR=34.0
Pod undocumented
1796 0 my ($self, $path, $output_place, $use_current_event) = @_;
1797 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1798 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1799 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1800 0 ▶ $self->_add("Lt", ($use_current_event ? "1" : "0") . GS . $path . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1801 }
1802
1803 0 ▶sub call_patch_back {
Subroutine call_patch_back: not called CC=5 SCAR=34.0
Pod undocumented
1804 0 my ($self, $path, $output_place, $use_current_event) = @_;
1805 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1806 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1807 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1808 0 ▶ $self->_add("LP", ($use_current_event ? "1" : "0") . GS . $path . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1809 }
1810
1811 0 ▶sub call_delete_back {
Subroutine call_delete_back: not called CC=5 SCAR=34.0
Pod undocumented
1812 0 my ($self, $path, $output_place, $use_current_event) = @_;
1813 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1814 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1815 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1816 0 ▶ $self->_add("Ld", ($use_current_event ? "1" : "0") . GS . $path . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1817 }
1818
1819 0 ▶sub call_head_back {
Subroutine call_head_back: not called CC=3 SCAR=24.8
Pod undocumented
1820 0 my ($self, $path, $use_current_event) = @_;
1821 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1822 0 ▶ $self->_add("Lh", ($use_current_event ? "1" : "0") . GS . $path);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1823 }
1824
1825 0 ▶sub call_options_back {
Subroutine call_options_back: not called CC=5 SCAR=34.0
Pod undocumented
1826 0 my ($self, $path, $output_place, $use_current_event) = @_;
1827 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1828 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1829 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1830 0 ▶ $self->_add("Lo", ($use_current_event ? "1" : "0") . GS . $path . $output_part);
Branch: 1 branch
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
1831 }
1832
1833 0 ▶sub call_send_back {
Subroutine call_send_back: not called CC=6 SCAR=37.4
Pod undocumented
1834 0 my ($self, $path, $method, $is_multi_part, $content_type, $data, $output_place, $use_current_event) = @_;
1835 0 ▶ $output_place = "" if !defined $output_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $output_place 0 0 0
1836 0 ▶ $use_current_event = 1 if !defined $use_current_event;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $use_current_event 0 0 0
1837 0 $data =~ s/\n/\$[ln];/g;
1838 0 ▶ my $output_part = ($output_place ne "") ? GS . $output_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$output_place ne '' ? : 0 0 0
1839 0 ▶ $self->_add("LS", ($use_current_event ? "1" : "0") . GS . $path . GS . $method . GS . ($is_multi_part ? "1" : "0") . GS . $content_type . GS . $data . $output_part);
Branch: 2 branches
BranchTrueFalseTotal
$use_current_event ? : 0 0 0
$is_multi_part ? : 0 0 0
1840 }
1841
1842 # Update
1843 0 ▶sub increase {
Subroutine increase: not called CC=1 SCAR=6.9
Pod undocumented
1844 0 my ($self, $input_place, $value) = @_;
1845 0 $self->_add("gt" . $input_place, "i" . GS . "$value");
1846 }
1847
1848 0 ▶sub decrease {
Subroutine decrease: not called CC=1 SCAR=6.9
Pod undocumented
1849 0 my ($self, $input_place, $value) = @_;
1850 0 $self->_add("gt" . $input_place, "i" . GS . ($value * -1));
1851 }
1852
1853 # If You Don't Use Deep Mode, any Tags Inside the Current Tag Will Simply Be Treated as Strings. Deep Mode Does not Remove Inner Elements.
1854 0 ▶sub replace {
Subroutine replace: not called CC=5 SCAR=34.0
Pod undocumented
1855 0 my ($self, $input_place, $value, $new_value, $also_start_tag, $deep) = @_;
1856 0 ▶ $also_start_tag = 0 if !defined $also_start_tag;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $also_start_tag 0 0 0
1857 0 ▶ $deep = 1 if !defined $deep;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $deep 0 0 0
1858 0 ▶ $self->_add("gt" . $input_place, "r" . GS . $value . GS . $new_value . GS . ($also_start_tag ? "1" : "0") . GS . ($deep ? "1" : "0"));
Branch: 2 branches
BranchTrueFalseTotal
$also_start_tag ? : 0 0 0
$deep ? : 0 0 0
1859 }
1860
1861 # HTML Converts Attribute Names to Lowercase, so they Need to Be Written in Lowercase.
1862 0 ▶sub replace_start_tag {
Subroutine replace_start_tag: not called CC=1 SCAR=6.9
Pod undocumented
1863 0 my ($self, $input_place, $value, $new_value) = @_;
1864 0 $self->_add("gt" . $input_place, "s" . GS . $value . GS . $new_value);
1865 }
1866
1867 # Pre Runner
1868 0 ▶sub assign_delay {
Subroutine assign_delay: not called CC=5 SCAR=34.0
Pod undocumented
1869 0 my ($self, $mili_second, $index) = @_;
1870 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1871 0 my $current_line = $self->_get_line_by_index($index);
1872 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
1873
1874 0 my @parts = split(/=/, $current_line, 2);
1875 0 my $new_name = ":" . $mili_second . ")" . $parts[0];
1876 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
1877
1878 0 $self->_update_line_by_index($index, $new_name, $new_value);
1879 }
1880
1881 0 ▶sub assign_delay_change {
Subroutine assign_delay_change: not called CC=7 SCAR=40.3
Pod undocumented
1882 0 my ($self, $mili_second, $index) = @_;
1883 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1884 0 my $current_line = $self->_get_line_by_index($index);
1885 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
1886
1887 0 my @parts = split(/=/, $current_line, 2);
1888 0 my $current_name = $parts[0];
1889
1890 0 ▶ if ($current_name =~ /^:/ && $current_name =~ /\)/) {
Branch: 1 branch
BranchTrueFalseTotal
if ($current_name =~ /^:/u and $current_name =~ /\)/u) 0 0 0
Condition0%0/3
$current_name =~ /^:/u and $current_name =~ /\)/u
!ll&&!rl&&r
000
MC/DC0%0/2
$current_name =~ /^:/u and $current_name =~ /\)/u
$current_name =~ /^:/u $current_name =~ /\)/u
Truth table0%0/3
A and B
A= $current_name =~ /^:/uB= $current_name =~ /\)/u
ABresult
0X0
100
111
1891 0 my $closing_bracket = index($current_name, ')');
1892 0 $current_name = substr($current_name, $closing_bracket + 1);
1893 }
1894
1895 0 my $new_name = ":" . $mili_second . ")" . $current_name;
1896 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
1897
1898 0 $self->_update_line_by_index($index, $new_name, $new_value);
1899 }
1900
1901 0 ▶sub assign_interval {
Subroutine assign_interval: not called CC=7 SCAR=40.3
Pod undocumented
1902 0 my ($self, $mili_second, $id, $index) = @_;
1903 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1904 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
1905 0 my $current_line = $self->_get_line_by_index($index);
1906 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
1907
1908 0 my @parts = split(/=/, $current_line, 2);
1909 0 ▶ my $id_part = ($id ne "") ? "|" . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
1910 0 my $new_name = "(" . $mili_second . $id_part . ")" . $parts[0];
1911 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
1912
1913 0 $self->_update_line_by_index($index, $new_name, $new_value);
1914 }
1915
1916 0 ▶sub assign_interval_change {
Subroutine assign_interval_change: not called CC=9 SCAR=45.0
Pod undocumented
1917 0 my ($self, $mili_second, $id, $index) = @_;
1918 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1919 0 ▶ $id = "" if !defined $id;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $id 0 0 0
1920 0 my $current_line = $self->_get_line_by_index($index);
1921 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
1922
1923 0 my @parts = split(/=/, $current_line, 2);
1924 0 my $current_name = $parts[0];
1925
1926 0 ▶ if ($current_name =~ /^\(/ && $current_name =~ /\)/) {
Branch: 1 branch
BranchTrueFalseTotal
if ($current_name =~ /^\(/u and $current_name =~ /\)/u) 0 0 0
Condition0%0/3
$current_name =~ /^\(/u and $current_name =~ /\)/u
!ll&&!rl&&r
000
MC/DC0%0/2
$current_name =~ /^\(/u and $current_name =~ /\)/u
$current_name =~ /^\(/u $current_name =~ /\)/u
Truth table0%0/3
A and B
A= $current_name =~ /^\(/uB= $current_name =~ /\)/u
ABresult
0X0
100
111
1927 0 my $closing_bracket = index($current_name, ')');
1928 0 $current_name = substr($current_name, $closing_bracket + 1);
1929 }
1930
1931 0 ▶ my $id_part = ($id ne "") ? "|" . $id : "";
Branch: 1 branch
BranchTrueFalseTotal
$id ne '' ? : 0 0 0
1932 0 my $new_name = "(" . $mili_second . $id_part . ")" . $current_name;
1933 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
1934
1935 0 $self->_update_line_by_index($index, $new_name, $new_value);
1936 }
1937
1938 0 ▶sub delete_interval {
Subroutine delete_interval: not called CC=1 SCAR=6.9
Pod undocumented
1939 0 my ($self, $id) = @_;
1940 0 $self->_add("Di", $id);
1941 }
1942
1943 0 ▶sub assign_repeat {
Subroutine assign_repeat: not called CC=5 SCAR=34.0
Pod undocumented
1944 0 my ($self, $count, $index) = @_;
1945 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1946 0 my $current_line = $self->_get_line_by_index($index);
1947 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
1948
1949 0 my @parts = split(/=/, $current_line, 2);
1950 0 my $new_name = "," . $count . ")" . $parts[0];
1951 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
1952
1953 0 $self->_update_line_by_index($index, $new_name, $new_value);
1954 }
1955
1956 0 ▶sub assign_repeat_change {
Subroutine assign_repeat_change: not called CC=7 SCAR=40.3
Pod undocumented
1957 0 my ($self, $count, $index) = @_;
1958 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
1959 0 my $current_line = $self->_get_line_by_index($index);
1960 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
1961
1962 0 my @parts = split(/=/, $current_line, 2);
1963 0 my $current_name = $parts[0];
1964
1965 0 ▶ if ($current_name =~ /^,/ && $current_name =~ /\)/) {
Branch: 1 branch
BranchTrueFalseTotal
if ($current_name =~ /^,/u and $current_name =~ /\)/u) 0 0 0
Condition0%0/3
$current_name =~ /^,/u and $current_name =~ /\)/u
!ll&&!rl&&r
000
MC/DC0%0/2
$current_name =~ /^,/u and $current_name =~ /\)/u
$current_name =~ /^,/u $current_name =~ /\)/u
Truth table0%0/3
A and B
A= $current_name =~ /^,/uB= $current_name =~ /\)/u
ABresult
0X0
100
111
1966 0 my $closing_bracket = index($current_name, ')');
1967 0 $current_name = substr($current_name, $closing_bracket + 1);
1968 }
1969
1970 0 my $new_name = "," . $count . ")" . $current_name;
1971 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
1972
1973 0 $self->_update_line_by_index($index, $new_name, $new_value);
1974 }
1975
1976 # Index
1977 0 ▶sub start_index {
Subroutine start_index: not called CC=2 SCAR=17.9
Pod undocumented
1978 0 my ($self, $name) = @_;
1979 0 ▶ $name = "" if !defined $name;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $name 0 0 0
1980 0 $self->_add("#", $name);
1981 }
1982
1983 # This Index Is Automatically Run After Changing The Browser History (Back And Forward Buttons)
1984 0 ▶sub start_state {
Subroutine start_state: not called CC=1 SCAR=6.9
Pod undocumented
1985 0 my ($self) = @_;
1986 0 $self->start_index('$');
1987 }
1988
1989 0 ▶sub go_to {
Subroutine go_to: not called CC=8 SCAR=42.8
Pod undocumented
1990 0 my ($self, $line, $repeat) = @_;
1991 0 ▶ if (ref($line) eq '' && $line =~ /^-?\d+$/ && ref($repeat) eq '' && $repeat =~ /^-?\d+$/) {
Branch: 2 branches
BranchTrueFalseTotal
if (ref $line eq '' and $line =~ /^-?\d+$/u and ref $repeat eq '' and $repeat =~ /^-?\d+$/u) { } 0 0 0
elsif (ref $repeat eq '' and $repeat =~ /^-?\d+$/u) { } 0 0 0
Condition0%0/9
ref $line eq "" and $line =~ /^-?\d+$/u and ref $repeat eq "" and $repeat =~ /^-?\d+$/u
!ll&&!rl&&r
000
ref $line eq "" and $line =~ /^-?\d+$/u and ref $repeat eq ""
!ll&&!rl&&r
000
ref $line eq "" and $line =~ /^-?\d+$/u
!ll&&!rl&&r
000
MC/DC0%0/4
ref $line eq "" and $line =~ /^-?\d+$/u and ref $repeat eq "" and $repeat =~ /^-?\d+$/u
ref $line eq "" $line =~ /^-?\d+$/u ref $repeat eq "" $repeat =~ /^-?\d+$/u
Truth table0%0/5
A and B and C and D
A= ref $line eq ""B= $line =~ /^-?\d+$/uC= ref $repeat eq ""D= $repeat =~ /^-?\d+$/u
ABCDresult
0XXX0
10XX0
110X0
11100
11111
1992 0 $self->_add("&", "$line" . GS . "$repeat");
1993 ▶ } elsif (ref($repeat) eq '' && $repeat =~ /^-?\d+$/) {
Condition0%0/3
ref $repeat eq "" and $repeat =~ /^-?\d+$/u
!ll&&!rl&&r
000
MC/DC0%0/2
ref $repeat eq "" and $repeat =~ /^-?\d+$/u
ref $repeat eq "" $repeat =~ /^-?\d+$/u
Truth table0%0/3
A and B
A= ref $repeat eq ""B= $repeat =~ /^-?\d+$/u
ABresult
0X0
100
111
1994 0 $self->_add("&", "#" . $line . GS . "$repeat");
1995 } else {
1996 0 ▶ $repeat = 1 if !defined $repeat;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $repeat 0 0 0
1997 0 $self->_add("&", "$line" . GS . "$repeat");
1998 }
1999 }
2000
2001 # Start
2002 0 ▶sub start_transient_dom {
Subroutine start_transient_dom: not called CC=1 SCAR=6.9
Pod undocumented
2003 0 my ($self, $input_place) = @_;
2004 0 $self->_add("td", $input_place);
2005 }
2006
2007 0 ▶sub end_transient_dom {
Subroutine end_transient_dom: not called CC=1 SCAR=6.9
Pod undocumented
2008 0 my ($self) = @_;
2009 0 $self->_add("td", ";");
2010 }
2011
2012 # Message
2013 # Type: warning, problem, help, success, none
2014 0 ▶sub alert {
Subroutine alert: not called CC=7 SCAR=40.3
Pod undocumented
2015 0 my ($self, $text, $type, $title, $ok_text) = @_;
2016 0 ▶ $type = "none" if !defined $type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $type 0 0 0
2017 0 ▶ $title = "Alert" if !defined $title;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $title 0 0 0
2018 0 ▶ $ok_text = "OK" if !defined $ok_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $ok_text 0 0 0
2019 0 ▶ $self->_add("Al", $text . GS . ($type eq "none" ? "" : $type) . GS . ($title eq "Alert" ? "" : $title) . GS . ($ok_text eq "OK" ? "" : $ok_text));
Branch: 3 branches
BranchTrueFalseTotal
$type eq 'none' ? : 0 0 0
$title eq 'Alert' ? : 0 0 0
$ok_text eq 'OK' ? : 0 0 0
2020 }
2021
2022 0 ▶sub message {
Subroutine message: not called CC=11 SCAR=48.8
Pod undocumented
2023 0 my ($self, $text, $type_or_duration, $duration) = @_;
2024 0 ▶ if (ref($type_or_duration) eq '' && $type_or_duration =~ /^-?\d+$/) {
Branch: 2 branches
BranchTrueFalseTotal
if (ref $type_or_duration eq '' and $type_or_duration =~ /^-?\d+$/u) { } 0 0 0
elsif (defined $duration and ref $duration eq '' and $duration =~ /^-?\d+$/u) { } 0 0 0
Condition0%0/3
ref $type_or_duration eq "" and $type_or_duration =~ /^-?\d+$/u
!ll&&!rl&&r
000
MC/DC0%0/2
ref $type_or_duration eq "" and $type_or_duration =~ /^-?\d+$/u
ref $type_or_duration eq "" $type_or_duration =~ /^-?\d+$/u
Truth table0%0/3
A and B
A= ref $type_or_duration eq ""B= $type_or_duration =~ /^-?\d+$/u
ABresult
0X0
100
111
2025 0 $self->_add("me", $text . GS . "" . GS . "$type_or_duration");
2026 ▶ } elsif (defined $duration && ref($duration) eq '' && $duration =~ /^-?\d+$/) {
Condition0%0/6
defined $duration and ref $duration eq "" and $duration =~ /^-?\d+$/u
!ll&&!rl&&r
000
defined $duration and ref $duration eq ""
!ll&&!rl&&r
000
MC/DC0%0/3
defined $duration and ref $duration eq "" and $duration =~ /^-?\d+$/u
defined $duration ref $duration eq "" $duration =~ /^-?\d+$/u
Truth table0%0/4
A and B and C
A= defined $durationB= ref $duration eq ""C= $duration =~ /^-?\d+$/u
ABCresult
0XX0
10X0
1100
1111
2027 0 ▶ $self->_add("me", $text . GS . ($type_or_duration eq "none" ? "" : $type_or_duration) . GS . "$duration");
Branch: 1 branch
BranchTrueFalseTotal
$type_or_duration eq 'none' ? : 0 0 0
2028 } else {
2029 0 ▶ $type_or_duration = "none" if !defined $type_or_duration;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $type_or_duration 0 0 0
2030 0 ▶ $duration = "0" if !defined $duration;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $duration 0 0 0
2031 0 ▶ $self->_add("me", $text . GS . ($type_or_duration eq "none" ? "" : $type_or_duration) . GS . ($duration eq "0" ? "" : $duration));
Branch: 2 branches
BranchTrueFalseTotal
$type_or_duration eq 'none' ? : 0 0 0
$duration eq '0' ? : 0 0 0
2032 }
2033 }
2034
2035 # Type: log, info, warn, error, debug, trace, group, groupend, table
2036 0 ▶sub console_message {
Subroutine console_message: not called CC=3 SCAR=24.8
Pod undocumented
2037 0 my ($self, $text, $type) = @_;
2038 0 ▶ $type = "log" if !defined $type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $type 0 0 0
2039 0 $text =~ s/\n/\$[ln];/g;
2040 0 ▶ $self->_add("mc", $text . ($type eq "log" ? "" : GS . $type));
Branch: 1 branch
BranchTrueFalseTotal
$type eq 'log' ? : 0 0 0
2041 }
2042
2043 0 ▶sub console_message_assert {
Subroutine console_message_assert: not called CC=1 SCAR=6.9
Pod undocumented
2044 0 my ($self, $text, $condition) = @_;
2045 0 $text =~ s/\n/\$[ln];/g;
2046 0 $self->_add("ma", $text . GS . $condition);
2047 }
2048
2049 # Enable
2050 # Calling The EnableWebSocket Or EnableWebSocketOnce Or AddWebSocket Methods Will Cause Any Subsequent Requests (Under WebForms Core Technology) To Operate Under The WebSocket Protocol.
2051 0 ▶sub enable_web_socket {
Subroutine enable_web_socket: not called CC=3 SCAR=24.8
Pod undocumented
2052 0 my ($self, $enable) = @_;
2053 0 ▶ $enable = 1 if !defined $enable;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $enable 0 0 0
2054 0 ▶ $self->_add("ew", $enable ? "1" : "0");
Branch: 1 branch
BranchTrueFalseTotal
$enable ? : 0 0 0
2055 }
2056
2057 0 ▶sub enable_web_socket_once {
Subroutine enable_web_socket_once: not called CC=1 SCAR=6.9
Pod undocumented
2058 0 my ($self) = @_;
2059 0 $self->_add("ew", '$');
2060 }
2061
2062 0 ▶sub add_web_socket {
Subroutine add_web_socket: not called CC=1 SCAR=6.9
Pod undocumented
2063 0 my ($self, $path) = @_;
2064 0 $self->_add("aw" . $path);
2065 }
2066
2067 # Disconnected WebSocket
2068 0 ▶sub delete_web_socket {
Subroutine delete_web_socket: not called CC=1 SCAR=6.9
Pod undocumented
2069 0 my ($self, $path) = @_;
2070 0 $self->_add("dw" . $path);
2071 }
2072
2073 # Use
2074 # InputPlace Using Only For form Element
2075 0 ▶sub use_web_socket {
Subroutine use_web_socket: not called CC=1 SCAR=6.9
Pod undocumented
2076 0 my ($self, $input_place) = @_;
2077 0 $self->_add("uw" . $input_place);
2078 }
2079
2080 0 ▶sub use_only_change_update {
Subroutine use_only_change_update: not called CC=1 SCAR=6.9
Pod undocumented
2081 0 my ($self, $input_place) = @_;
2082 0 $self->_add("uo" . $input_place);
2083 }
2084
2085 # Condition And Loop
2086 # Condition And Loop Supports Brackets and Then
2087 # Type: warning, problem, help, success, none
2088 # Interval: Value 0 is Await (if is not True, all Next Action Controls Waiting for it), Value -1 is Sync Check Once (is Support Bracket or Next Action Control), Value > 0 is Async and is Wait Based on Time Repetition Until it Becomes True (Is Support Bracket or Next Action Control, but is not Support Else).
2089 # Nested Conditions and Nested Loops are Possible.
2090 0 ▶sub confirm_is_true_accept {
Subroutine confirm_is_true_accept: not called CC=13 SCAR=52.0
Pod undocumented
2091 0 my ($self, $text, $type, $title, $ok_text, $cancel_text, $interval) = @_;
2092 0 ▶ $text = "Are you sure you want to proceed?" if !defined $text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $text 0 0 0
2093 0 ▶ $type = "none" if !defined $type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $type 0 0 0
2094 0 ▶ $title = "Confirm" if !defined $title;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $title 0 0 0
2095 0 ▶ $ok_text = "OK" if !defined $ok_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $ok_text 0 0 0
2096 0 ▶ $cancel_text = "Cancel" if !defined $cancel_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $cancel_text 0 0 0
2097 0 ▶ $interval = 100 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2098
2099 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2100 0 ▶ my $text_part = ($text eq "Are you sure you want to proceed?" ? "" : $text);
Branch: 1 branch
BranchTrueFalseTotal
$text eq 'Are you sure you want to proceed?' ? : 0 0 0
2101 0 ▶ my $type_part = ($type eq "none" ? "" : $type);
Branch: 1 branch
BranchTrueFalseTotal
$type eq 'none' ? : 0 0 0
2102 0 ▶ my $title_part = ($title eq "Confirm" ? "" : $title);
Branch: 1 branch
BranchTrueFalseTotal
$title eq 'Confirm' ? : 0 0 0
2103 0 ▶ my $ok_part = ($ok_text eq "OK" ? "" : $ok_text);
Branch: 1 branch
BranchTrueFalseTotal
$ok_text eq 'OK' ? : 0 0 0
2104 0 ▶ my $cancel_part = ($cancel_text eq "Cancel" ? "" : $cancel_text);
Branch: 1 branch
BranchTrueFalseTotal
$cancel_text eq 'Cancel' ? : 0 0 0
2105
2106 0 $self->_add($prefix . "ct", $text_part . GS . $type_part . GS . $title_part . GS . $ok_part . GS . $cancel_part);
2107 0 return $self;
2108 }
2109
2110 0 ▶sub confirm_is_false_accept {
Subroutine confirm_is_false_accept: not called CC=13 SCAR=52.0
Pod undocumented
2111 0 my ($self, $text, $type, $title, $ok_text, $cancel_text, $interval) = @_;
2112 0 ▶ $text = "Are you sure you want to proceed?" if !defined $text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $text 0 0 0
2113 0 ▶ $type = "none" if !defined $type;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $type 0 0 0
2114 0 ▶ $title = "Confirm" if !defined $title;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $title 0 0 0
2115 0 ▶ $ok_text = "OK" if !defined $ok_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $ok_text 0 0 0
2116 0 ▶ $cancel_text = "Cancel" if !defined $cancel_text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $cancel_text 0 0 0
2117 0 ▶ $interval = 100 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2118
2119 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2120 0 ▶ my $text_part = ($text eq "Are you sure you want to proceed?" ? "" : $text);
Branch: 1 branch
BranchTrueFalseTotal
$text eq 'Are you sure you want to proceed?' ? : 0 0 0
2121 0 ▶ my $type_part = ($type eq "none" ? "" : $type);
Branch: 1 branch
BranchTrueFalseTotal
$type eq 'none' ? : 0 0 0
2122 0 ▶ my $title_part = ($title eq "Confirm" ? "" : $title);
Branch: 1 branch
BranchTrueFalseTotal
$title eq 'Confirm' ? : 0 0 0
2123 0 ▶ my $ok_part = ($ok_text eq "OK" ? "" : $ok_text);
Branch: 1 branch
BranchTrueFalseTotal
$ok_text eq 'OK' ? : 0 0 0
2124 0 ▶ my $cancel_part = ($cancel_text eq "Cancel" ? "" : $cancel_text);
Branch: 1 branch
BranchTrueFalseTotal
$cancel_text eq 'Cancel' ? : 0 0 0
2125
2126 0 $self->_add($prefix . "cf", $text_part . GS . $type_part . GS . $title_part . GS . $ok_part . GS . $cancel_part);
2127 0 return $self;
2128 }
2129
2130 0 ▶sub is_greater_than {
Subroutine is_greater_than: not called CC=3 SCAR=24.8
Pod undocumented
2131 0 my ($self, $first_value, $second_value, $interval) = @_;
2132 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2133 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2134 0 $self->_add($prefix . "gt", $first_value . GS . $second_value);
2135 0 return $self;
2136 }
2137
2138 0 ▶sub is_less_than {
Subroutine is_less_than: not called CC=3 SCAR=24.8
Pod undocumented
2139 0 my ($self, $first_value, $second_value, $interval) = @_;
2140 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2141 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2142 0 $self->_add($prefix . "lt", $first_value . GS . $second_value);
2143 0 return $self;
2144 }
2145
2146 0 ▶sub is_equal_to {
Subroutine is_equal_to: not called CC=3 SCAR=24.8
Pod undocumented
2147 0 my ($self, $first_value, $second_value, $interval) = @_;
2148 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2149 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2150 0 $self->_add($prefix . "et", $first_value . GS . $second_value);
2151 0 return $self;
2152 }
2153
2154 0 ▶sub is_not_equal_to {
Subroutine is_not_equal_to: not called CC=3 SCAR=24.8
Pod undocumented
2155 0 my ($self, $first_value, $second_value, $interval) = @_;
2156 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2157 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2158 0 $self->_add($prefix . "Nt", $first_value . GS . $second_value);
2159 0 return $self;
2160 }
2161
2162 0 ▶sub exist {
Subroutine exist: not called CC=3 SCAR=24.8
Pod undocumented
2163 0 my ($self, $value, $interval) = @_;
2164 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2165 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2166 0 $self->_add($prefix . "ex", $value);
2167 0 return $self;
2168 }
2169
2170 0 ▶sub not_exist {
Subroutine not_exist: not called CC=3 SCAR=24.8
Pod undocumented
2171 0 my ($self, $value, $interval) = @_;
2172 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2173 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2174 0 $self->_add($prefix . "nx", $value);
2175 0 return $self;
2176 }
2177
2178 0 ▶sub is_true {
Subroutine is_true: not called CC=3 SCAR=24.8
Pod undocumented
2179 0 my ($self, $value, $interval) = @_;
2180 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2181 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2182 0 $self->_add($prefix . "tr", $value);
2183 0 return $self;
2184 }
2185
2186 0 ▶sub is_false {
Subroutine is_false: not called CC=3 SCAR=24.8
Pod undocumented
2187 0 my ($self, $value, $interval) = @_;
2188 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2189 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2190 0 $self->_add($prefix . "fa", $value);
2191 0 return $self;
2192 }
2193
2194 0 ▶sub is_match_media {
Subroutine is_match_media: not called CC=3 SCAR=24.8
Pod undocumented
2195 0 my ($self, $value, $interval) = @_;
2196 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2197 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2198 0 $self->_add($prefix . "mm", $value);
2199 0 return $self;
2200 }
2201
2202 0 ▶sub is_not_match_media {
Subroutine is_not_match_media: not called CC=3 SCAR=24.8
Pod undocumented
2203 0 my ($self, $value, $interval) = @_;
2204 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2205 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2206 0 $self->_add($prefix . "nm", $value);
2207 0 return $self;
2208 }
2209
2210 0 ▶sub include {
Subroutine include: not called CC=3 SCAR=24.8
Pod undocumented
2211 0 my ($self, $text, $value, $interval) = @_;
2212 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2213 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2214 0 $self->_add($prefix . "In", $value . GS . $text);
2215 0 return $self;
2216 }
2217
2218 0 ▶sub not_include {
Subroutine not_include: not called CC=3 SCAR=24.8
Pod undocumented
2219 0 my ($self, $text, $value, $interval) = @_;
2220 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2221 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2222 0 $self->_add($prefix . "Nn", $value . GS . $text);
2223 0 return $self;
2224 }
2225
2226 0 ▶sub element_exists {
Subroutine element_exists: not called CC=3 SCAR=24.8
Pod undocumented
2227 0 my ($self, $input_place, $interval) = @_;
2228 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2229 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2230 0 $self->_add($prefix . "eE", $input_place);
2231 0 return $self;
2232 }
2233
2234 0 ▶sub element_not_exists {
Subroutine element_not_exists: not called CC=3 SCAR=24.8
Pod undocumented
2235 0 my ($self, $input_place, $interval) = @_;
2236 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2237 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2238 0 $self->_add($prefix . "nE", $input_place);
2239 0 return $self;
2240 }
2241
2242 0 ▶sub is_regex_match {
Subroutine is_regex_match: not called CC=3 SCAR=24.8
Pod undocumented
2243 0 my ($self, $value, $pattern, $interval) = @_;
2244 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2245 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2246 0 $self->_add($prefix . "re", $value . GS . $pattern);
2247 0 return $self;
2248 }
2249
2250 0 ▶sub is_regex_not_match {
Subroutine is_regex_not_match: not called CC=3 SCAR=24.8
Pod undocumented
2251 0 my ($self, $value, $pattern, $interval) = @_;
2252 0 ▶ $interval = -1 if !defined $interval;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $interval 0 0 0
2253 0 ▶ my $prefix = ($interval >= 0) ? "{(" . $interval . ")" : "{";
Branch: 1 branch
BranchTrueFalseTotal
$interval >= 0 ? : 0 0 0
2254 0 $self->_add($prefix . "rn", $value . GS . $pattern);
2255 0 return $self;
2256 }
2257
2258 # In: Everything Becomes A JSON List.
2259 # Key: Creates A Temporary Data In The Browser IndexedDB.
2260 # Key + "i" Creates A Temporary Data To Maintain The Loop Counter In The Browser IndexedDB.
2261 0 ▶sub for_each {
Subroutine for_each: not called CC=2 SCAR=17.9
Pod undocumented
2262 0 my ($self, $path, $in_val, $key) = @_;
2263 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
2264 0 $self->_add("{fe", $path . GS . $in_val . GS . $key);
2265 0 return $self;
2266 }
2267
2268 # 'break' is a reserved keyword in Perl, so 'wf_break' is used to preserve API intent without syntax errors.
2269 0 ▶sub wf_break {
Subroutine wf_break: not called CC=1 SCAR=6.9
Pod undocumented
2270 0 my ($self) = @_;
2271 0 $self->_add(";");
2272 }
2273
2274 # 'else' is a reserved keyword in Perl, so 'wf_else' is used to preserve API intent without syntax errors.
2275 0 ▶sub wf_else {
Subroutine wf_else: not called CC=1 SCAR=6.9
Pod undocumented
2276 0 my ($self) = @_;
2277 0 $self->_add("}e");
2278 0 return $self;
2279 }
2280
2281 0 ▶sub start_bracket {
Subroutine start_bracket: not called CC=1 SCAR=6.9
Pod undocumented
2282 0 my ($self) = @_;
2283 0 $self->_add("{");
2284 }
2285
2286 0 ▶sub end_bracket {
Subroutine end_bracket: not called CC=1 SCAR=6.9
Pod undocumented
2287 0 my ($self) = @_;
2288 0 $self->_add("}");
2289 }
2290
2291 # Used Then In Condition And Loop Methods
2292 0 ▶sub then_form {
Subroutine then_form: not called CC=5 SCAR=34.0
Pod undocumented
2293 0 my ($self, $new_form) = @_;
2294 0 ▶ return $self if !defined $new_form;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $new_form 0 0 0
2295
2296 0 my $data = $new_form->get_web_forms_data();
2297
2298 0 ▶ if (defined $data && $data ne "") {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $data and $data ne "") 0 0 0
Condition0%0/3
defined $data and $data ne ""
!ll&&!rl&&r
000
MC/DC0%0/2
defined $data and $data ne ""
defined $data $data ne ""
Truth table0%0/3
A and B
A= defined $dataB= $data ne ""
ABresult
0X0
100
111
2299 0 ▶ if ($data =~ /\n/) {
Branch: 1 branch
BranchTrueFalseTotal
if ($data =~ /\n/u) 0 0 0
2300 0 $new_form->_add_to_up("{");
2301 0 $new_form->_add("}");
2302 }
2303 }
2304
2305 0 $self->append_form($new_form);
2306 0 return $self;
2307 }
2308
2309 0 ▶sub repeat_form {
Subroutine repeat_form: not called CC=6 SCAR=37.4
Pod undocumented
2310 0 my ($self, $new_form, $repeat, $index) = @_;
2311 0 ▶ return $self if !defined $new_form;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $new_form 0 0 0
2312
2313 0 ▶ if (defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $index) 0 0 0
2314 0 $self->go_to($index);
2315 0 $self->start_index($index);
2316 }
2317
2318 0 my $body_data = $new_form->get_web_forms_data();
2319 0 ▶ return $self if !defined $body_data || $body_data eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $body_data or $body_data eq "" 0 0 0
Condition0%0/3
not defined $body_data or $body_data eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $body_data or $body_data eq ""
not defined $body_data $body_data eq ""
Truth table0%0/3
not(A) or B
A= not defined $body_dataB= $body_data eq ""
ABresult
1X1
011
000
2320
2321 0 ▶ if (!defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $index) { } 0 0 0
2322 0 my @lines = split(/\n/, $body_data, -1);
2323 0 my $start_line = scalar(@lines) * -1;
2324 0 $self->append_form($new_form);
2325 0 $self->go_to("$start_line", $repeat - 1);
2326 } else {
2327 0 $self->append_form($new_form);
2328 0 $self->go_to($index, $repeat - 1);
2329 }
2330
2331 0 return $self;
2332 }
2333
2334 # Async
2335 # It Supports Brackets and Then
2336 0 ▶sub async_action {
Subroutine async_action: not called CC=1 SCAR=6.9
Pod undocumented
2337 0 my ($self) = @_;
2338 0 $self->_add("{(a)");
2339 0 return $self;
2340 }
2341
2342 0 ▶sub delay {
Subroutine delay: not called CC=1 SCAR=6.9
Pod undocumented
2343 0 my ($self, $mili_second) = @_;
2344 0 $self->_add("De", "$mili_second");
2345 }
2346
2347 # Option
2348 0 ▶sub change_option {
Subroutine change_option: not called CC=1 SCAR=6.9
Pod undocumented
2349 0 my ($self, $name, $value) = @_;
2350 0 $self->_add("co", $name . GS . $value);
2351 }
2352
2353 0 ▶sub reset_option {
Subroutine reset_option: not called CC=2 SCAR=17.9
Pod undocumented
2354 0 my ($self, $name) = @_;
2355 0 ▶ if (!defined $name) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $name) { } 0 0 0
2356 0 $self->_add("ro");
2357 } else {
2358 0 $self->_add("ro", $name);
2359 }
2360 }
2361
2362 # Format Storage
2363 0 ▶sub create_format_storage {
Subroutine create_format_storage: not called CC=1 SCAR=6.9
Pod undocumented
2364 0 my ($self, $key, $data) = @_;
2365 0 $self->_add(".C", $key . GS . $data);
2366 }
2367
2368 0 ▶sub delete_format_storage {
Subroutine delete_format_storage: not called CC=1 SCAR=6.9
Pod undocumented
2369 0 my ($self, $key) = @_;
2370 0 $self->_add(".D", $key);
2371 }
2372
2373 0 ▶sub add_json {
Subroutine add_json: not called CC=1 SCAR=6.9
Pod undocumented
2374 0 my ($self, $key, $path, $value) = @_;
2375 0 $self->_add(".a", $key . GS . "j" . GS . $value . GS . $path);
2376 }
2377
2378 # Name: For Support Attribute, Set Double At Sign (@@) Before Name.
2379 0 ▶sub add_xml {
Subroutine add_xml: not called CC=2 SCAR=17.9
Pod undocumented
2380 0 my ($self, $key, $path, $name, $value) = @_;
2381 0 ▶ $value = "" if !defined $value;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $value 0 0 0
2382 0 $self->_add(".a", $key . GS . "x" . GS . $name . GS . $value . GS . $path);
2383 }
2384
2385 0 ▶sub add_ini {
Subroutine add_ini: not called CC=3 SCAR=24.8
Pod undocumented
2386 0 my ($self, $key, $path, $value, $is_ini_like) = @_;
2387 0 ▶ $is_ini_like = 0 if !defined $is_ini_like;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $is_ini_like 0 0 0
2388 0 ▶ $self->_add(".a", $key . GS . "i" . GS . ($is_ini_like ? "1" : "0") . GS . $value . GS . $path);
Branch: 1 branch
BranchTrueFalseTotal
$is_ini_like ? : 0 0 0
2389 }
2390
2391 0 ▶sub add_text_line {
Subroutine add_text_line: not called CC=1 SCAR=6.9
Pod undocumented
2392 0 my ($self, $key, $line, $text) = @_;
2393 0 $self->_add(".a", $key . GS . "t" . GS . $text . GS . "$line");
2394 }
2395
2396 0 ▶sub add_variable {
Subroutine add_variable: not called CC=1 SCAR=6.9
Pod undocumented
2397 0 my ($self, $key, $value) = @_;
2398 0 $self->_add(".a", $key . GS . "v" . GS . $value);
2399 }
2400
2401 0 ▶sub update_json {
Subroutine update_json: not called CC=1 SCAR=6.9
Pod undocumented
2402 0 my ($self, $key, $path, $value) = @_;
2403 0 $self->_add(".u", $key . GS . "j" . GS . $value . GS . $path);
2404 }
2405
2406 0 ▶sub update_xml {
Subroutine update_xml: not called CC=1 SCAR=6.9
Pod undocumented
2407 0 my ($self, $key, $path, $value) = @_;
2408 0 $self->_add(".u", $key . GS . "x" . GS . $value . GS . $path);
2409 }
2410
2411 0 ▶sub update_ini {
Subroutine update_ini: not called CC=3 SCAR=24.8
Pod undocumented
2412 0 my ($self, $key, $path, $value, $is_ini_like) = @_;
2413 0 ▶ $is_ini_like = 0 if !defined $is_ini_like;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $is_ini_like 0 0 0
2414 0 ▶ $self->_add(".u", $key . GS . "i" . GS . ($is_ini_like ? "1" : "0") . GS . $value . GS . $path);
Branch: 1 branch
BranchTrueFalseTotal
$is_ini_like ? : 0 0 0
2415 }
2416
2417 # Note: C# original has a typo 'UpdateTexLine', mapped to 'update_text_line' for Perl standards while preserving exact logic.
2418 0 ▶sub update_text_line {
Subroutine update_text_line: not called CC=1 SCAR=6.9
Pod undocumented
2419 0 my ($self, $key, $line, $text) = @_;
2420 0 $self->_add(".u", $key . GS . "t" . GS . $text . GS . "$line");
2421 }
2422
2423 0 ▶sub update_variable {
Subroutine update_variable: not called CC=1 SCAR=6.9
Pod undocumented
2424 0 my ($self, $key, $value) = @_;
2425 0 $self->_add(".u", $key . GS . "v" . GS . $value);
2426 }
2427
2428 0 ▶sub increase_variable {
Subroutine increase_variable: not called CC=1 SCAR=6.9
Pod undocumented
2429 0 my ($self, $key, $value) = @_;
2430 0 $self->_add(".i", $key . GS . "v" . GS . "$value");
2431 }
2432
2433 0 ▶sub decrease_variable {
Subroutine decrease_variable: not called CC=1 SCAR=6.9
Pod undocumented
2434 0 my ($self, $key, $value) = @_;
2435 0 $self->increase_variable($key, $value * -1);
2436 }
2437
2438 0 ▶sub delete_json {
Subroutine delete_json: not called CC=1 SCAR=6.9
Pod undocumented
2439 0 my ($self, $key, $path) = @_;
2440 0 $self->_add(".d", $key . GS . "j" . GS . $path);
2441 }
2442
2443 0 ▶sub delete_xml {
Subroutine delete_xml: not called CC=1 SCAR=6.9
Pod undocumented
2444 0 my ($self, $key, $path) = @_;
2445 0 $self->_add(".d", $key . GS . "x" . GS . $path);
2446 }
2447
2448 0 ▶sub delete_ini {
Subroutine delete_ini: not called CC=3 SCAR=24.8
Pod undocumented
2449 0 my ($self, $key, $path, $is_ini_like) = @_;
2450 0 ▶ $is_ini_like = 0 if !defined $is_ini_like;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $is_ini_like 0 0 0
2451 0 ▶ $self->_add(".d", $key . GS . "i" . GS . ($is_ini_like ? "1" : "0") . GS . $path);
Branch: 1 branch
BranchTrueFalseTotal
$is_ini_like ? : 0 0 0
2452 }
2453
2454 0 ▶sub delete_text_line {
Subroutine delete_text_line: not called CC=1 SCAR=6.9
Pod undocumented
2455 0 my ($self, $key, $line) = @_;
2456 0 $self->_add(".d", $key . GS . "t" . GS . "$line");
2457 }
2458
2459 0 ▶sub delete_variable {
Subroutine delete_variable: not called CC=1 SCAR=6.9
Pod undocumented
2460 0 my ($self, $key) = @_;
2461 0 $self->_add(".d", $key . GS . "v");
2462 }
2463
2464 # Template Engine
2465 # Pattern Example: {{value}}, ((value)), *value*, $value;
2466 0 ▶sub bind_json_to_template {
Subroutine bind_json_to_template: not called CC=3 SCAR=24.8
Pod undocumented
2467 0 my ($self, $input_place, $json_text, $path, $pattern, $also_start_tag) = @_;
2468 0 ▶ $also_start_tag = 1 if !defined $also_start_tag;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $also_start_tag 0 0 0
2469 0 ▶ $self->_add("Tj" . $input_place, $json_text . GS . $path . GS . $pattern . GS . ($also_start_tag ? "1" : "0"));
Branch: 1 branch
BranchTrueFalseTotal
$also_start_tag ? : 0 0 0
2470 }
2471
2472 # Because XML Elements Are Lowercased, Placeholders Must Use Lowercase Names.
2473 0 ▶sub bind_xml_to_template {
Subroutine bind_xml_to_template: not called CC=3 SCAR=24.8
Pod undocumented
2474 0 my ($self, $input_place, $xml_text, $path, $pattern, $also_start_tag) = @_;
2475 0 ▶ $also_start_tag = 1 if !defined $also_start_tag;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $also_start_tag 0 0 0
2476 0 ▶ $self->_add("Tx" . $input_place, $xml_text . GS . $path . GS . $pattern . GS . ($also_start_tag ? "1" : "0"));
Branch: 1 branch
BranchTrueFalseTotal
$also_start_tag ? : 0 0 0
2477 }
2478
2479 0 ▶sub bind_ini_to_template {
Subroutine bind_ini_to_template: not called CC=3 SCAR=24.8
Pod undocumented
2480 0 my ($self, $input_place, $ini_text, $path, $pattern, $also_start_tag) = @_;
2481 0 ▶ $also_start_tag = 1 if !defined $also_start_tag;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $also_start_tag 0 0 0
2482 0 ▶ $self->_add("Ti" . $input_place, $ini_text . GS . $path . GS . $pattern . GS . ($also_start_tag ? "1" : "0"));
Branch: 1 branch
BranchTrueFalseTotal
$also_start_tag ? : 0 0 0
2483 }
2484
2485 # Inject
2486 # Need Add @: to First of String
2487 0 ▶sub inject {
Subroutine inject: not called CC=1 SCAR=6.9
Pod undocumented
2488 0 my ($self, $value) = @_;
2489 0 return "\$[" . $value . "];";
2490 }
2491
2492 # Action Control
2493 0 ▶sub replace_action_control {
Subroutine replace_action_control: not called CC=3 SCAR=24.8
Pod undocumented
2494 0 my ($self, $search_value, $value, $adding_to_up) = @_;
2495 0 ▶ $adding_to_up = 0 if !defined $adding_to_up;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $adding_to_up 0 0 0
2496 0 ▶ if ($adding_to_up) {
Branch: 1 branch
BranchTrueFalseTotal
if ($adding_to_up) { } 0 0 0
2497 0 $self->_add_to_up("rE", $search_value . GS . $value);
2498 } else {
2499 0 $self->_add("rE", $search_value . GS . $value);
2500 }
2501 }
2502
2503 0 ▶sub assign_replace {
Subroutine assign_replace: not called CC=5 SCAR=34.0
Pod undocumented
2504 0 my ($self, $search_value, $value, $index) = @_;
2505 0 ▶ $index = -1 if !defined $index;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $index 0 0 0
2506 0 my $current_line = $self->_get_line_by_index($index);
2507 0 ▶ return if !defined $current_line || $current_line eq "";
Branch: 1 branch
BranchTrueFalseTotal
if not defined $current_line or $current_line eq "" 0 0 0
Condition0%0/3
not defined $current_line or $current_line eq ""
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $current_line or $current_line eq ""
not defined $current_line $current_line eq ""
Truth table0%0/3
not(A) or B
A= not defined $current_lineB= $current_line eq ""
ABresult
1X1
011
000
2508
2509 0 my @parts = split(/=/, $current_line, 2);
2510 0 my $new_name = ";" . $search_value . GS . $value . GS . $parts[0];
2511 0 ▶ my $new_value = (scalar(@parts) > 1) ? $parts[1] : "";
Branch: 1 branch
BranchTrueFalseTotal
scalar @parts > 1 ? : 0 0 0
2512
2513 0 $self->_update_line_by_index($index, $new_name, $new_value);
2514 }
2515
2516 # Hash And Checksum
2517 0 ▶sub set_hash {
Subroutine set_hash: not called CC=1 SCAR=6.9
Pod undocumented
2518 0 my ($self) = @_;
2519 0 $self->_add("SH");
2520 }
2521
2522 0 ▶sub set_checksum {
Subroutine set_checksum: not called CC=1 SCAR=6.9
Pod undocumented
2523 0 my ($self) = @_;
2524 0 $self->_add("CS");
2525 }
2526
2527 0 ▶sub checksum_calculation {
Subroutine checksum_calculation: not called CC=2 SCAR=17.9
Pod undocumented
2528 0 my ($self, $text) = @_;
2529 0 my $sum = 0;
2530 0 my $mod = 65536;
2531 0 my $shift = 5;
2532
2533 0 foreach my $c (split(//, $text)) {
2534 0 $sum = ((($sum << $shift) | ($sum >> (16 - $shift))) ^ ord($c)) % $mod;
2535 }
2536
2537 0 return "$sum";
2538 }
2539
2540 0 ▶sub get_checksum {
Subroutine get_checksum: not called CC=1 SCAR=6.9
Pod undocumented
2541 0 my ($self) = @_;
2542 0 return $self->checksum_calculation($self->get_web_forms_data());
2543 }
2544
2545 # Get
2546 0 ▶sub get_forms_action_data {
Subroutine get_forms_action_data: not called CC=2 SCAR=17.9
Pod undocumented
2547 0 my ($self) = @_;
2548 0 ▶ return "" if length($self->{web_forms_data}) == 0;
Branch: 1 branch
BranchTrueFalseTotal
if length $self->{"web_forms_data"} == 0 0 0 0
2549 0 return $self->{web_forms_data};
2550 }
2551
2552 0 ▶sub response {
Subroutine response: not called CC=1 SCAR=6.9
Pod undocumented
2553 0 my ($self) = @_;
2554 0 return "[web-forms]\n" . $self->get_forms_action_data();
2555 }
2556
2557 0 ▶sub get_forms_action_data_line_break {
Subroutine get_forms_action_data_line_break: not called CC=2 SCAR=17.9
Pod undocumented
2558 0 my ($self) = @_;
2559 0 ▶ return "" if length($self->{web_forms_data}) == 0;
Branch: 1 branch
BranchTrueFalseTotal
if length $self->{"web_forms_data"} == 0 0 0 0
2560
2561 0 my $data = $self->{web_forms_data};
2562 0 my $processed_data = $data;
2563 0 $processed_data =~ s/"/\$[dq];/g;
2564 0 $processed_data =~ s/\n/\$[sln];/g;
2565 0 return $processed_data;
2566 }
2567
2568 # Export
2569 0 ▶sub export_to_html_comment {
Subroutine export_to_html_comment: not called CC=4 SCAR=30.0
Pod undocumented
2570 0 my ($self, $add_line) = @_;
2571 0 ▶ $add_line = 0 if !defined $add_line;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $add_line 0 0 0
2572 0 my $response_str = $self->response();
2573 0 $response_str =~ s/--/\$[dd];/g;
2574 0 ▶ if (substr($response_str, -1) eq '-') {
Branch: 1 branch
BranchTrueFalseTotal
if (substr($response_str, -1) eq "-") 0 0 0
2575 0 $response_str = substr($response_str, 0, -1) . "\$[da];";
2576 }
2577
2578 0 ▶ return ($add_line ? "\n" : "") . "<!--" . $response_str . "-->";
Branch: 1 branch
BranchTrueFalseTotal
$add_line ? : 0 0 0
2579 }
2580
2581 # Using it for SSE Response
2582 0 ▶sub export_to_line_break {
Subroutine export_to_line_break: not called CC=1 SCAR=6.9
Pod undocumented
2583 0 my ($self, $src) = @_;
2584 0 return "[web-forms]\$[sln];" . $self->get_forms_action_data_line_break();
2585 }
2586
2587 0 ▶sub get_web_forms_data {
Subroutine get_web_forms_data: not called CC=1 SCAR=6.9
Pod undocumented
2588 0 my ($self) = @_;
2589 0 return $self->{web_forms_data};
2590 }
2591
2592 0 ▶sub append_form {
Subroutine append_form: not called CC=5 SCAR=34.0
Pod undocumented
2593 0 my ($self, $form) = @_;
2594 0 ▶ return if !defined $form;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $form 0 0 0
2595
2596 0 my $other_data = $form->get_web_forms_data();
2597 0 ▶ if (defined $other_data && $other_data ne "") {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $other_data and $other_data ne "") 0 0 0
Condition0%0/3
defined $other_data and $other_data ne ""
!ll&&!rl&&r
000
MC/DC0%0/2
defined $other_data and $other_data ne ""
defined $other_data $other_data ne ""
Truth table0%0/3
A and B
A= defined $other_dataB= $other_data ne ""
ABresult
0X0
100
111
2598 0 ▶ if (length($self->{web_forms_data}) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (length $self->{"web_forms_data"} > 0) 0 0 0
2599 0 $self->{web_forms_data} .= "\n";
2600 }
2601 0 $self->{web_forms_data} .= $other_data;
2602 }
2603 }
2604
2605 0 ▶sub clean {
Subroutine clean: not called CC=1 SCAR=6.9
Pod undocumented
2606 0 my ($self) = @_;
2607 0 $self->{web_forms_data} = "";
2608 }
2609
2610 package Security;
2611 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
2612 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
2613 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
2614
2615 0 ▶sub new {
Subroutine new: not called CC=1 SCAR=6.9
2616 0 my ($class) = @_;
2617 0 my $self = {};
2618 0 bless $self, $class;
2619 0 return $self;
2620 }
2621
2622 0 ▶sub safe_value {
Subroutine safe_value: not called CC=3 SCAR=24.8
2623 0 my ($self, $value) = @_;
2624 0 ▶ return $value if length($value) < 1;
Branch: 1 branch
BranchTrueFalseTotal
if length $value < 1 0 0 0
2625
2626 0 ▶ $value = '@' . $value if substr($value, 0, 1) eq '@';
Branch: 1 branch
BranchTrueFalseTotal
if substr($value, 0, 1) eq "\@" 0 0 0
2627
2628 0 $value =~ s/\n/\$[ln];/g;
2629 0 $value =~ s/,@/\$[co];@/g;
2630 0 $value =~ s/\x{1c}/\0/g;
2631 0 $value =~ s/\x{1d}/\0/g;
2632 0 $value =~ s/\x{1e}/\0/g;
2633 0 $value =~ s/\x{1f}/\0/g;
2634
2635 0 return $value;
2636 }
2637
2638 # WebForms Place Criteria (WPC) DSL
2639 package InputPlace;
2640 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
2641 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
2642 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
2643
2644 1 ▶use constant Document => ",";
Subroutine BEGIN: called CC=1 SCAR=0.0
2645 1 ▶use constant Window => "`";
Subroutine BEGIN: called CC=1 SCAR=0.0
2646 # When Calling TransientDOM, Using Root will Result in the Selection of the Transient Tag.
2647 1 ▶use constant Root => "~";
Subroutine BEGIN: called CC=1 SCAR=0.0
2648 1 ▶use constant HTML => ".";
Subroutine BEGIN: called CC=1 SCAR=0.0
2649 1 ▶use constant Head => "^";
Subroutine BEGIN: called CC=1 SCAR=0.0
2650 1 ▶use constant ScreenOrientation => "%";
Subroutine BEGIN: called CC=1 SCAR=0.0
2651 1 ▶use constant All => "*";
Subroutine BEGIN: called CC=1 SCAR=0.0
2652 1 ▶use constant Parent => "/";
Subroutine BEGIN: called CC=1 SCAR=0.0
2653 1 ▶use constant Current => '$';
Subroutine BEGIN: called CC=1 SCAR=0.0
2654 1 ▶use constant Target => "!";
Subroutine BEGIN: called CC=1 SCAR=0.0
2655 1 ▶use constant Upper => "-";
Subroutine BEGIN: called CC=1 SCAR=0.0
2656
2657 0 ▶sub id {
Subroutine id: not called CC=1 SCAR=6.9
2658 0 my ($id_val) = @_;
2659 0 return $id_val;
2660 }
2661
2662 0 ▶sub name {
Subroutine name: not called CC=2 SCAR=17.9
2663 0 my ($name_val, $index) = @_;
2664 0 ▶ if (!defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $index) { } 0 0 0
2665 0 return '(' . $name_val . ')';
2666 } else {
2667 0 return '(' . $name_val . ')' . $index;
2668 }
2669 }
2670
2671 0 ▶sub all_names {
Subroutine all_names: not called CC=1 SCAR=6.9
2672 0 my ($name_val) = @_;
2673 0 return "(" . $name_val . ")*";
2674 }
2675
2676 0 ▶sub tag {
Subroutine tag: not called CC=2 SCAR=17.9
2677 0 my ($tag_val, $index) = @_;
2678 0 ▶ if (!defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $index) { } 0 0 0
2679 0 return '<' . $tag_val . '>';
2680 } else {
2681 0 return '<' . $tag_val . '>' . $index;
2682 }
2683 }
2684
2685 0 ▶sub all_tags {
Subroutine all_tags: not called CC=1 SCAR=6.9
2686 0 my ($tag_val) = @_;
2687 0 return "<" . $tag_val . ">*";
2688 }
2689
2690 0 ▶sub child {
Subroutine child: not called CC=2 SCAR=17.9
2691 0 my ($index) = @_;
2692 0 ▶ if (!defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $index) { } 0 0 0
2693 0 return "<>";
2694 } else {
2695 0 return "<>" . $index;
2696 }
2697 }
2698
2699 0 ▶sub all_child {
Subroutine all_child: not called CC=1 SCAR=6.9
2700 0 my ($class) = @_;
2701 0 return "<>*";
2702 }
2703
2704 0 ▶sub class_name {
Subroutine class_name: not called CC=2 SCAR=17.9
2705 0 my ($class_val, $index) = @_;
2706 0 ▶ if (!defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $index) { } 0 0 0
2707 0 return '{' . $class_val . '}';
2708 } else {
2709 0 return '{' . $class_val . '}' . $index;
2710 }
2711 }
2712
2713 0 ▶sub all_classes {
Subroutine all_classes: not called CC=1 SCAR=6.9
2714 0 my ($class_val) = @_;
2715 0 return "{" . $class_val . "}*";
2716 }
2717
2718 0 ▶sub attribute {
Subroutine attribute: not called CC=8 SCAR=42.8
2719 0 my ($name_val, $value_or_index, $operator_or_nil, $index) = @_;
2720 0 ▶ if (!defined $value_or_index) {
Branch: 2 branches
BranchTrueFalseTotal
if (not defined $value_or_index) { } 0 0 0
elsif (not defined $index and !defined($operator_or_nil) || $operator_or_nil eq "\000") { } 0 0 0
2721 0 return '"' . $name_val . '"';
2722 ▶ } elsif (!defined $index && (!defined $operator_or_nil || $operator_or_nil eq "\0")) {
Condition0%0/6
not defined $index and !defined($operator_or_nil) || $operator_or_nil eq "\0"
!ll&&!rl&&r
000
not defined $operator_or_nil or $operator_or_nil eq "\0"
l!l&&r!l&&!r
000
MC/DC0%0/3
not defined $index and !defined($operator_or_nil) || $operator_or_nil eq "\0"
not defined $index not defined $operator_or_nil $operator_or_nil eq "\0"
Truth table0%0/4
not(A) and not(B) or C
A= not defined $indexB= not defined $operator_or_nilC= $operator_or_nil eq "\0"
ABCresult
0XX0
1000
11X1
1011
2723 0 return '"' . $name_val . '"' . $value_or_index;
2724 } else {
2725 0 ▶ my $op = (!defined $operator_or_nil || $operator_or_nil eq "\0") ? "" : $operator_or_nil;
Branch: 1 branch
BranchTrueFalseTotal
!defined($operator_or_nil) || $operator_or_nil eq "\000" ? : 0 0 0
Condition0%0/3
not defined $operator_or_nil or $operator_or_nil eq "\0"
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $operator_or_nil or $operator_or_nil eq "\0"
not defined $operator_or_nil $operator_or_nil eq "\0"
Truth table0%0/3
not(A) or B
A= not defined $operator_or_nilB= $operator_or_nil eq "\0"
ABresult
1X1
011
000
2726 0 ▶ if (!defined $index) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $index) { } 0 0 0
2727 0 return '"' . $name_val . $op . "'" . $value_or_index . '"';
2728 } else {
2729 0 return '"' . $name_val . $op . "'" . $value_or_index . '"' . $index;
2730 }
2731 }
2732 }
2733
2734 0 ▶sub all_attributes {
Subroutine all_attributes: not called CC=4 SCAR=30.0
2735 0 my ($name_val, $value, $operator) = @_;
2736 0 ▶ if (!defined $value) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $value) { } 0 0 0
2737 0 return "\"" . $name_val . "\"*";
2738 } else {
2739 0 ▶ my $op = (!defined $operator || $operator eq "\0") ? "" : $operator;
Branch: 1 branch
BranchTrueFalseTotal
!defined($operator) || $operator eq "\000" ? : 0 0 0
Condition0%0/3
not defined $operator or $operator eq "\0"
l!l&&r!l&&!r
000
MC/DC0%0/2
not defined $operator or $operator eq "\0"
not defined $operator $operator eq "\0"
Truth table0%0/3
not(A) or B
A= not defined $operatorB= $operator eq "\0"
ABresult
1X1
011
000
2740 0 return "\"" . $name_val . $op . "'" . $value . "\"*";
2741 }
2742 }
2743
2744 0 ▶sub query {
Subroutine query: not called CC=1 SCAR=6.9
2745 0 my ($query_val) = @_;
2746 0 my $res = $query_val;
2747 0 $res =~ s/=/\$[eq];/g;
2748 0 $res =~ s/\|/\$[vb];/g;
2749 0 $res =~ s/\?/\$[qu];/g;
2750 0 return "*" . $res;
2751 }
2752
2753 0 ▶sub query_all {
Subroutine query_all: not called CC=1 SCAR=6.9
2754 0 my ($query_val) = @_;
2755 0 my $res = $query_val;
2756 0 $res =~ s/=/\$[eq];/g;
2757 0 $res =~ s/\|/\$[vb];/g;
2758 0 $res =~ s/\?/\$[qu];/g;
2759 0 return "[" . $res;
2760 }
2761
2762 package OutputPlace;
2763 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
2764 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
2765 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
2766 1 ▶use parent -norequire, 'InputPlace';
Subroutine BEGIN: called CC=1 SCAR=0.0
2767
2768 # Do not Add any Data Before or After it
2769 package Fetch;
2770 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
2771 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
2772 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
2773
2774 1 ▶use constant RS => chr(30);
Subroutine BEGIN: called CC=1 SCAR=0.0
2775 1 ▶use constant US => chr(31);
Subroutine BEGIN: called CC=1 SCAR=0.0
2776
2777 # Method
2778 0 ▶sub random {
Subroutine random: not called CC=2 SCAR=17.9
2779 0 my ($max_value, $min_value) = @_;
2780 0 ▶ if (!defined $min_value) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $min_value) { } 0 0 0
2781 0 return '@mr' . $max_value;
2782 } else {
2783 0 return '@mr' . $max_value . RS . $min_value;
2784 }
2785 }
2786
2787 0 ▶sub space_to_char {
Subroutine space_to_char: not called CC=2 SCAR=17.9
2788 0 my ($text, $character) = @_;
2789 0 ▶ $character = "-" if !defined $character;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $character 0 0 0
2790 0 return '@sc' . $character . RS . $text;
2791 }
2792
2793 0 ▶sub encode_uri {
Subroutine encode_uri: not called CC=1 SCAR=6.9
2794 0 my ($text) = @_;
2795 0 return '@ue' . $text;
2796 }
2797
2798 0 ▶sub decode_uri {
Subroutine decode_uri: not called CC=1 SCAR=6.9
2799 0 my ($text) = @_;
2800 0 return '@ud' . $text;
2801 }
2802
2803 0 ▶sub method {
Subroutine method: not called CC=4 SCAR=30.0
2804 0 my ($method_name, $args) = @_;
2805 0 my $return_value = '@cm' . $method_name;
2806 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
2807 0 $return_value .= RS . join(US, @$args);
2808 }
2809 0 return $return_value;
2810 }
2811
2812 0 ▶sub module_method {
Subroutine module_method: not called CC=4 SCAR=30.0
2813 0 my ($method_name, $args) = @_;
2814 0 my $return_value = '@cM' . $method_name;
2815 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
2816 0 $return_value .= RS . join(US, @$args);
2817 }
2818 0 return $return_value;
2819 }
2820
2821 # MethodName: The Method Name May Need to Include the Class Name, Separated by a Period. Example: MyClassName.MyMethodName
2822 0 ▶sub wasm_method {
Subroutine wasm_method: not called CC=5 SCAR=34.0
2823 0 my ($wasm_language, $wasm_url, $method_name, $args, $key) = @_;
2824 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
2825 0 my $return_value = '@wA' . $wasm_language . RS . $wasm_url . RS . $method_name;
2826 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
2827 0 $return_value .= RS . join(US, @$args);
2828 }
2829 0 return $return_value;
2830 }
2831
2832 0 ▶sub script {
Subroutine script: not called CC=1 SCAR=6.9
2833 0 my ($script_text) = @_;
2834 0 $script_text =~ s/\n/\$[ln];/g;
2835 0 return '@_' . $script_text;
2836 }
2837
2838 0 ▶sub load_url {
Subroutine load_url: not called CC=3 SCAR=24.8
2839 0 my ($url, $fetch_script) = @_;
2840 0 ▶ $fetch_script = 0 if !defined $fetch_script;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $fetch_script 0 0 0
2841 0 ▶ return '@lu' . $url . ($fetch_script ? RS . "1" : "");
Branch: 1 branch
BranchTrueFalseTotal
$fetch_script ? : 0 0 0
2842 }
2843
2844 0 ▶sub load_html {
Subroutine load_html: not called CC=5 SCAR=34.0
2845 0 my ($url, $fetch_input_place, $fetch_script) = @_;
2846 0 ▶ $fetch_input_place = "" if !defined $fetch_input_place;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $fetch_input_place 0 0 0
2847 0 ▶ $fetch_script = 0 if !defined $fetch_script;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $fetch_script 0 0 0
2848 0 ▶ my $fetch_input_part = ($fetch_input_place ne "") ? RS . $fetch_input_place : "";
Branch: 1 branch
BranchTrueFalseTotal
$fetch_input_place ne '' ? : 0 0 0
2849 0 ▶ return '@lh' . $url . RS . ($fetch_script ? "1" : "0") . $fetch_input_part;
Branch: 1 branch
BranchTrueFalseTotal
$fetch_script ? : 0 0 0
2850 }
2851
2852 0 ▶sub load_line {
Subroutine load_line: not called CC=1 SCAR=6.9
2853 0 my ($url, $line) = @_;
2854 0 return '@ll' . $url . RS . $line;
2855 }
2856
2857 0 ▶sub load_ini {
Subroutine load_ini: not called CC=3 SCAR=24.8
2858 0 my ($url, $name, $is_ini_like) = @_;
2859 0 ▶ $is_ini_like = 0 if !defined $is_ini_like;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $is_ini_like 0 0 0
2860 0 ▶ return '@li' . $url . RS . $name . ($is_ini_like ? RS . "1" : "");
Branch: 1 branch
BranchTrueFalseTotal
$is_ini_like ? : 0 0 0
2861 }
2862
2863 # Name: Name Or Nested Paths. Is Supprt Index (Student[8].Name). Nested Paths Index Starts At 0
2864 0 ▶sub load_json {
Subroutine load_json: not called CC=1 SCAR=6.9
2865 0 my ($url, $name) = @_;
2866 0 return '@lj' . $url . RS . $name;
2867 }
2868
2869 # Name: Name Or XPath; XPath Index Starts At 1
2870 0 ▶sub load_xml {
Subroutine load_xml: not called CC=1 SCAR=6.9
2871 0 my ($url, $name) = @_;
2872 0 return '@lx' . $url . RS . $name;
2873 }
2874
2875 # MethodName: It's Check Function Or Variable
2876 0 ▶sub has_method {
Subroutine has_method: not called CC=1 SCAR=6.9
2877 0 my ($method_name) = @_;
2878 0 return '@hm' . $method_name;
2879 }
2880
2881 0 ▶sub has_module_method {
Subroutine has_module_method: not called CC=1 SCAR=6.9
2882 0 my ($method_name) = @_;
2883 0 return '@hM' . $method_name;
2884 }
2885
2886 # This Method Return True Or False If Key Pressed
2887 # Modifier: Alt, AltGraph, Control, Meta, Shift, CapsLock, NumLock, ScrollLock
2888 0 ▶sub get_modifier_state {
Subroutine get_modifier_state: not called CC=1 SCAR=6.9
2889 0 my ($modifier) = @_;
2890 0 return '@ms' . $modifier;
2891 }
2892
2893 # Math
2894 0 ▶sub math {
Subroutine math: not called CC=4 SCAR=30.0
2895 0 my ($method_name, $args) = @_;
2896 0 my $return_value = '@M#' . $method_name;
2897 0 ▶ if (defined $args && ref($args) eq 'ARRAY' && scalar(@$args) > 0) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $args and ref $args eq "ARRAY" and scalar @$args > 0) 0 0 0
Condition0%0/6
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
!ll&&!rl&&r
000
defined $args and ref $args eq "ARRAY"
!ll&&!rl&&r
000
MC/DC0%0/3
defined $args and ref $args eq "ARRAY" and scalar @$args > 0
defined $args ref $args eq "ARRAY" scalar @$args > 0
Truth table0%0/4
A and B and C
A= defined $argsB= ref $args eq "ARRAY"C= scalar @$args > 0
ABCresult
0XX0
10X0
1100
1111
2898 0 $return_value .= RS . join(US, @$args);
2899 }
2900 0 return $return_value;
2901 }
2902
2903 # Data
2904 1 ▶use constant DateYear => '@dy';
Subroutine BEGIN: called CC=1 SCAR=0.0
2905 # Month In JavaScript Is Start From Index 0, Month In WebForms Core Is Start From Index 1
2906 1 ▶use constant DateMonth => '@dm';
Subroutine BEGIN: called CC=1 SCAR=0.0
2907 1 ▶use constant DateDay => '@dd';
Subroutine BEGIN: called CC=1 SCAR=0.0
2908 1 ▶use constant DateDate => '@dD';
Subroutine BEGIN: called CC=1 SCAR=0.0
2909 1 ▶use constant DateHours => '@dh';
Subroutine BEGIN: called CC=1 SCAR=0.0
2910 1 ▶use constant DateMinutes => '@di';
Subroutine BEGIN: called CC=1 SCAR=0.0
2911 1 ▶use constant DateSeconds => '@ds';
Subroutine BEGIN: called CC=1 SCAR=0.0
2912 1 ▶use constant DateMilliseconds => '@dl';
Subroutine BEGIN: called CC=1 SCAR=0.0
2913
2914 # String
2915 1 ▶use constant Space => '@sp';
Subroutine BEGIN: called CC=1 SCAR=0.0
2916 1 ▶use constant AtSign => '@sa';
Subroutine BEGIN: called CC=1 SCAR=0.0
2917
2918 # Tag
2919 0 ▶sub get_id {
Subroutine get_id: not called CC=1 SCAR=6.9
2920 0 my ($input_place) = @_;
2921 0 return '@$i' . $input_place;
2922 }
2923
2924 0 ▶sub get_name {
Subroutine get_name: not called CC=1 SCAR=6.9
2925 0 my ($input_place) = @_;
2926 0 return '@$n' . $input_place;
2927 }
2928
2929 0 ▶sub get_value {
Subroutine get_value: not called CC=1 SCAR=6.9
2930 0 my ($input_place) = @_;
2931 0 return '@$v' . $input_place;
2932 }
2933
2934 0 ▶sub get_value_length {
Subroutine get_value_length: not called CC=1 SCAR=6.9
2935 0 my ($input_place) = @_;
2936 0 return '@$e' . $input_place;
2937 }
2938
2939 0 ▶sub get_class {
Subroutine get_class: not called CC=1 SCAR=6.9
2940 0 my ($input_place) = @_;
2941 0 return '@$c' . $input_place;
2942 }
2943
2944 0 ▶sub get_style {
Subroutine get_style: not called CC=1 SCAR=6.9
2945 0 my ($input_place) = @_;
2946 0 return '@$s' . $input_place;
2947 }
2948
2949 0 ▶sub get_title {
Subroutine get_title: not called CC=1 SCAR=6.9
2950 0 my ($input_place) = @_;
2951 0 return '@$l' . $input_place;
2952 }
2953
2954 0 ▶sub get_label {
Subroutine get_label: not called CC=1 SCAR=6.9
2955 0 my ($input_place) = @_;
2956 0 return '@$A' . $input_place;
2957 }
2958
2959 0 ▶sub get_text {
Subroutine get_text: not called CC=1 SCAR=6.9
2960 0 my ($input_place) = @_;
2961 0 return '@$t' . $input_place;
2962 }
2963
2964 0 ▶sub get_outer_text {
Subroutine get_outer_text: not called CC=1 SCAR=6.9
2965 0 my ($input_place) = @_;
2966 0 return '@$o' . $input_place;
2967 }
2968
2969 0 ▶sub get_text_length {
Subroutine get_text_length: not called CC=1 SCAR=6.9
2970 0 my ($input_place) = @_;
2971 0 return '@$g' . $input_place;
2972 }
2973
2974 0 ▶sub get_attribute {
Subroutine get_attribute: not called CC=1 SCAR=6.9
2975 0 my ($input_place, $attribute) = @_;
2976 0 return '@$a' . $input_place . RS . $attribute;
2977 }
2978
2979 0 ▶sub get_width {
Subroutine get_width: not called CC=1 SCAR=6.9
2980 0 my ($input_place) = @_;
2981 0 return '@$w' . $input_place;
2982 }
2983
2984 0 ▶sub get_height {
Subroutine get_height: not called CC=1 SCAR=6.9
2985 0 my ($input_place) = @_;
2986 0 return '@$h' . $input_place;
2987 }
2988
2989 0 ▶sub get_is_read_only {
Subroutine get_is_read_only: not called CC=1 SCAR=6.9
2990 0 my ($input_place) = @_;
2991 0 return '@$r' . $input_place;
2992 }
2993
2994 0 ▶sub get_selected_index {
Subroutine get_selected_index: not called CC=1 SCAR=6.9
2995 0 my ($input_place) = @_;
2996 0 return '@$x' . $input_place;
2997 }
2998
2999 0 ▶sub get_index {
Subroutine get_index: not called CC=1 SCAR=6.9
3000 0 my ($input_place) = @_;
3001 0 return '@$I' . $input_place;
3002 }
3003
3004 0 ▶sub get_text_align {
Subroutine get_text_align: not called CC=1 SCAR=6.9
3005 0 my ($input_place) = @_;
3006 0 return '@$T' . $input_place;
3007 }
3008
3009 0 ▶sub get_node_length {
Subroutine get_node_length: not called CC=1 SCAR=6.9
3010 0 my ($input_place) = @_;
3011 0 return '@$L' . $input_place;
3012 }
3013
3014 0 ▶sub get_is_visible {
Subroutine get_is_visible: not called CC=1 SCAR=6.9
3015 0 my ($input_place) = @_;
3016 0 return '@$V' . $input_place;
3017 }
3018
3019 # Save
3020 0 ▶sub has_hash {
Subroutine has_hash: not called CC=1 SCAR=6.9
3021 0 my ($hash_val) = @_;
3022 0 return '@HH' . $hash_val;
3023 }
3024
3025 0 ▶sub cookie {
Subroutine cookie: not called CC=1 SCAR=6.9
3026 0 my ($key) = @_;
3027 0 return '@co' . $key;
3028 }
3029
3030 0 ▶sub save {
Subroutine save: not called CC=3 SCAR=24.8
3031 0 my ($key, $replace_value) = @_;
3032 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3033 0 ▶ if (!defined $replace_value) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $replace_value) { } 0 0 0
3034 0 return '@cs' . $key;
3035 } else {
3036 0 return '@cs' . $key . RS . $replace_value;
3037 }
3038 }
3039
3040 0 ▶sub save_then_remove {
Subroutine save_then_remove: not called CC=1 SCAR=6.9
3041 0 my ($key) = @_;
3042 0 return '@cl' . $key;
3043 }
3044
3045 0 ▶sub save_length {
Subroutine save_length: not called CC=2 SCAR=17.9
3046 0 my ($key) = @_;
3047 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3048 0 return '@cg' . $key;
3049 }
3050
3051 0 ▶sub cache {
Subroutine cache: not called CC=3 SCAR=24.8
3052 0 my ($key, $replace_value) = @_;
3053 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3054 0 ▶ if (!defined $replace_value) {
Branch: 1 branch
BranchTrueFalseTotal
if (not defined $replace_value) { } 0 0 0
3055 0 return '@cd' . $key;
3056 } else {
3057 0 return '@cd' . $key . RS . $replace_value;
3058 }
3059 }
3060
3061 0 ▶sub cache_then_remove {
Subroutine cache_then_remove: not called CC=1 SCAR=6.9
3062 0 my ($key) = @_;
3063 0 return '@ct' . $key;
3064 }
3065
3066 0 ▶sub cache_length {
Subroutine cache_length: not called CC=2 SCAR=17.9
3067 0 my ($key) = @_;
3068 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3069 0 return '@cG' . $key;
3070 }
3071
3072 0 ▶sub save_line {
Subroutine save_line: not called CC=3 SCAR=24.8
3073 0 my ($key, $line) = @_;
3074 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3075 0 ▶ $line = 0 if !defined $line;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $line 0 0 0
3076 0 return '@lL' . $key . "[" . $line;
3077 }
3078
3079 0 ▶sub save_line_consume {
Subroutine save_line_consume: not called CC=2 SCAR=17.9
3080 0 my ($key) = @_;
3081 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3082 0 return '@lL' . $key;
3083 }
3084
3085 # INIKey: Only Direct Key is Supported
3086 0 ▶sub save_ini {
Subroutine save_ini: not called CC=1 SCAR=6.9
3087 0 my ($key, $ini_key) = @_;
3088 0 return '@lI' . $key . "[" . $ini_key;
3089 }
3090
3091 0 ▶sub cache_line {
Subroutine cache_line: not called CC=3 SCAR=24.8
3092 0 my ($key, $line) = @_;
3093 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3094 0 ▶ $line = 0 if !defined $line;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $line 0 0 0
3095 0 return '@dL' . $key . "[" . $line;
3096 }
3097
3098 0 ▶sub cache_line_consume {
Subroutine cache_line_consume: not called CC=2 SCAR=17.9
3099 0 my ($key) = @_;
3100 0 ▶ $key = "." if !defined $key;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $key 0 0 0
3101 0 return '@dL' . $key;
3102 }
3103
3104 # INIKey: Only Direct Key is Supported
3105 0 ▶sub cache_ini {
Subroutine cache_ini: not called CC=1 SCAR=6.9
3106 0 my ($key, $ini_key) = @_;
3107 0 return '@dI' . $key . "[" . $ini_key;
3108 }
3109
3110 # Format Storage
3111 0 ▶sub format_store {
Subroutine format_store: not called CC=1 SCAR=6.9
3112 0 my ($key) = @_;
3113 0 return '@fr' . $key;
3114 }
3115
3116 0 ▶sub format_store_by_xml_query {
Subroutine format_store_by_xml_query: not called CC=1 SCAR=6.9
3117 0 my ($key, $xpath) = @_;
3118 0 return '@fx' . $key . RS . $xpath;
3119 }
3120
3121 0 ▶sub format_store_by_json_query {
Subroutine format_store_by_json_query: not called CC=1 SCAR=6.9
3122 0 my ($key, $query) = @_;
3123 0 return '@fj' . $key . RS . $query;
3124 }
3125
3126 0 ▶sub format_store_by_ini {
Subroutine format_store_by_ini: not called CC=1 SCAR=6.9
3127 0 my ($key, $name) = @_;
3128 0 return '@fi' . $key . RS . $name;
3129 }
3130
3131 0 ▶sub format_store_by_text {
Subroutine format_store_by_text: not called CC=1 SCAR=6.9
3132 0 my ($key, $line) = @_;
3133 0 return '@ft' . $key . RS . $line;
3134 }
3135
3136 0 ▶sub format_store_by_variable {
Subroutine format_store_by_variable: not called CC=1 SCAR=6.9
3137 0 my ($key) = @_;
3138 0 return '@fv' . $key;
3139 }
3140
3141 # State
3142 0 ▶sub has_state {
Subroutine has_state: not called CC=1 SCAR=6.9
3143 0 my ($path) = @_;
3144 0 return '@hs' . $path;
3145 }
3146
3147 # SSE
3148 0 ▶sub sse_is_connected {
Subroutine sse_is_connected: not called CC=1 SCAR=6.9
3149 0 my ($path) = @_;
3150 0 return '@Sc' . $path;
3151 }
3152
3153 # WebSockets
3154 0 ▶sub web_sockets_is_connected {
Subroutine web_sockets_is_connected: not called CC=2 SCAR=17.9
3155 0 my ($path) = @_;
3156 0 ▶ $path = "" if !defined $path;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $path 0 0 0
3157 0 return '@Wc' . $path;
3158 }
3159
3160 # Document
3161 1 ▶use constant TabIsActive => '@da';
Subroutine BEGIN: called CC=1 SCAR=0.0
3162
3163 # Window
3164 1 ▶use constant Href => '@wf';
Subroutine BEGIN: called CC=1 SCAR=0.0
3165 1 ▶use constant PathName => '@wP';
Subroutine BEGIN: called CC=1 SCAR=0.0
3166
3167 0 ▶sub query {
Subroutine query: not called CC=2 SCAR=17.9
3168 0 my ($name) = @_;
3169 0 ▶ $name = "*" if !defined $name;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $name 0 0 0
3170 0 return '@wq' . $name;
3171 }
3172
3173 1 ▶use constant Hash => '@wh';
Subroutine BEGIN: called CC=1 SCAR=0.0
3174 1 ▶use constant Host => '@wH';
Subroutine BEGIN: called CC=1 SCAR=0.0
3175 1 ▶use constant HostName => '@wn';
Subroutine BEGIN: called CC=1 SCAR=0.0
3176 1 ▶use constant Port => '@wT';
Subroutine BEGIN: called CC=1 SCAR=0.0
3177 1 ▶use constant Origin => '@wo';
Subroutine BEGIN: called CC=1 SCAR=0.0
3178 1 ▶use constant GetSelection => '@ws';
Subroutine BEGIN: called CC=1 SCAR=0.0
3179 1 ▶use constant ScrollX => '@wx';
Subroutine BEGIN: called CC=1 SCAR=0.0
3180 1 ▶use constant ScrollY => '@wy';
Subroutine BEGIN: called CC=1 SCAR=0.0
3181
3182 0 ▶sub segment {
Subroutine segment: not called CC=1 SCAR=6.9
3183 0 my ($index) = @_;
3184 0 return '@wS' . $index;
3185 }
3186
3187 # It Only Works when the String Starts with the Tilde Character (~). The Path is Also Separated by the Slash Character (/). #~/Segment1/Segment2/Segment3
3188 0 ▶sub hash_segment {
Subroutine hash_segment: not called CC=1 SCAR=6.9
3189 0 my ($index) = @_;
3190 0 return '@wt' . $index;
3191 }
3192
3193 # Navigator
3194 1 ▶use constant ClipboardText => '@nC';
Subroutine BEGIN: called CC=1 SCAR=0.0
3195 1 ▶use constant GeoLatitude => '@nW';
Subroutine BEGIN: called CC=1 SCAR=0.0
3196 1 ▶use constant GeoLongitude => '@nO';
Subroutine BEGIN: called CC=1 SCAR=0.0
3197 1 ▶use constant Language => '@nL';
Subroutine BEGIN: called CC=1 SCAR=0.0
3198 1 ▶use constant IsOnLine => '@no';
Subroutine BEGIN: called CC=1 SCAR=0.0
3199 1 ▶use constant UserAgent => '@na';
Subroutine BEGIN: called CC=1 SCAR=0.0
3200
3201 # Screen
3202 1 ▶use constant ScreenWidth => '@sw';
Subroutine BEGIN: called CC=1 SCAR=0.0
3203 1 ▶use constant ScreenHeight => '@sh';
Subroutine BEGIN: called CC=1 SCAR=0.0
3204 1 ▶use constant ScreenOrientationType => '@so';
Subroutine BEGIN: called CC=1 SCAR=0.0
3205 1 ▶use constant ScreenOrientationAngle => '@sr';
Subroutine BEGIN: called CC=1 SCAR=0.0
3206
3207 # Performance
3208 1 ▶use constant TimeOrigin => '@pt';
Subroutine BEGIN: called CC=1 SCAR=0.0
3209 1 ▶use constant PerformanceNow => '@pn';
Subroutine BEGIN: called CC=1 SCAR=0.0
3210
3211 # Event
3212 1 ▶use constant Event => '@EV';
Subroutine BEGIN: called CC=1 SCAR=0.0
3213 1 ▶use constant EventSerialize => '@Es';
Subroutine BEGIN: called CC=1 SCAR=0.0
3214 1 ▶use constant EventKey => '@ek';
Subroutine BEGIN: called CC=1 SCAR=0.0
3215 1 ▶use constant EventWhich => '@ew';
Subroutine BEGIN: called CC=1 SCAR=0.0
3216 1 ▶use constant EventClientX => '@ex';
Subroutine BEGIN: called CC=1 SCAR=0.0
3217 1 ▶use constant EventClientY => '@ey';
Subroutine BEGIN: called CC=1 SCAR=0.0
3218 1 ▶use constant EventPageX => '@eX';
Subroutine BEGIN: called CC=1 SCAR=0.0
3219 1 ▶use constant EventPageY => '@eY';
Subroutine BEGIN: called CC=1 SCAR=0.0
3220 1 ▶use constant EventOffsetX => '@Ex';
Subroutine BEGIN: called CC=1 SCAR=0.0
3221 1 ▶use constant EventOffsetY => '@Ey';
Subroutine BEGIN: called CC=1 SCAR=0.0
3222 1 ▶use constant EventDeltaY => '@ed';
Subroutine BEGIN: called CC=1 SCAR=0.0
3223
3224 package WasmLanguage;
3225 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3226 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
3227 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
3228
3229 # The Suffix "Mediator" Means You Must Call the JavaScript Interface. In Other Cases, the WASM File Should Be Called Directly.
3230 1 ▶use constant C => "c";
Subroutine BEGIN: called CC=1 SCAR=0.0
3231 1 ▶use constant CPP => "c";
Subroutine BEGIN: called CC=1 SCAR=0.0
3232 1 ▶use constant Rust => "rust";
Subroutine BEGIN: called CC=1 SCAR=0.0
3233 1 ▶use constant CSharp => "csharp";
Subroutine BEGIN: called CC=1 SCAR=0.0
3234 # .NET WebCIL Container. The "dotnet.js" File Should Be Invoked.
3235 1 ▶use constant CSharpMediator => "csharp-m";
Subroutine BEGIN: called CC=1 SCAR=0.0
3236 1 ▶use constant GO => "go";
Subroutine BEGIN: called CC=1 SCAR=0.0
3237 1 ▶use constant JAVA => "java";
Subroutine BEGIN: called CC=1 SCAR=0.0
3238 1 ▶use constant AssemblyScript => "as";
Subroutine BEGIN: called CC=1 SCAR=0.0
3239
3240 package HtmlEvent;
3241 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3242 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
3243 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
3244
3245 1 ▶use constant OnAbort => "onabort";
Subroutine BEGIN: called CC=1 SCAR=0.0
3246 1 ▶use constant OnAfterPrint => "onafterprint";
Subroutine BEGIN: called CC=1 SCAR=0.0
3247 1 ▶use constant OnBeforePrint => "onbeforeprint";
Subroutine BEGIN: called CC=1 SCAR=0.0
3248 1 ▶use constant OnBeforeUnload => "onbeforeunload";
Subroutine BEGIN: called CC=1 SCAR=0.0
3249 1 ▶use constant OnBlur => "onblur";
Subroutine BEGIN: called CC=1 SCAR=0.0
3250 1 ▶use constant OnCanPlay => "oncanplay";
Subroutine BEGIN: called CC=1 SCAR=0.0
3251 1 ▶use constant OnCanPlayThrough => "oncanplaythrough";
Subroutine BEGIN: called CC=1 SCAR=0.0
3252 1 ▶use constant OnChange => "onchange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3253 1 ▶use constant OnClick => "onclick";
Subroutine BEGIN: called CC=1 SCAR=0.0
3254 1 ▶use constant OnCopy => "oncopy";
Subroutine BEGIN: called CC=1 SCAR=0.0
3255 1 ▶use constant OnCut => "oncut";
Subroutine BEGIN: called CC=1 SCAR=0.0
3256 1 ▶use constant OnDoubleClick => "ondblclick";
Subroutine BEGIN: called CC=1 SCAR=0.0
3257 1 ▶use constant OnDrag => "ondrag";
Subroutine BEGIN: called CC=1 SCAR=0.0
3258 1 ▶use constant OnDragEnd => "ondragend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3259 1 ▶use constant OnDragEnter => "ondragenter";
Subroutine BEGIN: called CC=1 SCAR=0.0
3260 1 ▶use constant OnDragLeave => "ondragleave";
Subroutine BEGIN: called CC=1 SCAR=0.0
3261 1 ▶use constant OnDragOver => "ondragover";
Subroutine BEGIN: called CC=1 SCAR=0.0
3262 1 ▶use constant OnDragStart => "ondragstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3263 1 ▶use constant OnDrop => "ondrop";
Subroutine BEGIN: called CC=1 SCAR=0.0
3264 1 ▶use constant OnDurationChange => "ondurationchange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3265 1 ▶use constant OnEnded => "onended";
Subroutine BEGIN: called CC=1 SCAR=0.0
3266 1 ▶use constant OnError => "onerror";
Subroutine BEGIN: called CC=1 SCAR=0.0
3267 1 ▶use constant OnFocus => "onfocus";
Subroutine BEGIN: called CC=1 SCAR=0.0
3268 1 ▶use constant OnFocusin => "onfocusin";
Subroutine BEGIN: called CC=1 SCAR=0.0
3269 1 ▶use constant OnFocusOut => "onfocusout";
Subroutine BEGIN: called CC=1 SCAR=0.0
3270 1 ▶use constant OnHashChange => "onhashchange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3271 1 ▶use constant OnInput => "oninput";
Subroutine BEGIN: called CC=1 SCAR=0.0
3272 1 ▶use constant OnInvalid => "oninvalid";
Subroutine BEGIN: called CC=1 SCAR=0.0
3273 1 ▶use constant OnKeyDown => "onkeydown";
Subroutine BEGIN: called CC=1 SCAR=0.0
3274 1 ▶use constant OnKeyPress => "onkeypress";
Subroutine BEGIN: called CC=1 SCAR=0.0
3275 1 ▶use constant OnKeyUp => "onkeyup";
Subroutine BEGIN: called CC=1 SCAR=0.0
3276 1 ▶use constant OnLoad => "onload";
Subroutine BEGIN: called CC=1 SCAR=0.0
3277 1 ▶use constant OnLoadedData => "onloadeddata";
Subroutine BEGIN: called CC=1 SCAR=0.0
3278 1 ▶use constant OnLoadedMetaData => "onloadedmetadata";
Subroutine BEGIN: called CC=1 SCAR=0.0
3279 1 ▶use constant OnLoadStart => "onloadstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3280 1 ▶use constant OnMouseDown => "onmousedown";
Subroutine BEGIN: called CC=1 SCAR=0.0
3281 1 ▶use constant OnMouseEnter => "onmouseenter";
Subroutine BEGIN: called CC=1 SCAR=0.0
3282 1 ▶use constant OnMouseLeave => "onmouseleave";
Subroutine BEGIN: called CC=1 SCAR=0.0
3283 1 ▶use constant OnMouseMove => "onmousemove";
Subroutine BEGIN: called CC=1 SCAR=0.0
3284 1 ▶use constant OnMouseOver => "onmouseover";
Subroutine BEGIN: called CC=1 SCAR=0.0
3285 1 ▶use constant OnMouseOut => "onmouseout";
Subroutine BEGIN: called CC=1 SCAR=0.0
3286 1 ▶use constant OnMouseUp => "onmouseup";
Subroutine BEGIN: called CC=1 SCAR=0.0
3287 1 ▶use constant OnOffline => "onoffline";
Subroutine BEGIN: called CC=1 SCAR=0.0
3288 1 ▶use constant OnOnline => "ononline";
Subroutine BEGIN: called CC=1 SCAR=0.0
3289 1 ▶use constant OnPageHide => "onpagehide";
Subroutine BEGIN: called CC=1 SCAR=0.0
3290 1 ▶use constant OnPageShow => "onpageshow";
Subroutine BEGIN: called CC=1 SCAR=0.0
3291 1 ▶use constant OnPaste => "onpaste";
Subroutine BEGIN: called CC=1 SCAR=0.0
3292 1 ▶use constant OnPause => "onpause";
Subroutine BEGIN: called CC=1 SCAR=0.0
3293 1 ▶use constant OnPlay => "onplay";
Subroutine BEGIN: called CC=1 SCAR=0.0
3294 1 ▶use constant OnPlaying => "onplaying";
Subroutine BEGIN: called CC=1 SCAR=0.0
3295 1 ▶use constant OnProgress => "onprogress";
Subroutine BEGIN: called CC=1 SCAR=0.0
3296 1 ▶use constant OnRateChange => "onratechange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3297 1 ▶use constant OnResize => "onresize";
Subroutine BEGIN: called CC=1 SCAR=0.0
3298 1 ▶use constant OnReset => "onreset";
Subroutine BEGIN: called CC=1 SCAR=0.0
3299 1 ▶use constant OnScroll => "onscroll";
Subroutine BEGIN: called CC=1 SCAR=0.0
3300 1 ▶use constant OnSearch => "onsearch";
Subroutine BEGIN: called CC=1 SCAR=0.0
3301 1 ▶use constant OnSeeked => "onseeked";
Subroutine BEGIN: called CC=1 SCAR=0.0
3302 1 ▶use constant OnSeeking => "onseeking";
Subroutine BEGIN: called CC=1 SCAR=0.0
3303 1 ▶use constant OnSelect => "onselect";
Subroutine BEGIN: called CC=1 SCAR=0.0
3304 1 ▶use constant OnStalled => "onstalled";
Subroutine BEGIN: called CC=1 SCAR=0.0
3305 1 ▶use constant OnSubmit => "onsubmit";
Subroutine BEGIN: called CC=1 SCAR=0.0
3306 1 ▶use constant OnSuspend => "onsuspend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3307 1 ▶use constant OnTimeUpdate => "ontimeupdate";
Subroutine BEGIN: called CC=1 SCAR=0.0
3308 1 ▶use constant OnToggle => "ontoggle";
Subroutine BEGIN: called CC=1 SCAR=0.0
3309 1 ▶use constant OnTouchCancel => "ontouchcancel";
Subroutine BEGIN: called CC=1 SCAR=0.0
3310 1 ▶use constant OnTouchend => "ontouchend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3311 1 ▶use constant OnTouchMove => "ontouchmove";
Subroutine BEGIN: called CC=1 SCAR=0.0
3312 1 ▶use constant OnTouchStart => "ontouchstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3313 1 ▶use constant OnUnload => "onunload";
Subroutine BEGIN: called CC=1 SCAR=0.0
3314 1 ▶use constant OnVolumeChange => "onvolumechange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3315 1 ▶use constant OnWaiting => "onwaiting";
Subroutine BEGIN: called CC=1 SCAR=0.0
3316 1 ▶use constant OnWheel => "onwheel";
Subroutine BEGIN: called CC=1 SCAR=0.0
3317
3318 package HtmlEventListener;
3319 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3320 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
3321 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
3322
3323 1 ▶use constant Abort => "abort";
Subroutine BEGIN: called CC=1 SCAR=0.0
3324 1 ▶use constant AfterPrint => "afterprint";
Subroutine BEGIN: called CC=1 SCAR=0.0
3325 1 ▶use constant BeforePrint => "beforeprint";
Subroutine BEGIN: called CC=1 SCAR=0.0
3326 1 ▶use constant BeforeUnload => "beforeunload";
Subroutine BEGIN: called CC=1 SCAR=0.0
3327 1 ▶use constant Blur => "blur";
Subroutine BEGIN: called CC=1 SCAR=0.0
3328 1 ▶use constant CanPlay => "canplay";
Subroutine BEGIN: called CC=1 SCAR=0.0
3329 1 ▶use constant CanPlayThrough => "canplaythrough";
Subroutine BEGIN: called CC=1 SCAR=0.0
3330 1 ▶use constant Change => "change";
Subroutine BEGIN: called CC=1 SCAR=0.0
3331 1 ▶use constant Click => "click";
Subroutine BEGIN: called CC=1 SCAR=0.0
3332 1 ▶use constant Copy => "copy";
Subroutine BEGIN: called CC=1 SCAR=0.0
3333 1 ▶use constant Cut => "cut";
Subroutine BEGIN: called CC=1 SCAR=0.0
3334 1 ▶use constant DoubleClick => "dblclick";
Subroutine BEGIN: called CC=1 SCAR=0.0
3335 1 ▶use constant Drag => "drag";
Subroutine BEGIN: called CC=1 SCAR=0.0
3336 1 ▶use constant DragEnd => "dragend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3337 1 ▶use constant DragEnter => "dragenter";
Subroutine BEGIN: called CC=1 SCAR=0.0
3338 1 ▶use constant DragLeave => "dragleave";
Subroutine BEGIN: called CC=1 SCAR=0.0
3339 1 ▶use constant DragOver => "dragover";
Subroutine BEGIN: called CC=1 SCAR=0.0
3340 1 ▶use constant DragStart => "dragstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3341 1 ▶use constant Drop => "drop";
Subroutine BEGIN: called CC=1 SCAR=0.0
3342 1 ▶use constant DurationChange => "durationchange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3343 1 ▶use constant Ended => "ended";
Subroutine BEGIN: called CC=1 SCAR=0.0
3344 1 ▶use constant Error => "error";
Subroutine BEGIN: called CC=1 SCAR=0.0
3345 1 ▶use constant Focus => "focus";
Subroutine BEGIN: called CC=1 SCAR=0.0
3346 1 ▶use constant Focusin => "focusin";
Subroutine BEGIN: called CC=1 SCAR=0.0
3347 1 ▶use constant FocusOut => "focusout";
Subroutine BEGIN: called CC=1 SCAR=0.0
3348 1 ▶use constant HashChange => "hashchange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3349 1 ▶use constant Input => "input";
Subroutine BEGIN: called CC=1 SCAR=0.0
3350 1 ▶use constant Invalid => "invalid";
Subroutine BEGIN: called CC=1 SCAR=0.0
3351 1 ▶use constant KeyDown => "keydown";
Subroutine BEGIN: called CC=1 SCAR=0.0
3352 1 ▶use constant KeyPress => "keypress";
Subroutine BEGIN: called CC=1 SCAR=0.0
3353 1 ▶use constant KeyUp => "keyup";
Subroutine BEGIN: called CC=1 SCAR=0.0
3354 1 ▶use constant Load => "load";
Subroutine BEGIN: called CC=1 SCAR=0.0
3355 1 ▶use constant LoadedData => "loadeddata";
Subroutine BEGIN: called CC=1 SCAR=0.0
3356 1 ▶use constant LoadedMetaData => "loadedmetadata";
Subroutine BEGIN: called CC=1 SCAR=0.0
3357 1 ▶use constant LoadStart => "loadstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3358 1 ▶use constant MouseDown => "mousedown";
Subroutine BEGIN: called CC=1 SCAR=0.0
3359 1 ▶use constant MouseEnter => "mouseenter";
Subroutine BEGIN: called CC=1 SCAR=0.0
3360 1 ▶use constant MouseLeave => "mouseleave";
Subroutine BEGIN: called CC=1 SCAR=0.0
3361 1 ▶use constant MouseMove => "mousemove";
Subroutine BEGIN: called CC=1 SCAR=0.0
3362 1 ▶use constant MouseOver => "mouseover";
Subroutine BEGIN: called CC=1 SCAR=0.0
3363 1 ▶use constant MouseOut => "mouseout";
Subroutine BEGIN: called CC=1 SCAR=0.0
3364 1 ▶use constant MouseUp => "mouseup";
Subroutine BEGIN: called CC=1 SCAR=0.0
3365 1 ▶use constant Offline => "offline";
Subroutine BEGIN: called CC=1 SCAR=0.0
3366 1 ▶use constant Online => "online";
Subroutine BEGIN: called CC=1 SCAR=0.0
3367 1 ▶use constant PageHide => "pagehide";
Subroutine BEGIN: called CC=1 SCAR=0.0
3368 1 ▶use constant PageShow => "pageshow";
Subroutine BEGIN: called CC=1 SCAR=0.0
3369 1 ▶use constant Paste => "paste";
Subroutine BEGIN: called CC=1 SCAR=0.0
3370 1 ▶use constant Pause => "pause";
Subroutine BEGIN: called CC=1 SCAR=0.0
3371 1 ▶use constant Play => "play";
Subroutine BEGIN: called CC=1 SCAR=0.0
3372 1 ▶use constant Playing => "playing";
Subroutine BEGIN: called CC=1 SCAR=0.0
3373 1 ▶use constant Progress => "progress";
Subroutine BEGIN: called CC=1 SCAR=0.0
3374 1 ▶use constant RateChange => "ratechange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3375 1 ▶use constant Resize => "resize";
Subroutine BEGIN: called CC=1 SCAR=0.0
3376 1 ▶use constant Reset => "reset";
Subroutine BEGIN: called CC=1 SCAR=0.0
3377 1 ▶use constant Scroll => "scroll";
Subroutine BEGIN: called CC=1 SCAR=0.0
3378 1 ▶use constant Search => "search";
Subroutine BEGIN: called CC=1 SCAR=0.0
3379 1 ▶use constant Seeked => "seeked";
Subroutine BEGIN: called CC=1 SCAR=0.0
3380 1 ▶use constant Seeking => "seeking";
Subroutine BEGIN: called CC=1 SCAR=0.0
3381 1 ▶use constant Select => "select";
Subroutine BEGIN: called CC=1 SCAR=0.0
3382 1 ▶use constant Stalled => "stalled";
Subroutine BEGIN: called CC=1 SCAR=0.0
3383 1 ▶use constant Submit => "submit";
Subroutine BEGIN: called CC=1 SCAR=0.0
3384 1 ▶use constant Suspend => "suspend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3385 1 ▶use constant TimeUpdate => "timeupdate";
Subroutine BEGIN: called CC=1 SCAR=0.0
3386 1 ▶use constant Toggle => "toggle";
Subroutine BEGIN: called CC=1 SCAR=0.0
3387 1 ▶use constant TouchCancel => "touchcancel";
Subroutine BEGIN: called CC=1 SCAR=0.0
3388 1 ▶use constant Touchend => "touchend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3389 1 ▶use constant TouchMove => "touchmove";
Subroutine BEGIN: called CC=1 SCAR=0.0
3390 1 ▶use constant TouchStart => "touchstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3391 1 ▶use constant Unload => "unload";
Subroutine BEGIN: called CC=1 SCAR=0.0
3392 1 ▶use constant VolumeChange => "volumechange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3393 1 ▶use constant Waiting => "waiting";
Subroutine BEGIN: called CC=1 SCAR=0.0
3394 1 ▶use constant Wheel => "wheel";
Subroutine BEGIN: called CC=1 SCAR=0.0
3395
3396 1 ▶use constant AnimationEnd => "animationend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3397 1 ▶use constant AnimationIteration => "animationiteration";
Subroutine BEGIN: called CC=1 SCAR=0.0
3398 1 ▶use constant AnimationStart => "animationstart";
Subroutine BEGIN: called CC=1 SCAR=0.0
3399 1 ▶use constant ContextMenu => "contextmenu";
Subroutine BEGIN: called CC=1 SCAR=0.0
3400 1 ▶use constant FullScreenChange => "fullscreenchange";
Subroutine BEGIN: called CC=1 SCAR=0.0
3401 1 ▶use constant FullScreenError => "fullscreenerror";
Subroutine BEGIN: called CC=1 SCAR=0.0
3402 1 ▶use constant PopState => "popstate";
Subroutine BEGIN: called CC=1 SCAR=0.0
3403 1 ▶use constant TransitionEnd => "transitionend";
Subroutine BEGIN: called CC=1 SCAR=0.0
3404 1 ▶use constant Storage => "storage";
Subroutine BEGIN: called CC=1 SCAR=0.0
3405
3406 # Custom
3407 1 ▶use constant ScrollBottom => "scrollbottom"; # Need Call EnableScrollBottomEvent Method Before
Subroutine BEGIN: called CC=1 SCAR=0.0
3408 1 ▶use constant ElementReached => "elementreached"; # Need Call EnableReachedElementEvent Method Before
Subroutine BEGIN: called CC=1 SCAR=0.0
3409
3410 package Extension;
3411 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3412 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
3413 1 ▶use v5.36;
Subroutine BEGIN: called CC=1 SCAR=0.0
3414
3415 # Simulates C# Extension Methods for strings in a natural Perl way.
3416 0 ▶sub child {
Subroutine child: not called CC=2 SCAR=17.9
3417 0 my ($text, $value) = @_;
3418 0 ▶ return $value if length($text) < 1;
Branch: 1 branch
BranchTrueFalseTotal
if length $text < 1 0 0 0
3419 0 return $text . "|" . $value;
3420 }
3421
3422 0 ▶sub parent {
Subroutine parent: not called CC=4 SCAR=30.0
3423 0 my ($text) = @_;
3424 0 ▶ return $text if length($text) < 1;
Branch: 1 branch
BranchTrueFalseTotal
if length $text < 1 0 0 0
3425 0 ▶ if ($text =~ /\|\/$/ || $text =~ /\/\//) {
Branch: 1 branch
BranchTrueFalseTotal
if ($text =~ m[\|/$]u or $text =~ m[//]u) 0 0 0
Condition0%0/3
$text =~ m[\|/$]u or $text =~ m[//]u
l!l&&r!l&&!r
000
MC/DC0%0/2
$text =~ m[\|/$]u or $text =~ m[//]u
$text =~ m[\|/$]u $text =~ m[//]u
Truth table0%0/3
A or B
A= $text =~ m[\|/$]uB= $text =~ m[//]u
ABresult
1X1
011
000
3426 0 return $text . '/';
3427 }
3428 0 return $text . "|/";
3429 }
3430
3431 0 ▶sub criteria {
Subroutine criteria: not called CC=2 SCAR=17.9
3432 0 my ($text, $value) = @_;
3433 0 ▶ return $value if length($text) < 1;
Branch: 1 branch
BranchTrueFalseTotal
if length $text < 1 0 0 0
3434 0 my $res = $value;
3435 0 $res =~ s/\|/\$[vb];/g;
3436 0 $res =~ s/\?/\$[qu];/g;
3437 0 return $text . "?" . $res;
3438 }
3439
3440 0 ▶sub append_fetch_replace {
Subroutine append_fetch_replace: not called CC=1 SCAR=6.9
3441 0 my ($text, $search_value, $value) = @_;
3442 0 my $fs = chr(28);
3443 0 my $clean_text = substr($text, 1);
3444 0 return '@;' . $search_value . $fs . $value . $fs . $clean_text;
3445 }
3446
3447 0 ▶sub line_break {
Subroutine line_break: not called CC=3 SCAR=24.8
3448 0 my ($text, $encode_line) = @_;
3449 0 ▶ $encode_line = 0 if !defined $encode_line;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $encode_line 0 0 0
3450 0 ▶ my $encode = $encode_line ? "\$[sln];" : "";
Branch: 1 branch
BranchTrueFalseTotal
$encode_line ? : 0 0 0
3451 0 my $res = $text;
3452 0 $res =~ s/\r\n/$encode/g;
3453 0 $res =~ s/\n/$encode/g;
3454 0 $res =~ s/\r/$encode/g;
3455 0 return $res;
3456 }
3457
3458 # Converts Numbers to Strings
3459 0 ▶sub to_js_string {
Subroutine to_js_string: not called CC=1 SCAR=6.9
3460 0 my ($text) = @_;
3461 0 return "\"" . $text . "\"";
3462 }
3463
3464 # Get JS Object Momentary
3465 0 ▶sub to_js_object {
Subroutine to_js_object: not called CC=1 SCAR=6.9
3466 0 my ($text) = @_;
3467 0 return "\$" . $text;
3468 }
3469
3470 # Get JS Object Returned Value Once
3471 0 ▶sub to_js_return_object {
Subroutine to_js_return_object: not called CC=1 SCAR=6.9
3472 0 my ($text) = @_;
3473 0 return "\$@" . $text;
3474 }
3475
3476 1 1;
↑ Summary