Types.pm

filter: Statementstmt 10.1% 240 / 2376 Branchbran 0.0% 0 / 876 Conditioncond 0.0% 0 / 60 MC/DCmcdc 0.0% 0 / 30 Subroutinesub 43.9% 94 / 214 Podpod n/a totaltotal 9.3% 334 / 3556 CC 509 SCAR 57.9
CC
509
Cov
7%
read
2970.0
new
812.0
write
756.0
CRAP 328.6
↑ Summary Lite.pm »
1 #
2 # Autogenerated by Thrift
3 #
4 # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5 #
6 1 require 5.6.0;
7 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
9 1 ▶use Thrift;
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 package Cassandra::ConsistencyLevel;
12 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
13 1 $Cassandra::ConsistencyLevel::VERSION = '0.4.0';
14 }
15 1 ▶use constant ONE => 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
16 1 ▶use constant QUORUM => 2;
Subroutine BEGIN: called CC=1 SCAR=0.0
17 1 ▶use constant LOCAL_QUORUM => 3;
Subroutine BEGIN: called CC=1 SCAR=0.0
18 1 ▶use constant EACH_QUORUM => 4;
Subroutine BEGIN: called CC=1 SCAR=0.0
19 1 ▶use constant ALL => 5;
Subroutine BEGIN: called CC=1 SCAR=0.0
20 1 ▶use constant ANY => 6;
Subroutine BEGIN: called CC=1 SCAR=0.0
21 1 ▶use constant TWO => 7;
Subroutine BEGIN: called CC=1 SCAR=0.0
22 1 ▶use constant THREE => 8;
Subroutine BEGIN: called CC=1 SCAR=0.0
23 package Cassandra::IndexOperator;
24 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
25 1 $Cassandra::IndexOperator::VERSION = '0.4.0';
26 }
27 1 ▶use constant EQ => 0;
Subroutine BEGIN: called CC=1 SCAR=0.0
28 1 ▶use constant GTE => 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
29 1 ▶use constant GT => 2;
Subroutine BEGIN: called CC=1 SCAR=0.0
30 1 ▶use constant LTE => 3;
Subroutine BEGIN: called CC=1 SCAR=0.0
31 1 ▶use constant LT => 4;
Subroutine BEGIN: called CC=1 SCAR=0.0
32 package Cassandra::IndexType;
33 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
34 1 $Cassandra::IndexType::VERSION = '0.4.0';
35 }
36 1 ▶use constant KEYS => 0;
Subroutine BEGIN: called CC=1 SCAR=0.0
37 package Cassandra::Compression;
38 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
39 1 $Cassandra::Compression::VERSION = '0.4.0';
40 }
41 1 ▶use constant GZIP => 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
42 1 ▶use constant NONE => 2;
Subroutine BEGIN: called CC=1 SCAR=0.0
43 package Cassandra::CqlResultType;
44 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
45 1 $Cassandra::CqlResultType::VERSION = '0.4.0';
46 }
47 1 ▶use constant ROWS => 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
48 1 ▶use constant VOID => 2;
Subroutine BEGIN: called CC=1 SCAR=0.0
49 1 ▶use constant INT => 3;
Subroutine BEGIN: called CC=1 SCAR=0.0
50 package Cassandra::Column;
51 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
52 1 $Cassandra::Column::VERSION = '0.4.0';
53 }
54 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
55 1 Cassandra::Column->mk_accessors( qw( name value timestamp ttl ) );
56  
57 0 ▶sub new {
Subroutine new: not called CC=7 SCAR=40.3
58 0 my $classname = shift;
59 0 my $self = {};
60 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
61 0 $self->{name} = undef;
62 0 $self->{value} = undef;
63 0 $self->{timestamp} = undef;
64 0 $self->{ttl} = undef;
65 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
66 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
67 0 $self->{name} = $vals->{name};
68 }
69 0 ▶ if (defined $vals->{value}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"value"}) 0 0 0
70 0 $self->{value} = $vals->{value};
71 }
72 0 ▶ if (defined $vals->{timestamp}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"timestamp"}) 0 0 0
73 0 $self->{timestamp} = $vals->{timestamp};
74 }
75 0 ▶ if (defined $vals->{ttl}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"ttl"}) 0 0 0
76 0 $self->{ttl} = $vals->{ttl};
77 }
78 }
79 0 return bless ($self, $classname);
80 }
81  
82 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
83 0 return 'Column';
84 }
85  
86 0 ▶sub read {
Subroutine read: not called CC=11 SCAR=48.8
87 0 my ($self, $input) = @_;
88 0 my $xfer = 0;
89 0 my $fname;
90 0 my $ftype = 0;
91 0 my $fid = 0;
92 0 $xfer += $input->readStructBegin(\$fname);
93 0 while (1)
94 {
95 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
96 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
97 0 last;
98 }
99 0 SWITCH: for($fid)
100 {
101 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
102 0 $xfer += $input->readString(\$self->{name});
103 } else {
104 0 $xfer += $input->skip($ftype);
105 }
106 0 last; };
107 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"value"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
108 0 $xfer += $input->readString(\$self->{value});
109 } else {
110 0 $xfer += $input->skip($ftype);
111 }
112 0 last; };
113 0 ▶ /^3$/ && do{ if ($ftype == TType::I64) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 10) { $xfer += $input->readI64(\$self->{"timestamp"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 10) { } 0 0 0
114 0 $xfer += $input->readI64(\$self->{timestamp});
115 } else {
116 0 $xfer += $input->skip($ftype);
117 }
118 0 last; };
119 0 ▶ /^4$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"ttl"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
120 0 $xfer += $input->readI32(\$self->{ttl});
121 } else {
122 0 $xfer += $input->skip($ftype);
123 }
124 0 last; };
125 0 $xfer += $input->skip($ftype);
126 }
127 0 $xfer += $input->readFieldEnd();
128 }
129 0 $xfer += $input->readStructEnd();
130 0 return $xfer;
131 }
132  
133 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
134 0 my ($self, $output) = @_;
135 0 my $xfer = 0;
136 0 $xfer += $output->writeStructBegin('Column');
137 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
138 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
139 0 $xfer += $output->writeString($self->{name});
140 0 $xfer += $output->writeFieldEnd();
141 }
142 0 ▶ if (defined $self->{value}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"value"}) 0 0 0
143 0 $xfer += $output->writeFieldBegin('value', TType::STRING, 2);
144 0 $xfer += $output->writeString($self->{value});
145 0 $xfer += $output->writeFieldEnd();
146 }
147 0 ▶ if (defined $self->{timestamp}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"timestamp"}) 0 0 0
148 0 $xfer += $output->writeFieldBegin('timestamp', TType::I64, 3);
149 0 $xfer += $output->writeI64($self->{timestamp});
150 0 $xfer += $output->writeFieldEnd();
151 }
152 0 ▶ if (defined $self->{ttl}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"ttl"}) 0 0 0
153 0 $xfer += $output->writeFieldBegin('ttl', TType::I32, 4);
154 0 $xfer += $output->writeI32($self->{ttl});
155 0 $xfer += $output->writeFieldEnd();
156 }
157 0 $xfer += $output->writeFieldStop();
158 0 $xfer += $output->writeStructEnd();
159 0 return $xfer;
160 }
161  
162 package Cassandra::SuperColumn;
163 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
164 1 $Cassandra::SuperColumn::VERSION = '0.4.0';
165 }
166 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
167 1 Cassandra::SuperColumn->mk_accessors( qw( name columns ) );
168  
169 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
170 0 my $classname = shift;
171 0 my $self = {};
172 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
173 0 $self->{name} = undef;
174 0 $self->{columns} = undef;
175 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
176 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
177 0 $self->{name} = $vals->{name};
178 }
179 0 ▶ if (defined $vals->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"columns"}) 0 0 0
180 0 $self->{columns} = $vals->{columns};
181 }
182 }
183 0 return bless ($self, $classname);
184 }
185  
186 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
187 0 return 'SuperColumn';
188 }
189  
190 0 ▶sub read {
Subroutine read: not called CC=8 SCAR=42.8
191 0 my ($self, $input) = @_;
192 0 my $xfer = 0;
193 0 my $fname;
194 0 my $ftype = 0;
195 0 my $fid = 0;
196 0 $xfer += $input->readStructBegin(\$fname);
197 0 while (1)
198 {
199 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
200 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
201 0 last;
202 }
203 0 SWITCH: for($fid)
204 {
205 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
206 0 $xfer += $input->readString(\$self->{name});
207 } else {
208 0 $xfer += $input->skip($ftype);
209 }
210 0 last; };
211 0 ▶ /^2$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 15) { { my $_size0 = 0; $self->{"columns"} = []; my $_etype3 = 0; $xfer += $input->readListBegin(\$_etype3, \$_size0); for (my $_i4 = 0; $_i4 < $_size0; ++$_i4) { my $elem5 = undef; $elem5 = "Cassandra::Column"->new; $xfer += $elem5->read($input); push @{$$self{"columns"};}, $elem5; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
212 {
213 0 my $_size0 = 0;
214 0 $self->{columns} = [];
215 0 my $_etype3 = 0;
216 0 $xfer += $input->readListBegin(\$_etype3, \$_size0);
217 0 ▶ for (my $_i4 = 0; $_i4 < $_size0; ++$_i4)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i4 < $_size0) 0 0 0
218 {
219 0 my $elem5 = undef;
220 0 $elem5 = new Cassandra::Column();
221 0 $xfer += $elem5->read($input);
222 0 push(@{$self->{columns}},$elem5);
223 }
224 0 $xfer += $input->readListEnd();
225 }
226 } else {
227 0 $xfer += $input->skip($ftype);
228 }
229 0 last; };
230 0 $xfer += $input->skip($ftype);
231 }
232 0 $xfer += $input->readFieldEnd();
233 }
234 0 $xfer += $input->readStructEnd();
235 0 return $xfer;
236 }
237  
238 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
239 0 my ($self, $output) = @_;
240 0 my $xfer = 0;
241 0 $xfer += $output->writeStructBegin('SuperColumn');
242 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
243 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
244 0 $xfer += $output->writeString($self->{name});
245 0 $xfer += $output->writeFieldEnd();
246 }
247 0 ▶ if (defined $self->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"columns"}) 0 0 0
248 0 $xfer += $output->writeFieldBegin('columns', TType::LIST, 2);
249 {
250 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{columns}}));
251 {
252 0 foreach my $iter6 (@{$self->{columns}})
253 {
254 0 $xfer += ${iter6}->write($output);
255 }
256 }
257 0 $xfer += $output->writeListEnd();
258 }
259 0 $xfer += $output->writeFieldEnd();
260 }
261 0 $xfer += $output->writeFieldStop();
262 0 $xfer += $output->writeStructEnd();
263 0 return $xfer;
264 }
265  
266 package Cassandra::CounterColumn;
267 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
268 1 $Cassandra::CounterColumn::VERSION = '0.4.0';
269 }
270 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
271 1 Cassandra::CounterColumn->mk_accessors( qw( name value ) );
272  
273 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
274 0 my $classname = shift;
275 0 my $self = {};
276 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
277 0 $self->{name} = undef;
278 0 $self->{value} = undef;
279 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
280 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
281 0 $self->{name} = $vals->{name};
282 }
283 0 ▶ if (defined $vals->{value}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"value"}) 0 0 0
284 0 $self->{value} = $vals->{value};
285 }
286 }
287 0 return bless ($self, $classname);
288 }
289  
290 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
291 0 return 'CounterColumn';
292 }
293  
294 0 ▶sub read {
Subroutine read: not called CC=7 SCAR=40.3
295 0 my ($self, $input) = @_;
296 0 my $xfer = 0;
297 0 my $fname;
298 0 my $ftype = 0;
299 0 my $fid = 0;
300 0 $xfer += $input->readStructBegin(\$fname);
301 0 while (1)
302 {
303 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
304 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
305 0 last;
306 }
307 0 SWITCH: for($fid)
308 {
309 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
310 0 $xfer += $input->readString(\$self->{name});
311 } else {
312 0 $xfer += $input->skip($ftype);
313 }
314 0 last; };
315 0 ▶ /^2$/ && do{ if ($ftype == TType::I64) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 10) { $xfer += $input->readI64(\$self->{"value"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 10) { } 0 0 0
316 0 $xfer += $input->readI64(\$self->{value});
317 } else {
318 0 $xfer += $input->skip($ftype);
319 }
320 0 last; };
321 0 $xfer += $input->skip($ftype);
322 }
323 0 $xfer += $input->readFieldEnd();
324 }
325 0 $xfer += $input->readStructEnd();
326 0 return $xfer;
327 }
328  
329 0 ▶sub write {
Subroutine write: not called CC=3 SCAR=24.8
330 0 my ($self, $output) = @_;
331 0 my $xfer = 0;
332 0 $xfer += $output->writeStructBegin('CounterColumn');
333 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
334 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
335 0 $xfer += $output->writeString($self->{name});
336 0 $xfer += $output->writeFieldEnd();
337 }
338 0 ▶ if (defined $self->{value}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"value"}) 0 0 0
339 0 $xfer += $output->writeFieldBegin('value', TType::I64, 2);
340 0 $xfer += $output->writeI64($self->{value});
341 0 $xfer += $output->writeFieldEnd();
342 }
343 0 $xfer += $output->writeFieldStop();
344 0 $xfer += $output->writeStructEnd();
345 0 return $xfer;
346 }
347  
348 package Cassandra::CounterSuperColumn;
349 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
350 1 $Cassandra::CounterSuperColumn::VERSION = '0.4.0';
351 }
352 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
353 1 Cassandra::CounterSuperColumn->mk_accessors( qw( name columns ) );
354  
355 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
356 0 my $classname = shift;
357 0 my $self = {};
358 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
359 0 $self->{name} = undef;
360 0 $self->{columns} = undef;
361 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
362 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
363 0 $self->{name} = $vals->{name};
364 }
365 0 ▶ if (defined $vals->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"columns"}) 0 0 0
366 0 $self->{columns} = $vals->{columns};
367 }
368 }
369 0 return bless ($self, $classname);
370 }
371  
372 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
373 0 return 'CounterSuperColumn';
374 }
375  
376 0 ▶sub read {
Subroutine read: not called CC=8 SCAR=42.8
377 0 my ($self, $input) = @_;
378 0 my $xfer = 0;
379 0 my $fname;
380 0 my $ftype = 0;
381 0 my $fid = 0;
382 0 $xfer += $input->readStructBegin(\$fname);
383 0 while (1)
384 {
385 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
386 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
387 0 last;
388 }
389 0 SWITCH: for($fid)
390 {
391 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
392 0 $xfer += $input->readString(\$self->{name});
393 } else {
394 0 $xfer += $input->skip($ftype);
395 }
396 0 last; };
397 0 ▶ /^2$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 15) { { my $_size7 = 0; $self->{"columns"} = []; my $_etype10 = 0; $xfer += $input->readListBegin(\$_etype10, \$_size7); for (my $_i11 = 0; $_i11 < $_size7; ++$_i11) { my $elem12 = undef; $elem12 = "Cassandra::CounterColumn"->new; $xfer += $elem12->read($input); push @{$$self{"columns"};}, $elem12; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
398 {
399 0 my $_size7 = 0;
400 0 $self->{columns} = [];
401 0 my $_etype10 = 0;
402 0 $xfer += $input->readListBegin(\$_etype10, \$_size7);
403 0 ▶ for (my $_i11 = 0; $_i11 < $_size7; ++$_i11)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i11 < $_size7) 0 0 0
404 {
405 0 my $elem12 = undef;
406 0 $elem12 = new Cassandra::CounterColumn();
407 0 $xfer += $elem12->read($input);
408 0 push(@{$self->{columns}},$elem12);
409 }
410 0 $xfer += $input->readListEnd();
411 }
412 } else {
413 0 $xfer += $input->skip($ftype);
414 }
415 0 last; };
416 0 $xfer += $input->skip($ftype);
417 }
418 0 $xfer += $input->readFieldEnd();
419 }
420 0 $xfer += $input->readStructEnd();
421 0 return $xfer;
422 }
423  
424 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
425 0 my ($self, $output) = @_;
426 0 my $xfer = 0;
427 0 $xfer += $output->writeStructBegin('CounterSuperColumn');
428 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
429 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
430 0 $xfer += $output->writeString($self->{name});
431 0 $xfer += $output->writeFieldEnd();
432 }
433 0 ▶ if (defined $self->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"columns"}) 0 0 0
434 0 $xfer += $output->writeFieldBegin('columns', TType::LIST, 2);
435 {
436 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{columns}}));
437 {
438 0 foreach my $iter13 (@{$self->{columns}})
439 {
440 0 $xfer += ${iter13}->write($output);
441 }
442 }
443 0 $xfer += $output->writeListEnd();
444 }
445 0 $xfer += $output->writeFieldEnd();
446 }
447 0 $xfer += $output->writeFieldStop();
448 0 $xfer += $output->writeStructEnd();
449 0 return $xfer;
450 }
451  
452 package Cassandra::ColumnOrSuperColumn;
453 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
454 1 $Cassandra::ColumnOrSuperColumn::VERSION = '0.4.0';
455 }
456 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
457 1 Cassandra::ColumnOrSuperColumn->mk_accessors( qw( column super_column counter_column counter_super_column ) );
458  
459 0 ▶sub new {
Subroutine new: not called CC=7 SCAR=40.3
460 0 my $classname = shift;
461 0 my $self = {};
462 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
463 0 $self->{column} = undef;
464 0 $self->{super_column} = undef;
465 0 $self->{counter_column} = undef;
466 0 $self->{counter_super_column} = undef;
467 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
468 0 ▶ if (defined $vals->{column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column"}) 0 0 0
469 0 $self->{column} = $vals->{column};
470 }
471 0 ▶ if (defined $vals->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"super_column"}) 0 0 0
472 0 $self->{super_column} = $vals->{super_column};
473 }
474 0 ▶ if (defined $vals->{counter_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"counter_column"}) 0 0 0
475 0 $self->{counter_column} = $vals->{counter_column};
476 }
477 0 ▶ if (defined $vals->{counter_super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"counter_super_column"}) 0 0 0
478 0 $self->{counter_super_column} = $vals->{counter_super_column};
479 }
480 }
481 0 return bless ($self, $classname);
482 }
483  
484 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
485 0 return 'ColumnOrSuperColumn';
486 }
487  
488 0 ▶sub read {
Subroutine read: not called CC=11 SCAR=48.8
489 0 my ($self, $input) = @_;
490 0 my $xfer = 0;
491 0 my $fname;
492 0 my $ftype = 0;
493 0 my $fid = 0;
494 0 $xfer += $input->readStructBegin(\$fname);
495 0 while (1)
496 {
497 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
498 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
499 0 last;
500 }
501 0 SWITCH: for($fid)
502 {
503 0 ▶ /^1$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 12) { $self->{"column"} = "Cassandra::Column"->new; $xfer += $self->{"column"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
504 0 $self->{column} = new Cassandra::Column();
505 0 $xfer += $self->{column}->read($input);
506 } else {
507 0 $xfer += $input->skip($ftype);
508 }
509 0 last; };
510 0 ▶ /^2$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 12) { $self->{"super_column"} = "Cassandra::SuperColumn"->new; $xfer += $self->{"super_column"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
511 0 $self->{super_column} = new Cassandra::SuperColumn();
512 0 $xfer += $self->{super_column}->read($input);
513 } else {
514 0 $xfer += $input->skip($ftype);
515 }
516 0 last; };
517 0 ▶ /^3$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 12) { $self->{"counter_column"} = "Cassandra::CounterColumn"->new; $xfer += $self->{"counter_column"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
518 0 $self->{counter_column} = new Cassandra::CounterColumn();
519 0 $xfer += $self->{counter_column}->read($input);
520 } else {
521 0 $xfer += $input->skip($ftype);
522 }
523 0 last; };
524 0 ▶ /^4$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 12) { $self->{"counter_super_column"} = "Cassandra::CounterSuperColumn"->new; $xfer += $self->{"counter_super_column"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
525 0 $self->{counter_super_column} = new Cassandra::CounterSuperColumn();
526 0 $xfer += $self->{counter_super_column}->read($input);
527 } else {
528 0 $xfer += $input->skip($ftype);
529 }
530 0 last; };
531 0 $xfer += $input->skip($ftype);
532 }
533 0 $xfer += $input->readFieldEnd();
534 }
535 0 $xfer += $input->readStructEnd();
536 0 return $xfer;
537 }
538  
539 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
540 0 my ($self, $output) = @_;
541 0 my $xfer = 0;
542 0 $xfer += $output->writeStructBegin('ColumnOrSuperColumn');
543 0 ▶ if (defined $self->{column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column"}) 0 0 0
544 0 $xfer += $output->writeFieldBegin('column', TType::STRUCT, 1);
545 0 $xfer += $self->{column}->write($output);
546 0 $xfer += $output->writeFieldEnd();
547 }
548 0 ▶ if (defined $self->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"super_column"}) 0 0 0
549 0 $xfer += $output->writeFieldBegin('super_column', TType::STRUCT, 2);
550 0 $xfer += $self->{super_column}->write($output);
551 0 $xfer += $output->writeFieldEnd();
552 }
553 0 ▶ if (defined $self->{counter_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"counter_column"}) 0 0 0
554 0 $xfer += $output->writeFieldBegin('counter_column', TType::STRUCT, 3);
555 0 $xfer += $self->{counter_column}->write($output);
556 0 $xfer += $output->writeFieldEnd();
557 }
558 0 ▶ if (defined $self->{counter_super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"counter_super_column"}) 0 0 0
559 0 $xfer += $output->writeFieldBegin('counter_super_column', TType::STRUCT, 4);
560 0 $xfer += $self->{counter_super_column}->write($output);
561 0 $xfer += $output->writeFieldEnd();
562 }
563 0 $xfer += $output->writeFieldStop();
564 0 $xfer += $output->writeStructEnd();
565 0 return $xfer;
566 }
567  
568 package Cassandra::NotFoundException;
569 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
570 1 $Cassandra::NotFoundException::VERSION = '0.4.0';
571 }
572 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
573 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
574  
575 0 ▶sub new {
Subroutine new: not called CC=2 SCAR=17.9
576 0 my $classname = shift;
577 0 my $self = {};
578 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
579 0 return bless ($self, $classname);
580 }
581  
582 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
583 0 return 'NotFoundException';
584 }
585  
586 0 ▶sub read {
Subroutine read: not called CC=3 SCAR=24.8
587 0 my ($self, $input) = @_;
588 0 my $xfer = 0;
589 0 my $fname;
590 0 my $ftype = 0;
591 0 my $fid = 0;
592 0 $xfer += $input->readStructBegin(\$fname);
593 0 while (1)
594 {
595 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
596 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
597 0 last;
598 }
599 0 SWITCH: for($fid)
600 {
601 0 $xfer += $input->skip($ftype);
602 }
603 0 $xfer += $input->readFieldEnd();
604 }
605 0 $xfer += $input->readStructEnd();
606 0 return $xfer;
607 }
608  
609 0 ▶sub write {
Subroutine write: not called CC=1 SCAR=6.9
610 0 my ($self, $output) = @_;
611 0 my $xfer = 0;
612 0 $xfer += $output->writeStructBegin('NotFoundException');
613 0 $xfer += $output->writeFieldStop();
614 0 $xfer += $output->writeStructEnd();
615 0 return $xfer;
616 }
617  
618 package Cassandra::InvalidRequestException;
619 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
620 1 $Cassandra::InvalidRequestException::VERSION = '0.4.0';
621 }
622 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
623 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
624 1 Cassandra::InvalidRequestException->mk_accessors( qw( why ) );
625  
626 0 ▶sub new {
Subroutine new: not called CC=4 SCAR=30.0
627 0 my $classname = shift;
628 0 my $self = {};
629 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
630 0 $self->{why} = undef;
631 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
632 0 ▶ if (defined $vals->{why}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"why"}) 0 0 0
633 0 $self->{why} = $vals->{why};
634 }
635 }
636 0 return bless ($self, $classname);
637 }
638  
639 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
640 0 return 'InvalidRequestException';
641 }
642  
643 0 ▶sub read {
Subroutine read: not called CC=5 SCAR=34.0
644 0 my ($self, $input) = @_;
645 0 my $xfer = 0;
646 0 my $fname;
647 0 my $ftype = 0;
648 0 my $fid = 0;
649 0 $xfer += $input->readStructBegin(\$fname);
650 0 while (1)
651 {
652 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
653 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
654 0 last;
655 }
656 0 SWITCH: for($fid)
657 {
658 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"why"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
659 0 $xfer += $input->readString(\$self->{why});
660 } else {
661 0 $xfer += $input->skip($ftype);
662 }
663 0 last; };
664 0 $xfer += $input->skip($ftype);
665 }
666 0 $xfer += $input->readFieldEnd();
667 }
668 0 $xfer += $input->readStructEnd();
669 0 return $xfer;
670 }
671  
672 0 ▶sub write {
Subroutine write: not called CC=2 SCAR=17.9
673 0 my ($self, $output) = @_;
674 0 my $xfer = 0;
675 0 $xfer += $output->writeStructBegin('InvalidRequestException');
676 0 ▶ if (defined $self->{why}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"why"}) 0 0 0
677 0 $xfer += $output->writeFieldBegin('why', TType::STRING, 1);
678 0 $xfer += $output->writeString($self->{why});
679 0 $xfer += $output->writeFieldEnd();
680 }
681 0 $xfer += $output->writeFieldStop();
682 0 $xfer += $output->writeStructEnd();
683 0 return $xfer;
684 }
685  
686 package Cassandra::UnavailableException;
687 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
688 1 $Cassandra::UnavailableException::VERSION = '0.4.0';
689 }
690 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
691 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
692  
693 0 ▶sub new {
Subroutine new: not called CC=2 SCAR=17.9
694 0 my $classname = shift;
695 0 my $self = {};
696 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
697 0 return bless ($self, $classname);
698 }
699  
700 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
701 0 return 'UnavailableException';
702 }
703  
704 0 ▶sub read {
Subroutine read: not called CC=3 SCAR=24.8
705 0 my ($self, $input) = @_;
706 0 my $xfer = 0;
707 0 my $fname;
708 0 my $ftype = 0;
709 0 my $fid = 0;
710 0 $xfer += $input->readStructBegin(\$fname);
711 0 while (1)
712 {
713 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
714 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
715 0 last;
716 }
717 0 SWITCH: for($fid)
718 {
719 0 $xfer += $input->skip($ftype);
720 }
721 0 $xfer += $input->readFieldEnd();
722 }
723 0 $xfer += $input->readStructEnd();
724 0 return $xfer;
725 }
726  
727 0 ▶sub write {
Subroutine write: not called CC=1 SCAR=6.9
728 0 my ($self, $output) = @_;
729 0 my $xfer = 0;
730 0 $xfer += $output->writeStructBegin('UnavailableException');
731 0 $xfer += $output->writeFieldStop();
732 0 $xfer += $output->writeStructEnd();
733 0 return $xfer;
734 }
735  
736 package Cassandra::TimedOutException;
737 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
738 1 $Cassandra::TimedOutException::VERSION = '0.4.0';
739 }
740 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
741 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
742  
743 0 ▶sub new {
Subroutine new: not called CC=2 SCAR=17.9
744 0 my $classname = shift;
745 0 my $self = {};
746 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
747 0 return bless ($self, $classname);
748 }
749  
750 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
751 0 return 'TimedOutException';
752 }
753  
754 0 ▶sub read {
Subroutine read: not called CC=3 SCAR=24.8
755 0 my ($self, $input) = @_;
756 0 my $xfer = 0;
757 0 my $fname;
758 0 my $ftype = 0;
759 0 my $fid = 0;
760 0 $xfer += $input->readStructBegin(\$fname);
761 0 while (1)
762 {
763 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
764 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
765 0 last;
766 }
767 0 SWITCH: for($fid)
768 {
769 0 $xfer += $input->skip($ftype);
770 }
771 0 $xfer += $input->readFieldEnd();
772 }
773 0 $xfer += $input->readStructEnd();
774 0 return $xfer;
775 }
776  
777 0 ▶sub write {
Subroutine write: not called CC=1 SCAR=6.9
778 0 my ($self, $output) = @_;
779 0 my $xfer = 0;
780 0 $xfer += $output->writeStructBegin('TimedOutException');
781 0 $xfer += $output->writeFieldStop();
782 0 $xfer += $output->writeStructEnd();
783 0 return $xfer;
784 }
785  
786 package Cassandra::AuthenticationException;
787 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
788 1 $Cassandra::AuthenticationException::VERSION = '0.4.0';
789 }
790 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
791 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
792 1 Cassandra::AuthenticationException->mk_accessors( qw( why ) );
793  
794 0 ▶sub new {
Subroutine new: not called CC=4 SCAR=30.0
795 0 my $classname = shift;
796 0 my $self = {};
797 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
798 0 $self->{why} = undef;
799 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
800 0 ▶ if (defined $vals->{why}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"why"}) 0 0 0
801 0 $self->{why} = $vals->{why};
802 }
803 }
804 0 return bless ($self, $classname);
805 }
806  
807 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
808 0 return 'AuthenticationException';
809 }
810  
811 0 ▶sub read {
Subroutine read: not called CC=5 SCAR=34.0
812 0 my ($self, $input) = @_;
813 0 my $xfer = 0;
814 0 my $fname;
815 0 my $ftype = 0;
816 0 my $fid = 0;
817 0 $xfer += $input->readStructBegin(\$fname);
818 0 while (1)
819 {
820 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
821 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
822 0 last;
823 }
824 0 SWITCH: for($fid)
825 {
826 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"why"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
827 0 $xfer += $input->readString(\$self->{why});
828 } else {
829 0 $xfer += $input->skip($ftype);
830 }
831 0 last; };
832 0 $xfer += $input->skip($ftype);
833 }
834 0 $xfer += $input->readFieldEnd();
835 }
836 0 $xfer += $input->readStructEnd();
837 0 return $xfer;
838 }
839  
840 0 ▶sub write {
Subroutine write: not called CC=2 SCAR=17.9
841 0 my ($self, $output) = @_;
842 0 my $xfer = 0;
843 0 $xfer += $output->writeStructBegin('AuthenticationException');
844 0 ▶ if (defined $self->{why}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"why"}) 0 0 0
845 0 $xfer += $output->writeFieldBegin('why', TType::STRING, 1);
846 0 $xfer += $output->writeString($self->{why});
847 0 $xfer += $output->writeFieldEnd();
848 }
849 0 $xfer += $output->writeFieldStop();
850 0 $xfer += $output->writeStructEnd();
851 0 return $xfer;
852 }
853  
854 package Cassandra::AuthorizationException;
855 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
856 1 $Cassandra::AuthorizationException::VERSION = '0.4.0';
857 }
858 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
859 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
860 1 Cassandra::AuthorizationException->mk_accessors( qw( why ) );
861  
862 0 ▶sub new {
Subroutine new: not called CC=4 SCAR=30.0
863 0 my $classname = shift;
864 0 my $self = {};
865 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
866 0 $self->{why} = undef;
867 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
868 0 ▶ if (defined $vals->{why}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"why"}) 0 0 0
869 0 $self->{why} = $vals->{why};
870 }
871 }
872 0 return bless ($self, $classname);
873 }
874  
875 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
876 0 return 'AuthorizationException';
877 }
878  
879 0 ▶sub read {
Subroutine read: not called CC=5 SCAR=34.0
880 0 my ($self, $input) = @_;
881 0 my $xfer = 0;
882 0 my $fname;
883 0 my $ftype = 0;
884 0 my $fid = 0;
885 0 $xfer += $input->readStructBegin(\$fname);
886 0 while (1)
887 {
888 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
889 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
890 0 last;
891 }
892 0 SWITCH: for($fid)
893 {
894 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"why"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
895 0 $xfer += $input->readString(\$self->{why});
896 } else {
897 0 $xfer += $input->skip($ftype);
898 }
899 0 last; };
900 0 $xfer += $input->skip($ftype);
901 }
902 0 $xfer += $input->readFieldEnd();
903 }
904 0 $xfer += $input->readStructEnd();
905 0 return $xfer;
906 }
907  
908 0 ▶sub write {
Subroutine write: not called CC=2 SCAR=17.9
909 0 my ($self, $output) = @_;
910 0 my $xfer = 0;
911 0 $xfer += $output->writeStructBegin('AuthorizationException');
912 0 ▶ if (defined $self->{why}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"why"}) 0 0 0
913 0 $xfer += $output->writeFieldBegin('why', TType::STRING, 1);
914 0 $xfer += $output->writeString($self->{why});
915 0 $xfer += $output->writeFieldEnd();
916 }
917 0 $xfer += $output->writeFieldStop();
918 0 $xfer += $output->writeStructEnd();
919 0 return $xfer;
920 }
921  
922 package Cassandra::SchemaDisagreementException;
923 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
924 1 $Cassandra::SchemaDisagreementException::VERSION = '0.4.0';
925 }
926 1 ▶use base qw(Thrift::TException);
Subroutine BEGIN: called CC=1 SCAR=0.0
927 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
928  
929 0 ▶sub new {
Subroutine new: not called CC=2 SCAR=17.9
930 0 my $classname = shift;
931 0 my $self = {};
932 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
933 0 return bless ($self, $classname);
934 }
935  
936 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
937 0 return 'SchemaDisagreementException';
938 }
939  
940 0 ▶sub read {
Subroutine read: not called CC=3 SCAR=24.8
941 0 my ($self, $input) = @_;
942 0 my $xfer = 0;
943 0 my $fname;
944 0 my $ftype = 0;
945 0 my $fid = 0;
946 0 $xfer += $input->readStructBegin(\$fname);
947 0 while (1)
948 {
949 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
950 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
951 0 last;
952 }
953 0 SWITCH: for($fid)
954 {
955 0 $xfer += $input->skip($ftype);
956 }
957 0 $xfer += $input->readFieldEnd();
958 }
959 0 $xfer += $input->readStructEnd();
960 0 return $xfer;
961 }
962  
963 0 ▶sub write {
Subroutine write: not called CC=1 SCAR=6.9
964 0 my ($self, $output) = @_;
965 0 my $xfer = 0;
966 0 $xfer += $output->writeStructBegin('SchemaDisagreementException');
967 0 $xfer += $output->writeFieldStop();
968 0 $xfer += $output->writeStructEnd();
969 0 return $xfer;
970 }
971  
972 package Cassandra::ColumnParent;
973 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
974 1 $Cassandra::ColumnParent::VERSION = '0.4.0';
975 }
976 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
977 1 Cassandra::ColumnParent->mk_accessors( qw( column_family super_column ) );
978  
979 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
980 0 my $classname = shift;
981 0 my $self = {};
982 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
983 0 $self->{column_family} = undef;
984 0 $self->{super_column} = undef;
985 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
986 0 ▶ if (defined $vals->{column_family}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_family"}) 0 0 0
987 0 $self->{column_family} = $vals->{column_family};
988 }
989 0 ▶ if (defined $vals->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"super_column"}) 0 0 0
990 0 $self->{super_column} = $vals->{super_column};
991 }
992 }
993 0 return bless ($self, $classname);
994 }
995  
996 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
997 0 return 'ColumnParent';
998 }
999  
1000 0 ▶sub read {
Subroutine read: not called CC=7 SCAR=40.3
1001 0 my ($self, $input) = @_;
1002 0 my $xfer = 0;
1003 0 my $fname;
1004 0 my $ftype = 0;
1005 0 my $fid = 0;
1006 0 $xfer += $input->readStructBegin(\$fname);
1007 0 while (1)
1008 {
1009 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1010 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1011 0 last;
1012 }
1013 0 SWITCH: for($fid)
1014 {
1015 0 ▶ /^3$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"column_family"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1016 0 $xfer += $input->readString(\$self->{column_family});
1017 } else {
1018 0 $xfer += $input->skip($ftype);
1019 }
1020 0 last; };
1021 0 ▶ /^4$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"super_column"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1022 0 $xfer += $input->readString(\$self->{super_column});
1023 } else {
1024 0 $xfer += $input->skip($ftype);
1025 }
1026 0 last; };
1027 0 $xfer += $input->skip($ftype);
1028 }
1029 0 $xfer += $input->readFieldEnd();
1030 }
1031 0 $xfer += $input->readStructEnd();
1032 0 return $xfer;
1033 }
1034  
1035 0 ▶sub write {
Subroutine write: not called CC=3 SCAR=24.8
1036 0 my ($self, $output) = @_;
1037 0 my $xfer = 0;
1038 0 $xfer += $output->writeStructBegin('ColumnParent');
1039 0 ▶ if (defined $self->{column_family}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_family"}) 0 0 0
1040 0 $xfer += $output->writeFieldBegin('column_family', TType::STRING, 3);
1041 0 $xfer += $output->writeString($self->{column_family});
1042 0 $xfer += $output->writeFieldEnd();
1043 }
1044 0 ▶ if (defined $self->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"super_column"}) 0 0 0
1045 0 $xfer += $output->writeFieldBegin('super_column', TType::STRING, 4);
1046 0 $xfer += $output->writeString($self->{super_column});
1047 0 $xfer += $output->writeFieldEnd();
1048 }
1049 0 $xfer += $output->writeFieldStop();
1050 0 $xfer += $output->writeStructEnd();
1051 0 return $xfer;
1052 }
1053  
1054 package Cassandra::ColumnPath;
1055 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1056 1 $Cassandra::ColumnPath::VERSION = '0.4.0';
1057 }
1058 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1059 1 Cassandra::ColumnPath->mk_accessors( qw( column_family super_column column ) );
1060  
1061 0 ▶sub new {
Subroutine new: not called CC=6 SCAR=37.4
1062 0 my $classname = shift;
1063 0 my $self = {};
1064 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1065 0 $self->{column_family} = undef;
1066 0 $self->{super_column} = undef;
1067 0 $self->{column} = undef;
1068 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1069 0 ▶ if (defined $vals->{column_family}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_family"}) 0 0 0
1070 0 $self->{column_family} = $vals->{column_family};
1071 }
1072 0 ▶ if (defined $vals->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"super_column"}) 0 0 0
1073 0 $self->{super_column} = $vals->{super_column};
1074 }
1075 0 ▶ if (defined $vals->{column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column"}) 0 0 0
1076 0 $self->{column} = $vals->{column};
1077 }
1078 }
1079 0 return bless ($self, $classname);
1080 }
1081  
1082 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1083 0 return 'ColumnPath';
1084 }
1085  
1086 0 ▶sub read {
Subroutine read: not called CC=9 SCAR=45.0
1087 0 my ($self, $input) = @_;
1088 0 my $xfer = 0;
1089 0 my $fname;
1090 0 my $ftype = 0;
1091 0 my $fid = 0;
1092 0 $xfer += $input->readStructBegin(\$fname);
1093 0 while (1)
1094 {
1095 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1096 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1097 0 last;
1098 }
1099 0 SWITCH: for($fid)
1100 {
1101 0 ▶ /^3$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"column_family"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1102 0 $xfer += $input->readString(\$self->{column_family});
1103 } else {
1104 0 $xfer += $input->skip($ftype);
1105 }
1106 0 last; };
1107 0 ▶ /^4$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"super_column"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1108 0 $xfer += $input->readString(\$self->{super_column});
1109 } else {
1110 0 $xfer += $input->skip($ftype);
1111 }
1112 0 last; };
1113 0 ▶ /^5$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^5$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"column"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1114 0 $xfer += $input->readString(\$self->{column});
1115 } else {
1116 0 $xfer += $input->skip($ftype);
1117 }
1118 0 last; };
1119 0 $xfer += $input->skip($ftype);
1120 }
1121 0 $xfer += $input->readFieldEnd();
1122 }
1123 0 $xfer += $input->readStructEnd();
1124 0 return $xfer;
1125 }
1126  
1127 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
1128 0 my ($self, $output) = @_;
1129 0 my $xfer = 0;
1130 0 $xfer += $output->writeStructBegin('ColumnPath');
1131 0 ▶ if (defined $self->{column_family}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_family"}) 0 0 0
1132 0 $xfer += $output->writeFieldBegin('column_family', TType::STRING, 3);
1133 0 $xfer += $output->writeString($self->{column_family});
1134 0 $xfer += $output->writeFieldEnd();
1135 }
1136 0 ▶ if (defined $self->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"super_column"}) 0 0 0
1137 0 $xfer += $output->writeFieldBegin('super_column', TType::STRING, 4);
1138 0 $xfer += $output->writeString($self->{super_column});
1139 0 $xfer += $output->writeFieldEnd();
1140 }
1141 0 ▶ if (defined $self->{column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column"}) 0 0 0
1142 0 $xfer += $output->writeFieldBegin('column', TType::STRING, 5);
1143 0 $xfer += $output->writeString($self->{column});
1144 0 $xfer += $output->writeFieldEnd();
1145 }
1146 0 $xfer += $output->writeFieldStop();
1147 0 $xfer += $output->writeStructEnd();
1148 0 return $xfer;
1149 }
1150  
1151 package Cassandra::SliceRange;
1152 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1153 1 $Cassandra::SliceRange::VERSION = '0.4.0';
1154 }
1155 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1156 1 Cassandra::SliceRange->mk_accessors( qw( start finish reversed count ) );
1157  
1158 0 ▶sub new {
Subroutine new: not called CC=7 SCAR=40.3
1159 0 my $classname = shift;
1160 0 my $self = {};
1161 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1162 0 $self->{start} = undef;
1163 0 $self->{finish} = undef;
1164 0 $self->{reversed} = 0;
1165 0 $self->{count} = 100;
1166 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1167 0 ▶ if (defined $vals->{start}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"start"}) 0 0 0
1168 0 $self->{start} = $vals->{start};
1169 }
1170 0 ▶ if (defined $vals->{finish}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"finish"}) 0 0 0
1171 0 $self->{finish} = $vals->{finish};
1172 }
1173 0 ▶ if (defined $vals->{reversed}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"reversed"}) 0 0 0
1174 0 $self->{reversed} = $vals->{reversed};
1175 }
1176 0 ▶ if (defined $vals->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"count"}) 0 0 0
1177 0 $self->{count} = $vals->{count};
1178 }
1179 }
1180 0 return bless ($self, $classname);
1181 }
1182  
1183 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1184 0 return 'SliceRange';
1185 }
1186  
1187 0 ▶sub read {
Subroutine read: not called CC=11 SCAR=48.8
1188 0 my ($self, $input) = @_;
1189 0 my $xfer = 0;
1190 0 my $fname;
1191 0 my $ftype = 0;
1192 0 my $fid = 0;
1193 0 $xfer += $input->readStructBegin(\$fname);
1194 0 while (1)
1195 {
1196 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1197 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1198 0 last;
1199 }
1200 0 SWITCH: for($fid)
1201 {
1202 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"start"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1203 0 $xfer += $input->readString(\$self->{start});
1204 } else {
1205 0 $xfer += $input->skip($ftype);
1206 }
1207 0 last; };
1208 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"finish"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1209 0 $xfer += $input->readString(\$self->{finish});
1210 } else {
1211 0 $xfer += $input->skip($ftype);
1212 }
1213 0 last; };
1214 0 ▶ /^3$/ && do{ if ($ftype == TType::BOOL) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 2) { $xfer += $input->readBool(\$self->{"reversed"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 2) { } 0 0 0
1215 0 $xfer += $input->readBool(\$self->{reversed});
1216 } else {
1217 0 $xfer += $input->skip($ftype);
1218 }
1219 0 last; };
1220 0 ▶ /^4$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"count"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
1221 0 $xfer += $input->readI32(\$self->{count});
1222 } else {
1223 0 $xfer += $input->skip($ftype);
1224 }
1225 0 last; };
1226 0 $xfer += $input->skip($ftype);
1227 }
1228 0 $xfer += $input->readFieldEnd();
1229 }
1230 0 $xfer += $input->readStructEnd();
1231 0 return $xfer;
1232 }
1233  
1234 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
1235 0 my ($self, $output) = @_;
1236 0 my $xfer = 0;
1237 0 $xfer += $output->writeStructBegin('SliceRange');
1238 0 ▶ if (defined $self->{start}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"start"}) 0 0 0
1239 0 $xfer += $output->writeFieldBegin('start', TType::STRING, 1);
1240 0 $xfer += $output->writeString($self->{start});
1241 0 $xfer += $output->writeFieldEnd();
1242 }
1243 0 ▶ if (defined $self->{finish}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"finish"}) 0 0 0
1244 0 $xfer += $output->writeFieldBegin('finish', TType::STRING, 2);
1245 0 $xfer += $output->writeString($self->{finish});
1246 0 $xfer += $output->writeFieldEnd();
1247 }
1248 0 ▶ if (defined $self->{reversed}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"reversed"}) 0 0 0
1249 0 $xfer += $output->writeFieldBegin('reversed', TType::BOOL, 3);
1250 0 $xfer += $output->writeBool($self->{reversed});
1251 0 $xfer += $output->writeFieldEnd();
1252 }
1253 0 ▶ if (defined $self->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"count"}) 0 0 0
1254 0 $xfer += $output->writeFieldBegin('count', TType::I32, 4);
1255 0 $xfer += $output->writeI32($self->{count});
1256 0 $xfer += $output->writeFieldEnd();
1257 }
1258 0 $xfer += $output->writeFieldStop();
1259 0 $xfer += $output->writeStructEnd();
1260 0 return $xfer;
1261 }
1262  
1263 package Cassandra::SlicePredicate;
1264 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1265 1 $Cassandra::SlicePredicate::VERSION = '0.4.0';
1266 }
1267 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1268 1 Cassandra::SlicePredicate->mk_accessors( qw( column_names slice_range ) );
1269  
1270 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
1271 0 my $classname = shift;
1272 0 my $self = {};
1273 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1274 0 $self->{column_names} = undef;
1275 0 $self->{slice_range} = undef;
1276 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1277 0 ▶ if (defined $vals->{column_names}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_names"}) 0 0 0
1278 0 $self->{column_names} = $vals->{column_names};
1279 }
1280 0 ▶ if (defined $vals->{slice_range}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"slice_range"}) 0 0 0
1281 0 $self->{slice_range} = $vals->{slice_range};
1282 }
1283 }
1284 0 return bless ($self, $classname);
1285 }
1286  
1287 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1288 0 return 'SlicePredicate';
1289 }
1290  
1291 0 ▶sub read {
Subroutine read: not called CC=8 SCAR=42.8
1292 0 my ($self, $input) = @_;
1293 0 my $xfer = 0;
1294 0 my $fname;
1295 0 my $ftype = 0;
1296 0 my $fid = 0;
1297 0 $xfer += $input->readStructBegin(\$fname);
1298 0 while (1)
1299 {
1300 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1301 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1302 0 last;
1303 }
1304 0 SWITCH: for($fid)
1305 {
1306 0 ▶ /^1$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 15) { { my $_size14 = 0; $self->{"column_names"} = []; my $_etype17 = 0; $xfer += $input->readListBegin(\$_etype17, \$_size14); for (my $_i18 = 0; $_i18 < $_size14; ++$_i18) { my $elem19 = undef; $xfer += $input->readString(\$elem19); push @{$$self{"column_names"};}, $elem19; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
1307 {
1308 0 my $_size14 = 0;
1309 0 $self->{column_names} = [];
1310 0 my $_etype17 = 0;
1311 0 $xfer += $input->readListBegin(\$_etype17, \$_size14);
1312 0 ▶ for (my $_i18 = 0; $_i18 < $_size14; ++$_i18)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i18 < $_size14) 0 0 0
1313 {
1314 0 my $elem19 = undef;
1315 0 $xfer += $input->readString(\$elem19);
1316 0 push(@{$self->{column_names}},$elem19);
1317 }
1318 0 $xfer += $input->readListEnd();
1319 }
1320 } else {
1321 0 $xfer += $input->skip($ftype);
1322 }
1323 0 last; };
1324 0 ▶ /^2$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 12) { $self->{"slice_range"} = "Cassandra::SliceRange"->new; $xfer += $self->{"slice_range"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
1325 0 $self->{slice_range} = new Cassandra::SliceRange();
1326 0 $xfer += $self->{slice_range}->read($input);
1327 } else {
1328 0 $xfer += $input->skip($ftype);
1329 }
1330 0 last; };
1331 0 $xfer += $input->skip($ftype);
1332 }
1333 0 $xfer += $input->readFieldEnd();
1334 }
1335 0 $xfer += $input->readStructEnd();
1336 0 return $xfer;
1337 }
1338  
1339 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
1340 0 my ($self, $output) = @_;
1341 0 my $xfer = 0;
1342 0 $xfer += $output->writeStructBegin('SlicePredicate');
1343 0 ▶ if (defined $self->{column_names}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_names"}) 0 0 0
1344 0 $xfer += $output->writeFieldBegin('column_names', TType::LIST, 1);
1345 {
1346 0 $xfer += $output->writeListBegin(TType::STRING, scalar(@{$self->{column_names}}));
1347 {
1348 0 foreach my $iter20 (@{$self->{column_names}})
1349 {
1350 0 $xfer += $output->writeString($iter20);
1351 }
1352 }
1353 0 $xfer += $output->writeListEnd();
1354 }
1355 0 $xfer += $output->writeFieldEnd();
1356 }
1357 0 ▶ if (defined $self->{slice_range}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"slice_range"}) 0 0 0
1358 0 $xfer += $output->writeFieldBegin('slice_range', TType::STRUCT, 2);
1359 0 $xfer += $self->{slice_range}->write($output);
1360 0 $xfer += $output->writeFieldEnd();
1361 }
1362 0 $xfer += $output->writeFieldStop();
1363 0 $xfer += $output->writeStructEnd();
1364 0 return $xfer;
1365 }
1366  
1367 package Cassandra::IndexExpression;
1368 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1369 1 $Cassandra::IndexExpression::VERSION = '0.4.0';
1370 }
1371 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1372 1 Cassandra::IndexExpression->mk_accessors( qw( column_name op value ) );
1373  
1374 0 ▶sub new {
Subroutine new: not called CC=6 SCAR=37.4
1375 0 my $classname = shift;
1376 0 my $self = {};
1377 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1378 0 $self->{column_name} = undef;
1379 0 $self->{op} = undef;
1380 0 $self->{value} = undef;
1381 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1382 0 ▶ if (defined $vals->{column_name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_name"}) 0 0 0
1383 0 $self->{column_name} = $vals->{column_name};
1384 }
1385 0 ▶ if (defined $vals->{op}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"op"}) 0 0 0
1386 0 $self->{op} = $vals->{op};
1387 }
1388 0 ▶ if (defined $vals->{value}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"value"}) 0 0 0
1389 0 $self->{value} = $vals->{value};
1390 }
1391 }
1392 0 return bless ($self, $classname);
1393 }
1394  
1395 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1396 0 return 'IndexExpression';
1397 }
1398  
1399 0 ▶sub read {
Subroutine read: not called CC=9 SCAR=45.0
1400 0 my ($self, $input) = @_;
1401 0 my $xfer = 0;
1402 0 my $fname;
1403 0 my $ftype = 0;
1404 0 my $fid = 0;
1405 0 $xfer += $input->readStructBegin(\$fname);
1406 0 while (1)
1407 {
1408 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1409 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1410 0 last;
1411 }
1412 0 SWITCH: for($fid)
1413 {
1414 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"column_name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1415 0 $xfer += $input->readString(\$self->{column_name});
1416 } else {
1417 0 $xfer += $input->skip($ftype);
1418 }
1419 0 last; };
1420 0 ▶ /^2$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"op"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
1421 0 $xfer += $input->readI32(\$self->{op});
1422 } else {
1423 0 $xfer += $input->skip($ftype);
1424 }
1425 0 last; };
1426 0 ▶ /^3$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"value"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1427 0 $xfer += $input->readString(\$self->{value});
1428 } else {
1429 0 $xfer += $input->skip($ftype);
1430 }
1431 0 last; };
1432 0 $xfer += $input->skip($ftype);
1433 }
1434 0 $xfer += $input->readFieldEnd();
1435 }
1436 0 $xfer += $input->readStructEnd();
1437 0 return $xfer;
1438 }
1439  
1440 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
1441 0 my ($self, $output) = @_;
1442 0 my $xfer = 0;
1443 0 $xfer += $output->writeStructBegin('IndexExpression');
1444 0 ▶ if (defined $self->{column_name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_name"}) 0 0 0
1445 0 $xfer += $output->writeFieldBegin('column_name', TType::STRING, 1);
1446 0 $xfer += $output->writeString($self->{column_name});
1447 0 $xfer += $output->writeFieldEnd();
1448 }
1449 0 ▶ if (defined $self->{op}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"op"}) 0 0 0
1450 0 $xfer += $output->writeFieldBegin('op', TType::I32, 2);
1451 0 $xfer += $output->writeI32($self->{op});
1452 0 $xfer += $output->writeFieldEnd();
1453 }
1454 0 ▶ if (defined $self->{value}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"value"}) 0 0 0
1455 0 $xfer += $output->writeFieldBegin('value', TType::STRING, 3);
1456 0 $xfer += $output->writeString($self->{value});
1457 0 $xfer += $output->writeFieldEnd();
1458 }
1459 0 $xfer += $output->writeFieldStop();
1460 0 $xfer += $output->writeStructEnd();
1461 0 return $xfer;
1462 }
1463  
1464 package Cassandra::IndexClause;
1465 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1466 1 $Cassandra::IndexClause::VERSION = '0.4.0';
1467 }
1468 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1469 1 Cassandra::IndexClause->mk_accessors( qw( expressions start_key count ) );
1470  
1471 0 ▶sub new {
Subroutine new: not called CC=6 SCAR=37.4
1472 0 my $classname = shift;
1473 0 my $self = {};
1474 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1475 0 $self->{expressions} = undef;
1476 0 $self->{start_key} = undef;
1477 0 $self->{count} = 100;
1478 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1479 0 ▶ if (defined $vals->{expressions}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"expressions"}) 0 0 0
1480 0 $self->{expressions} = $vals->{expressions};
1481 }
1482 0 ▶ if (defined $vals->{start_key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"start_key"}) 0 0 0
1483 0 $self->{start_key} = $vals->{start_key};
1484 }
1485 0 ▶ if (defined $vals->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"count"}) 0 0 0
1486 0 $self->{count} = $vals->{count};
1487 }
1488 }
1489 0 return bless ($self, $classname);
1490 }
1491  
1492 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1493 0 return 'IndexClause';
1494 }
1495  
1496 0 ▶sub read {
Subroutine read: not called CC=10 SCAR=47.0
1497 0 my ($self, $input) = @_;
1498 0 my $xfer = 0;
1499 0 my $fname;
1500 0 my $ftype = 0;
1501 0 my $fid = 0;
1502 0 $xfer += $input->readStructBegin(\$fname);
1503 0 while (1)
1504 {
1505 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1506 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1507 0 last;
1508 }
1509 0 SWITCH: for($fid)
1510 {
1511 0 ▶ /^1$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 15) { { my $_size21 = 0; $self->{"expressions"} = []; my $_etype24 = 0; $xfer += $input->readListBegin(\$_etype24, \$_size21); for (my $_i25 = 0; $_i25 < $_size21; ++$_i25) { my $elem26 = undef; $elem26 = "Cassandra::IndexExpression"->new; $xfer += $elem26->read($input); push @{$$self{"expressions"};}, $elem26; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
1512 {
1513 0 my $_size21 = 0;
1514 0 $self->{expressions} = [];
1515 0 my $_etype24 = 0;
1516 0 $xfer += $input->readListBegin(\$_etype24, \$_size21);
1517 0 ▶ for (my $_i25 = 0; $_i25 < $_size21; ++$_i25)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i25 < $_size21) 0 0 0
1518 {
1519 0 my $elem26 = undef;
1520 0 $elem26 = new Cassandra::IndexExpression();
1521 0 $xfer += $elem26->read($input);
1522 0 push(@{$self->{expressions}},$elem26);
1523 }
1524 0 $xfer += $input->readListEnd();
1525 }
1526 } else {
1527 0 $xfer += $input->skip($ftype);
1528 }
1529 0 last; };
1530 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"start_key"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1531 0 $xfer += $input->readString(\$self->{start_key});
1532 } else {
1533 0 $xfer += $input->skip($ftype);
1534 }
1535 0 last; };
1536 0 ▶ /^3$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"count"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
1537 0 $xfer += $input->readI32(\$self->{count});
1538 } else {
1539 0 $xfer += $input->skip($ftype);
1540 }
1541 0 last; };
1542 0 $xfer += $input->skip($ftype);
1543 }
1544 0 $xfer += $input->readFieldEnd();
1545 }
1546 0 $xfer += $input->readStructEnd();
1547 0 return $xfer;
1548 }
1549  
1550 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
1551 0 my ($self, $output) = @_;
1552 0 my $xfer = 0;
1553 0 $xfer += $output->writeStructBegin('IndexClause');
1554 0 ▶ if (defined $self->{expressions}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"expressions"}) 0 0 0
1555 0 $xfer += $output->writeFieldBegin('expressions', TType::LIST, 1);
1556 {
1557 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{expressions}}));
1558 {
1559 0 foreach my $iter27 (@{$self->{expressions}})
1560 {
1561 0 $xfer += ${iter27}->write($output);
1562 }
1563 }
1564 0 $xfer += $output->writeListEnd();
1565 }
1566 0 $xfer += $output->writeFieldEnd();
1567 }
1568 0 ▶ if (defined $self->{start_key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"start_key"}) 0 0 0
1569 0 $xfer += $output->writeFieldBegin('start_key', TType::STRING, 2);
1570 0 $xfer += $output->writeString($self->{start_key});
1571 0 $xfer += $output->writeFieldEnd();
1572 }
1573 0 ▶ if (defined $self->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"count"}) 0 0 0
1574 0 $xfer += $output->writeFieldBegin('count', TType::I32, 3);
1575 0 $xfer += $output->writeI32($self->{count});
1576 0 $xfer += $output->writeFieldEnd();
1577 }
1578 0 $xfer += $output->writeFieldStop();
1579 0 $xfer += $output->writeStructEnd();
1580 0 return $xfer;
1581 }
1582  
1583 package Cassandra::KeyRange;
1584 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1585 1 $Cassandra::KeyRange::VERSION = '0.4.0';
1586 }
1587 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1588 1 Cassandra::KeyRange->mk_accessors( qw( start_key end_key start_token end_token count ) );
1589  
1590 0 ▶sub new {
Subroutine new: not called CC=8 SCAR=42.8
1591 0 my $classname = shift;
1592 0 my $self = {};
1593 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1594 0 $self->{start_key} = undef;
1595 0 $self->{end_key} = undef;
1596 0 $self->{start_token} = undef;
1597 0 $self->{end_token} = undef;
1598 0 $self->{count} = 100;
1599 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1600 0 ▶ if (defined $vals->{start_key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"start_key"}) 0 0 0
1601 0 $self->{start_key} = $vals->{start_key};
1602 }
1603 0 ▶ if (defined $vals->{end_key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"end_key"}) 0 0 0
1604 0 $self->{end_key} = $vals->{end_key};
1605 }
1606 0 ▶ if (defined $vals->{start_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"start_token"}) 0 0 0
1607 0 $self->{start_token} = $vals->{start_token};
1608 }
1609 0 ▶ if (defined $vals->{end_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"end_token"}) 0 0 0
1610 0 $self->{end_token} = $vals->{end_token};
1611 }
1612 0 ▶ if (defined $vals->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"count"}) 0 0 0
1613 0 $self->{count} = $vals->{count};
1614 }
1615 }
1616 0 return bless ($self, $classname);
1617 }
1618  
1619 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1620 0 return 'KeyRange';
1621 }
1622  
1623 0 ▶sub read {
Subroutine read: not called CC=13 SCAR=52.0
1624 0 my ($self, $input) = @_;
1625 0 my $xfer = 0;
1626 0 my $fname;
1627 0 my $ftype = 0;
1628 0 my $fid = 0;
1629 0 $xfer += $input->readStructBegin(\$fname);
1630 0 while (1)
1631 {
1632 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1633 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1634 0 last;
1635 }
1636 0 SWITCH: for($fid)
1637 {
1638 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"start_key"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1639 0 $xfer += $input->readString(\$self->{start_key});
1640 } else {
1641 0 $xfer += $input->skip($ftype);
1642 }
1643 0 last; };
1644 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"end_key"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1645 0 $xfer += $input->readString(\$self->{end_key});
1646 } else {
1647 0 $xfer += $input->skip($ftype);
1648 }
1649 0 last; };
1650 0 ▶ /^3$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"start_token"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1651 0 $xfer += $input->readString(\$self->{start_token});
1652 } else {
1653 0 $xfer += $input->skip($ftype);
1654 }
1655 0 last; };
1656 0 ▶ /^4$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"end_token"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1657 0 $xfer += $input->readString(\$self->{end_token});
1658 } else {
1659 0 $xfer += $input->skip($ftype);
1660 }
1661 0 last; };
1662 0 ▶ /^5$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^5$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"count"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
1663 0 $xfer += $input->readI32(\$self->{count});
1664 } else {
1665 0 $xfer += $input->skip($ftype);
1666 }
1667 0 last; };
1668 0 $xfer += $input->skip($ftype);
1669 }
1670 0 $xfer += $input->readFieldEnd();
1671 }
1672 0 $xfer += $input->readStructEnd();
1673 0 return $xfer;
1674 }
1675  
1676 0 ▶sub write {
Subroutine write: not called CC=6 SCAR=37.4
1677 0 my ($self, $output) = @_;
1678 0 my $xfer = 0;
1679 0 $xfer += $output->writeStructBegin('KeyRange');
1680 0 ▶ if (defined $self->{start_key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"start_key"}) 0 0 0
1681 0 $xfer += $output->writeFieldBegin('start_key', TType::STRING, 1);
1682 0 $xfer += $output->writeString($self->{start_key});
1683 0 $xfer += $output->writeFieldEnd();
1684 }
1685 0 ▶ if (defined $self->{end_key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"end_key"}) 0 0 0
1686 0 $xfer += $output->writeFieldBegin('end_key', TType::STRING, 2);
1687 0 $xfer += $output->writeString($self->{end_key});
1688 0 $xfer += $output->writeFieldEnd();
1689 }
1690 0 ▶ if (defined $self->{start_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"start_token"}) 0 0 0
1691 0 $xfer += $output->writeFieldBegin('start_token', TType::STRING, 3);
1692 0 $xfer += $output->writeString($self->{start_token});
1693 0 $xfer += $output->writeFieldEnd();
1694 }
1695 0 ▶ if (defined $self->{end_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"end_token"}) 0 0 0
1696 0 $xfer += $output->writeFieldBegin('end_token', TType::STRING, 4);
1697 0 $xfer += $output->writeString($self->{end_token});
1698 0 $xfer += $output->writeFieldEnd();
1699 }
1700 0 ▶ if (defined $self->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"count"}) 0 0 0
1701 0 $xfer += $output->writeFieldBegin('count', TType::I32, 5);
1702 0 $xfer += $output->writeI32($self->{count});
1703 0 $xfer += $output->writeFieldEnd();
1704 }
1705 0 $xfer += $output->writeFieldStop();
1706 0 $xfer += $output->writeStructEnd();
1707 0 return $xfer;
1708 }
1709  
1710 package Cassandra::KeySlice;
1711 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1712 1 $Cassandra::KeySlice::VERSION = '0.4.0';
1713 }
1714 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1715 1 Cassandra::KeySlice->mk_accessors( qw( key columns ) );
1716  
1717 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
1718 0 my $classname = shift;
1719 0 my $self = {};
1720 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1721 0 $self->{key} = undef;
1722 0 $self->{columns} = undef;
1723 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1724 0 ▶ if (defined $vals->{key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key"}) 0 0 0
1725 0 $self->{key} = $vals->{key};
1726 }
1727 0 ▶ if (defined $vals->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"columns"}) 0 0 0
1728 0 $self->{columns} = $vals->{columns};
1729 }
1730 }
1731 0 return bless ($self, $classname);
1732 }
1733  
1734 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1735 0 return 'KeySlice';
1736 }
1737  
1738 0 ▶sub read {
Subroutine read: not called CC=8 SCAR=42.8
1739 0 my ($self, $input) = @_;
1740 0 my $xfer = 0;
1741 0 my $fname;
1742 0 my $ftype = 0;
1743 0 my $fid = 0;
1744 0 $xfer += $input->readStructBegin(\$fname);
1745 0 while (1)
1746 {
1747 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1748 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1749 0 last;
1750 }
1751 0 SWITCH: for($fid)
1752 {
1753 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"key"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1754 0 $xfer += $input->readString(\$self->{key});
1755 } else {
1756 0 $xfer += $input->skip($ftype);
1757 }
1758 0 last; };
1759 0 ▶ /^2$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 15) { { my $_size28 = 0; $self->{"columns"} = []; my $_etype31 = 0; $xfer += $input->readListBegin(\$_etype31, \$_size28); for (my $_i32 = 0; $_i32 < $_size28; ++$_i32) { my $elem33 = undef; $elem33 = "Cassandra::ColumnOrSuperColumn"->new; $xfer += $elem33->read($input); push @{$$self{"columns"};}, $elem33; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
1760 {
1761 0 my $_size28 = 0;
1762 0 $self->{columns} = [];
1763 0 my $_etype31 = 0;
1764 0 $xfer += $input->readListBegin(\$_etype31, \$_size28);
1765 0 ▶ for (my $_i32 = 0; $_i32 < $_size28; ++$_i32)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i32 < $_size28) 0 0 0
1766 {
1767 0 my $elem33 = undef;
1768 0 $elem33 = new Cassandra::ColumnOrSuperColumn();
1769 0 $xfer += $elem33->read($input);
1770 0 push(@{$self->{columns}},$elem33);
1771 }
1772 0 $xfer += $input->readListEnd();
1773 }
1774 } else {
1775 0 $xfer += $input->skip($ftype);
1776 }
1777 0 last; };
1778 0 $xfer += $input->skip($ftype);
1779 }
1780 0 $xfer += $input->readFieldEnd();
1781 }
1782 0 $xfer += $input->readStructEnd();
1783 0 return $xfer;
1784 }
1785  
1786 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
1787 0 my ($self, $output) = @_;
1788 0 my $xfer = 0;
1789 0 $xfer += $output->writeStructBegin('KeySlice');
1790 0 ▶ if (defined $self->{key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key"}) 0 0 0
1791 0 $xfer += $output->writeFieldBegin('key', TType::STRING, 1);
1792 0 $xfer += $output->writeString($self->{key});
1793 0 $xfer += $output->writeFieldEnd();
1794 }
1795 0 ▶ if (defined $self->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"columns"}) 0 0 0
1796 0 $xfer += $output->writeFieldBegin('columns', TType::LIST, 2);
1797 {
1798 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{columns}}));
1799 {
1800 0 foreach my $iter34 (@{$self->{columns}})
1801 {
1802 0 $xfer += ${iter34}->write($output);
1803 }
1804 }
1805 0 $xfer += $output->writeListEnd();
1806 }
1807 0 $xfer += $output->writeFieldEnd();
1808 }
1809 0 $xfer += $output->writeFieldStop();
1810 0 $xfer += $output->writeStructEnd();
1811 0 return $xfer;
1812 }
1813  
1814 package Cassandra::KeyCount;
1815 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1816 1 $Cassandra::KeyCount::VERSION = '0.4.0';
1817 }
1818 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1819 1 Cassandra::KeyCount->mk_accessors( qw( key count ) );
1820  
1821 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
1822 0 my $classname = shift;
1823 0 my $self = {};
1824 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1825 0 $self->{key} = undef;
1826 0 $self->{count} = undef;
1827 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1828 0 ▶ if (defined $vals->{key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key"}) 0 0 0
1829 0 $self->{key} = $vals->{key};
1830 }
1831 0 ▶ if (defined $vals->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"count"}) 0 0 0
1832 0 $self->{count} = $vals->{count};
1833 }
1834 }
1835 0 return bless ($self, $classname);
1836 }
1837  
1838 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1839 0 return 'KeyCount';
1840 }
1841  
1842 0 ▶sub read {
Subroutine read: not called CC=7 SCAR=40.3
1843 0 my ($self, $input) = @_;
1844 0 my $xfer = 0;
1845 0 my $fname;
1846 0 my $ftype = 0;
1847 0 my $fid = 0;
1848 0 $xfer += $input->readStructBegin(\$fname);
1849 0 while (1)
1850 {
1851 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1852 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1853 0 last;
1854 }
1855 0 SWITCH: for($fid)
1856 {
1857 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"key"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1858 0 $xfer += $input->readString(\$self->{key});
1859 } else {
1860 0 $xfer += $input->skip($ftype);
1861 }
1862 0 last; };
1863 0 ▶ /^2$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"count"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
1864 0 $xfer += $input->readI32(\$self->{count});
1865 } else {
1866 0 $xfer += $input->skip($ftype);
1867 }
1868 0 last; };
1869 0 $xfer += $input->skip($ftype);
1870 }
1871 0 $xfer += $input->readFieldEnd();
1872 }
1873 0 $xfer += $input->readStructEnd();
1874 0 return $xfer;
1875 }
1876  
1877 0 ▶sub write {
Subroutine write: not called CC=3 SCAR=24.8
1878 0 my ($self, $output) = @_;
1879 0 my $xfer = 0;
1880 0 $xfer += $output->writeStructBegin('KeyCount');
1881 0 ▶ if (defined $self->{key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key"}) 0 0 0
1882 0 $xfer += $output->writeFieldBegin('key', TType::STRING, 1);
1883 0 $xfer += $output->writeString($self->{key});
1884 0 $xfer += $output->writeFieldEnd();
1885 }
1886 0 ▶ if (defined $self->{count}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"count"}) 0 0 0
1887 0 $xfer += $output->writeFieldBegin('count', TType::I32, 2);
1888 0 $xfer += $output->writeI32($self->{count});
1889 0 $xfer += $output->writeFieldEnd();
1890 }
1891 0 $xfer += $output->writeFieldStop();
1892 0 $xfer += $output->writeStructEnd();
1893 0 return $xfer;
1894 }
1895  
1896 package Cassandra::Deletion;
1897 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1898 1 $Cassandra::Deletion::VERSION = '0.4.0';
1899 }
1900 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1901 1 Cassandra::Deletion->mk_accessors( qw( timestamp super_column predicate ) );
1902  
1903 0 ▶sub new {
Subroutine new: not called CC=6 SCAR=37.4
1904 0 my $classname = shift;
1905 0 my $self = {};
1906 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
1907 0 $self->{timestamp} = undef;
1908 0 $self->{super_column} = undef;
1909 0 $self->{predicate} = undef;
1910 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
1911 0 ▶ if (defined $vals->{timestamp}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"timestamp"}) 0 0 0
1912 0 $self->{timestamp} = $vals->{timestamp};
1913 }
1914 0 ▶ if (defined $vals->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"super_column"}) 0 0 0
1915 0 $self->{super_column} = $vals->{super_column};
1916 }
1917 0 ▶ if (defined $vals->{predicate}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"predicate"}) 0 0 0
1918 0 $self->{predicate} = $vals->{predicate};
1919 }
1920 }
1921 0 return bless ($self, $classname);
1922 }
1923  
1924 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
1925 0 return 'Deletion';
1926 }
1927  
1928 0 ▶sub read {
Subroutine read: not called CC=9 SCAR=45.0
1929 0 my ($self, $input) = @_;
1930 0 my $xfer = 0;
1931 0 my $fname;
1932 0 my $ftype = 0;
1933 0 my $fid = 0;
1934 0 $xfer += $input->readStructBegin(\$fname);
1935 0 while (1)
1936 {
1937 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
1938 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
1939 0 last;
1940 }
1941 0 SWITCH: for($fid)
1942 {
1943 0 ▶ /^1$/ && do{ if ($ftype == TType::I64) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 10) { $xfer += $input->readI64(\$self->{"timestamp"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 10) { } 0 0 0
1944 0 $xfer += $input->readI64(\$self->{timestamp});
1945 } else {
1946 0 $xfer += $input->skip($ftype);
1947 }
1948 0 last; };
1949 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"super_column"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
1950 0 $xfer += $input->readString(\$self->{super_column});
1951 } else {
1952 0 $xfer += $input->skip($ftype);
1953 }
1954 0 last; };
1955 0 ▶ /^3$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 12) { $self->{"predicate"} = "Cassandra::SlicePredicate"->new; $xfer += $self->{"predicate"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
1956 0 $self->{predicate} = new Cassandra::SlicePredicate();
1957 0 $xfer += $self->{predicate}->read($input);
1958 } else {
1959 0 $xfer += $input->skip($ftype);
1960 }
1961 0 last; };
1962 0 $xfer += $input->skip($ftype);
1963 }
1964 0 $xfer += $input->readFieldEnd();
1965 }
1966 0 $xfer += $input->readStructEnd();
1967 0 return $xfer;
1968 }
1969  
1970 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
1971 0 my ($self, $output) = @_;
1972 0 my $xfer = 0;
1973 0 $xfer += $output->writeStructBegin('Deletion');
1974 0 ▶ if (defined $self->{timestamp}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"timestamp"}) 0 0 0
1975 0 $xfer += $output->writeFieldBegin('timestamp', TType::I64, 1);
1976 0 $xfer += $output->writeI64($self->{timestamp});
1977 0 $xfer += $output->writeFieldEnd();
1978 }
1979 0 ▶ if (defined $self->{super_column}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"super_column"}) 0 0 0
1980 0 $xfer += $output->writeFieldBegin('super_column', TType::STRING, 2);
1981 0 $xfer += $output->writeString($self->{super_column});
1982 0 $xfer += $output->writeFieldEnd();
1983 }
1984 0 ▶ if (defined $self->{predicate}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"predicate"}) 0 0 0
1985 0 $xfer += $output->writeFieldBegin('predicate', TType::STRUCT, 3);
1986 0 $xfer += $self->{predicate}->write($output);
1987 0 $xfer += $output->writeFieldEnd();
1988 }
1989 0 $xfer += $output->writeFieldStop();
1990 0 $xfer += $output->writeStructEnd();
1991 0 return $xfer;
1992 }
1993  
1994 package Cassandra::Mutation;
1995 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
1996 1 $Cassandra::Mutation::VERSION = '0.4.0';
1997 }
1998 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
1999 1 Cassandra::Mutation->mk_accessors( qw( column_or_supercolumn deletion ) );
2000  
2001 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
2002 0 my $classname = shift;
2003 0 my $self = {};
2004 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
2005 0 $self->{column_or_supercolumn} = undef;
2006 0 $self->{deletion} = undef;
2007 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
2008 0 ▶ if (defined $vals->{column_or_supercolumn}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_or_supercolumn"}) 0 0 0
2009 0 $self->{column_or_supercolumn} = $vals->{column_or_supercolumn};
2010 }
2011 0 ▶ if (defined $vals->{deletion}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"deletion"}) 0 0 0
2012 0 $self->{deletion} = $vals->{deletion};
2013 }
2014 }
2015 0 return bless ($self, $classname);
2016 }
2017  
2018 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
2019 0 return 'Mutation';
2020 }
2021  
2022 0 ▶sub read {
Subroutine read: not called CC=7 SCAR=40.3
2023 0 my ($self, $input) = @_;
2024 0 my $xfer = 0;
2025 0 my $fname;
2026 0 my $ftype = 0;
2027 0 my $fid = 0;
2028 0 $xfer += $input->readStructBegin(\$fname);
2029 0 while (1)
2030 {
2031 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
2032 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
2033 0 last;
2034 }
2035 0 SWITCH: for($fid)
2036 {
2037 0 ▶ /^1$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 12) { $self->{"column_or_supercolumn"} = "Cassandra::ColumnOrSuperColumn"->new; $xfer += $self->{"column_or_supercolumn"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
2038 0 $self->{column_or_supercolumn} = new Cassandra::ColumnOrSuperColumn();
2039 0 $xfer += $self->{column_or_supercolumn}->read($input);
2040 } else {
2041 0 $xfer += $input->skip($ftype);
2042 }
2043 0 last; };
2044 0 ▶ /^2$/ && do{ if ($ftype == TType::STRUCT) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 12) { $self->{"deletion"} = "Cassandra::Deletion"->new; $xfer += $self->{"deletion"}->read($input); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 12) { } 0 0 0
2045 0 $self->{deletion} = new Cassandra::Deletion();
2046 0 $xfer += $self->{deletion}->read($input);
2047 } else {
2048 0 $xfer += $input->skip($ftype);
2049 }
2050 0 last; };
2051 0 $xfer += $input->skip($ftype);
2052 }
2053 0 $xfer += $input->readFieldEnd();
2054 }
2055 0 $xfer += $input->readStructEnd();
2056 0 return $xfer;
2057 }
2058  
2059 0 ▶sub write {
Subroutine write: not called CC=3 SCAR=24.8
2060 0 my ($self, $output) = @_;
2061 0 my $xfer = 0;
2062 0 $xfer += $output->writeStructBegin('Mutation');
2063 0 ▶ if (defined $self->{column_or_supercolumn}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_or_supercolumn"}) 0 0 0
2064 0 $xfer += $output->writeFieldBegin('column_or_supercolumn', TType::STRUCT, 1);
2065 0 $xfer += $self->{column_or_supercolumn}->write($output);
2066 0 $xfer += $output->writeFieldEnd();
2067 }
2068 0 ▶ if (defined $self->{deletion}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"deletion"}) 0 0 0
2069 0 $xfer += $output->writeFieldBegin('deletion', TType::STRUCT, 2);
2070 0 $xfer += $self->{deletion}->write($output);
2071 0 $xfer += $output->writeFieldEnd();
2072 }
2073 0 $xfer += $output->writeFieldStop();
2074 0 $xfer += $output->writeStructEnd();
2075 0 return $xfer;
2076 }
2077  
2078 package Cassandra::TokenRange;
2079 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
2080 1 $Cassandra::TokenRange::VERSION = '0.4.0';
2081 }
2082 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
2083 1 Cassandra::TokenRange->mk_accessors( qw( start_token end_token endpoints ) );
2084  
2085 0 ▶sub new {
Subroutine new: not called CC=6 SCAR=37.4
2086 0 my $classname = shift;
2087 0 my $self = {};
2088 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
2089 0 $self->{start_token} = undef;
2090 0 $self->{end_token} = undef;
2091 0 $self->{endpoints} = undef;
2092 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
2093 0 ▶ if (defined $vals->{start_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"start_token"}) 0 0 0
2094 0 $self->{start_token} = $vals->{start_token};
2095 }
2096 0 ▶ if (defined $vals->{end_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"end_token"}) 0 0 0
2097 0 $self->{end_token} = $vals->{end_token};
2098 }
2099 0 ▶ if (defined $vals->{endpoints}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"endpoints"}) 0 0 0
2100 0 $self->{endpoints} = $vals->{endpoints};
2101 }
2102 }
2103 0 return bless ($self, $classname);
2104 }
2105  
2106 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
2107 0 return 'TokenRange';
2108 }
2109  
2110 0 ▶sub read {
Subroutine read: not called CC=10 SCAR=47.0
2111 0 my ($self, $input) = @_;
2112 0 my $xfer = 0;
2113 0 my $fname;
2114 0 my $ftype = 0;
2115 0 my $fid = 0;
2116 0 $xfer += $input->readStructBegin(\$fname);
2117 0 while (1)
2118 {
2119 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
2120 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
2121 0 last;
2122 }
2123 0 SWITCH: for($fid)
2124 {
2125 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"start_token"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2126 0 $xfer += $input->readString(\$self->{start_token});
2127 } else {
2128 0 $xfer += $input->skip($ftype);
2129 }
2130 0 last; };
2131 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"end_token"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2132 0 $xfer += $input->readString(\$self->{end_token});
2133 } else {
2134 0 $xfer += $input->skip($ftype);
2135 }
2136 0 last; };
2137 0 ▶ /^3$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 15) { { my $_size35 = 0; $self->{"endpoints"} = []; my $_etype38 = 0; $xfer += $input->readListBegin(\$_etype38, \$_size35); for (my $_i39 = 0; $_i39 < $_size35; ++$_i39) { my $elem40 = undef; $xfer += $input->readString(\$elem40); push @{$$self{"endpoints"};}, $elem40; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
2138 {
2139 0 my $_size35 = 0;
2140 0 $self->{endpoints} = [];
2141 0 my $_etype38 = 0;
2142 0 $xfer += $input->readListBegin(\$_etype38, \$_size35);
2143 0 ▶ for (my $_i39 = 0; $_i39 < $_size35; ++$_i39)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i39 < $_size35) 0 0 0
2144 {
2145 0 my $elem40 = undef;
2146 0 $xfer += $input->readString(\$elem40);
2147 0 push(@{$self->{endpoints}},$elem40);
2148 }
2149 0 $xfer += $input->readListEnd();
2150 }
2151 } else {
2152 0 $xfer += $input->skip($ftype);
2153 }
2154 0 last; };
2155 0 $xfer += $input->skip($ftype);
2156 }
2157 0 $xfer += $input->readFieldEnd();
2158 }
2159 0 $xfer += $input->readStructEnd();
2160 0 return $xfer;
2161 }
2162  
2163 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
2164 0 my ($self, $output) = @_;
2165 0 my $xfer = 0;
2166 0 $xfer += $output->writeStructBegin('TokenRange');
2167 0 ▶ if (defined $self->{start_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"start_token"}) 0 0 0
2168 0 $xfer += $output->writeFieldBegin('start_token', TType::STRING, 1);
2169 0 $xfer += $output->writeString($self->{start_token});
2170 0 $xfer += $output->writeFieldEnd();
2171 }
2172 0 ▶ if (defined $self->{end_token}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"end_token"}) 0 0 0
2173 0 $xfer += $output->writeFieldBegin('end_token', TType::STRING, 2);
2174 0 $xfer += $output->writeString($self->{end_token});
2175 0 $xfer += $output->writeFieldEnd();
2176 }
2177 0 ▶ if (defined $self->{endpoints}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"endpoints"}) 0 0 0
2178 0 $xfer += $output->writeFieldBegin('endpoints', TType::LIST, 3);
2179 {
2180 0 $xfer += $output->writeListBegin(TType::STRING, scalar(@{$self->{endpoints}}));
2181 {
2182 0 foreach my $iter41 (@{$self->{endpoints}})
2183 {
2184 0 $xfer += $output->writeString($iter41);
2185 }
2186 }
2187 0 $xfer += $output->writeListEnd();
2188 }
2189 0 $xfer += $output->writeFieldEnd();
2190 }
2191 0 $xfer += $output->writeFieldStop();
2192 0 $xfer += $output->writeStructEnd();
2193 0 return $xfer;
2194 }
2195  
2196 package Cassandra::AuthenticationRequest;
2197 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
2198 1 $Cassandra::AuthenticationRequest::VERSION = '0.4.0';
2199 }
2200 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
2201 1 Cassandra::AuthenticationRequest->mk_accessors( qw( credentials ) );
2202  
2203 0 ▶sub new {
Subroutine new: not called CC=4 SCAR=30.0
2204 0 my $classname = shift;
2205 0 my $self = {};
2206 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
2207 0 $self->{credentials} = undef;
2208 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
2209 0 ▶ if (defined $vals->{credentials}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"credentials"}) 0 0 0
2210 0 $self->{credentials} = $vals->{credentials};
2211 }
2212 }
2213 0 return bless ($self, $classname);
2214 }
2215  
2216 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
2217 0 return 'AuthenticationRequest';
2218 }
2219  
2220 0 ▶sub read {
Subroutine read: not called CC=6 SCAR=37.4
2221 0 my ($self, $input) = @_;
2222 0 my $xfer = 0;
2223 0 my $fname;
2224 0 my $ftype = 0;
2225 0 my $fid = 0;
2226 0 $xfer += $input->readStructBegin(\$fname);
2227 0 while (1)
2228 {
2229 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
2230 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
2231 0 last;
2232 }
2233 0 SWITCH: for($fid)
2234 {
2235 0 ▶ /^1$/ && do{ if ($ftype == TType::MAP) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 13) { { my $_size42 = 0; $self->{"credentials"} = {}; my $_ktype43 = 0; my $_vtype44 = 0; $xfer += $input->readMapBegin(\$_ktype43, \$_vtype44, \$_size42); for (my $_i46 = 0; $_i46 < $_size42; ++$_i46) { my $key47 = ""; my $val48 = ""; $xfer += $input->readString(\$key47); $xfer += $input->readString(\$val48); $self->{"credentials"}{$key47} = $val48; } ; $xfer += $input->readMapEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 13) { } 0 0 0
2236 {
2237 0 my $_size42 = 0;
2238 0 $self->{credentials} = {};
2239 0 my $_ktype43 = 0;
2240 0 my $_vtype44 = 0;
2241 0 $xfer += $input->readMapBegin(\$_ktype43, \$_vtype44, \$_size42);
2242 0 ▶ for (my $_i46 = 0; $_i46 < $_size42; ++$_i46)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i46 < $_size42) 0 0 0
2243 {
2244 0 my $key47 = '';
2245 0 my $val48 = '';
2246 0 $xfer += $input->readString(\$key47);
2247 0 $xfer += $input->readString(\$val48);
2248 0 $self->{credentials}->{$key47} = $val48;
2249 }
2250 0 $xfer += $input->readMapEnd();
2251 }
2252 } else {
2253 0 $xfer += $input->skip($ftype);
2254 }
2255 0 last; };
2256 0 $xfer += $input->skip($ftype);
2257 }
2258 0 $xfer += $input->readFieldEnd();
2259 }
2260 0 $xfer += $input->readStructEnd();
2261 0 return $xfer;
2262 }
2263  
2264 0 ▶sub write {
Subroutine write: not called CC=3 SCAR=24.8
2265 0 my ($self, $output) = @_;
2266 0 my $xfer = 0;
2267 0 $xfer += $output->writeStructBegin('AuthenticationRequest');
2268 0 ▶ if (defined $self->{credentials}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"credentials"}) 0 0 0
2269 0 $xfer += $output->writeFieldBegin('credentials', TType::MAP, 1);
2270 {
2271 0 $xfer += $output->writeMapBegin(TType::STRING, TType::STRING, scalar(keys %{$self->{credentials}}));
2272 {
2273 0 ▶ while( my ($kiter49,$viter50) = each %{$self->{credentials}})
Branch: 1 branch
BranchTrueFalseTotal
if (() = each %{$$self{"credentials"};}) 0 0 0
2274 {
2275 0 $xfer += $output->writeString($kiter49);
2276 0 $xfer += $output->writeString($viter50);
2277 }
2278 }
2279 0 $xfer += $output->writeMapEnd();
2280 }
2281 0 $xfer += $output->writeFieldEnd();
2282 }
2283 0 $xfer += $output->writeFieldStop();
2284 0 $xfer += $output->writeStructEnd();
2285 0 return $xfer;
2286 }
2287  
2288 package Cassandra::ColumnDef;
2289 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
2290 1 $Cassandra::ColumnDef::VERSION = '0.4.0';
2291 }
2292 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
2293 1 Cassandra::ColumnDef->mk_accessors( qw( name validation_class index_type index_name ) );
2294  
2295 0 ▶sub new {
Subroutine new: not called CC=7 SCAR=40.3
2296 0 my $classname = shift;
2297 0 my $self = {};
2298 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
2299 0 $self->{name} = undef;
2300 0 $self->{validation_class} = undef;
2301 0 $self->{index_type} = undef;
2302 0 $self->{index_name} = undef;
2303 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
2304 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
2305 0 $self->{name} = $vals->{name};
2306 }
2307 0 ▶ if (defined $vals->{validation_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"validation_class"}) 0 0 0
2308 0 $self->{validation_class} = $vals->{validation_class};
2309 }
2310 0 ▶ if (defined $vals->{index_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"index_type"}) 0 0 0
2311 0 $self->{index_type} = $vals->{index_type};
2312 }
2313 0 ▶ if (defined $vals->{index_name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"index_name"}) 0 0 0
2314 0 $self->{index_name} = $vals->{index_name};
2315 }
2316 }
2317 0 return bless ($self, $classname);
2318 }
2319  
2320 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
2321 0 return 'ColumnDef';
2322 }
2323  
2324 0 ▶sub read {
Subroutine read: not called CC=11 SCAR=48.8
2325 0 my ($self, $input) = @_;
2326 0 my $xfer = 0;
2327 0 my $fname;
2328 0 my $ftype = 0;
2329 0 my $fid = 0;
2330 0 $xfer += $input->readStructBegin(\$fname);
2331 0 while (1)
2332 {
2333 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
2334 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
2335 0 last;
2336 }
2337 0 SWITCH: for($fid)
2338 {
2339 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2340 0 $xfer += $input->readString(\$self->{name});
2341 } else {
2342 0 $xfer += $input->skip($ftype);
2343 }
2344 0 last; };
2345 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"validation_class"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2346 0 $xfer += $input->readString(\$self->{validation_class});
2347 } else {
2348 0 $xfer += $input->skip($ftype);
2349 }
2350 0 last; };
2351 0 ▶ /^3$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"index_type"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2352 0 $xfer += $input->readI32(\$self->{index_type});
2353 } else {
2354 0 $xfer += $input->skip($ftype);
2355 }
2356 0 last; };
2357 0 ▶ /^4$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"index_name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2358 0 $xfer += $input->readString(\$self->{index_name});
2359 } else {
2360 0 $xfer += $input->skip($ftype);
2361 }
2362 0 last; };
2363 0 $xfer += $input->skip($ftype);
2364 }
2365 0 $xfer += $input->readFieldEnd();
2366 }
2367 0 $xfer += $input->readStructEnd();
2368 0 return $xfer;
2369 }
2370  
2371 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
2372 0 my ($self, $output) = @_;
2373 0 my $xfer = 0;
2374 0 $xfer += $output->writeStructBegin('ColumnDef');
2375 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
2376 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
2377 0 $xfer += $output->writeString($self->{name});
2378 0 $xfer += $output->writeFieldEnd();
2379 }
2380 0 ▶ if (defined $self->{validation_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"validation_class"}) 0 0 0
2381 0 $xfer += $output->writeFieldBegin('validation_class', TType::STRING, 2);
2382 0 $xfer += $output->writeString($self->{validation_class});
2383 0 $xfer += $output->writeFieldEnd();
2384 }
2385 0 ▶ if (defined $self->{index_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"index_type"}) 0 0 0
2386 0 $xfer += $output->writeFieldBegin('index_type', TType::I32, 3);
2387 0 $xfer += $output->writeI32($self->{index_type});
2388 0 $xfer += $output->writeFieldEnd();
2389 }
2390 0 ▶ if (defined $self->{index_name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"index_name"}) 0 0 0
2391 0 $xfer += $output->writeFieldBegin('index_name', TType::STRING, 4);
2392 0 $xfer += $output->writeString($self->{index_name});
2393 0 $xfer += $output->writeFieldEnd();
2394 }
2395 0 $xfer += $output->writeFieldStop();
2396 0 $xfer += $output->writeStructEnd();
2397 0 return $xfer;
2398 }
2399  
2400 package Cassandra::CfDef;
2401 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
2402 1 $Cassandra::CfDef::VERSION = '0.4.0';
2403 }
2404 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
2405 1 Cassandra::CfDef->mk_accessors( qw( keyspace name column_type comparator_type subcomparator_type comment row_cache_size key_cache_size read_repair_chance column_metadata gc_grace_seconds default_validation_class id min_compaction_threshold max_compaction_threshold row_cache_save_period_in_seconds key_cache_save_period_in_seconds memtable_flush_after_mins memtable_throughput_in_mb memtable_operations_in_millions replicate_on_write merge_shards_chance key_validation_class row_cache_provider key_alias ) );
2406  
2407 0 ▶sub new {
Subroutine new: not called CC=28 SCAR=67.0
2408 0 my $classname = shift;
2409 0 my $self = {};
2410 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
2411 0 $self->{keyspace} = undef;
2412 0 $self->{name} = undef;
2413 0 $self->{column_type} = "Standard";
2414 0 $self->{comparator_type} = "BytesType";
2415 0 $self->{subcomparator_type} = undef;
2416 0 $self->{comment} = undef;
2417 0 $self->{row_cache_size} = 0;
2418 0 $self->{key_cache_size} = 200000;
2419 0 $self->{read_repair_chance} = 1;
2420 0 $self->{column_metadata} = undef;
2421 0 $self->{gc_grace_seconds} = undef;
2422 0 $self->{default_validation_class} = undef;
2423 0 $self->{id} = undef;
2424 0 $self->{min_compaction_threshold} = undef;
2425 0 $self->{max_compaction_threshold} = undef;
2426 0 $self->{row_cache_save_period_in_seconds} = undef;
2427 0 $self->{key_cache_save_period_in_seconds} = undef;
2428 0 $self->{memtable_flush_after_mins} = undef;
2429 0 $self->{memtable_throughput_in_mb} = undef;
2430 0 $self->{memtable_operations_in_millions} = undef;
2431 0 $self->{replicate_on_write} = undef;
2432 0 $self->{merge_shards_chance} = undef;
2433 0 $self->{key_validation_class} = undef;
2434 0 $self->{row_cache_provider} = "org.apache.cassandra.cache.ConcurrentLinkedHashCacheProvider";
2435 0 $self->{key_alias} = undef;
2436 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
2437 0 ▶ if (defined $vals->{keyspace}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"keyspace"}) 0 0 0
2438 0 $self->{keyspace} = $vals->{keyspace};
2439 }
2440 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
2441 0 $self->{name} = $vals->{name};
2442 }
2443 0 ▶ if (defined $vals->{column_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_type"}) 0 0 0
2444 0 $self->{column_type} = $vals->{column_type};
2445 }
2446 0 ▶ if (defined $vals->{comparator_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"comparator_type"}) 0 0 0
2447 0 $self->{comparator_type} = $vals->{comparator_type};
2448 }
2449 0 ▶ if (defined $vals->{subcomparator_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"subcomparator_type"}) 0 0 0
2450 0 $self->{subcomparator_type} = $vals->{subcomparator_type};
2451 }
2452 0 ▶ if (defined $vals->{comment}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"comment"}) 0 0 0
2453 0 $self->{comment} = $vals->{comment};
2454 }
2455 0 ▶ if (defined $vals->{row_cache_size}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"row_cache_size"}) 0 0 0
2456 0 $self->{row_cache_size} = $vals->{row_cache_size};
2457 }
2458 0 ▶ if (defined $vals->{key_cache_size}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key_cache_size"}) 0 0 0
2459 0 $self->{key_cache_size} = $vals->{key_cache_size};
2460 }
2461 0 ▶ if (defined $vals->{read_repair_chance}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"read_repair_chance"}) 0 0 0
2462 0 $self->{read_repair_chance} = $vals->{read_repair_chance};
2463 }
2464 0 ▶ if (defined $vals->{column_metadata}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"column_metadata"}) 0 0 0
2465 0 $self->{column_metadata} = $vals->{column_metadata};
2466 }
2467 0 ▶ if (defined $vals->{gc_grace_seconds}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"gc_grace_seconds"}) 0 0 0
2468 0 $self->{gc_grace_seconds} = $vals->{gc_grace_seconds};
2469 }
2470 0 ▶ if (defined $vals->{default_validation_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"default_validation_class"}) 0 0 0
2471 0 $self->{default_validation_class} = $vals->{default_validation_class};
2472 }
2473 0 ▶ if (defined $vals->{id}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"id"}) 0 0 0
2474 0 $self->{id} = $vals->{id};
2475 }
2476 0 ▶ if (defined $vals->{min_compaction_threshold}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"min_compaction_threshold"}) 0 0 0
2477 0 $self->{min_compaction_threshold} = $vals->{min_compaction_threshold};
2478 }
2479 0 ▶ if (defined $vals->{max_compaction_threshold}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"max_compaction_threshold"}) 0 0 0
2480 0 $self->{max_compaction_threshold} = $vals->{max_compaction_threshold};
2481 }
2482 0 ▶ if (defined $vals->{row_cache_save_period_in_seconds}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"row_cache_save_period_in_seconds"}) 0 0 0
2483 0 $self->{row_cache_save_period_in_seconds} = $vals->{row_cache_save_period_in_seconds};
2484 }
2485 0 ▶ if (defined $vals->{key_cache_save_period_in_seconds}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key_cache_save_period_in_seconds"}) 0 0 0
2486 0 $self->{key_cache_save_period_in_seconds} = $vals->{key_cache_save_period_in_seconds};
2487 }
2488 0 ▶ if (defined $vals->{memtable_flush_after_mins}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"memtable_flush_after_mins"}) 0 0 0
2489 0 $self->{memtable_flush_after_mins} = $vals->{memtable_flush_after_mins};
2490 }
2491 0 ▶ if (defined $vals->{memtable_throughput_in_mb}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"memtable_throughput_in_mb"}) 0 0 0
2492 0 $self->{memtable_throughput_in_mb} = $vals->{memtable_throughput_in_mb};
2493 }
2494 0 ▶ if (defined $vals->{memtable_operations_in_millions}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"memtable_operations_in_millions"}) 0 0 0
2495 0 $self->{memtable_operations_in_millions} = $vals->{memtable_operations_in_millions};
2496 }
2497 0 ▶ if (defined $vals->{replicate_on_write}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"replicate_on_write"}) 0 0 0
2498 0 $self->{replicate_on_write} = $vals->{replicate_on_write};
2499 }
2500 0 ▶ if (defined $vals->{merge_shards_chance}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"merge_shards_chance"}) 0 0 0
2501 0 $self->{merge_shards_chance} = $vals->{merge_shards_chance};
2502 }
2503 0 ▶ if (defined $vals->{key_validation_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key_validation_class"}) 0 0 0
2504 0 $self->{key_validation_class} = $vals->{key_validation_class};
2505 }
2506 0 ▶ if (defined $vals->{row_cache_provider}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"row_cache_provider"}) 0 0 0
2507 0 $self->{row_cache_provider} = $vals->{row_cache_provider};
2508 }
2509 0 ▶ if (defined $vals->{key_alias}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key_alias"}) 0 0 0
2510 0 $self->{key_alias} = $vals->{key_alias};
2511 }
2512 }
2513 0 return bless ($self, $classname);
2514 }
2515  
2516 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
2517 0 return 'CfDef';
2518 }
2519  
2520 0 ▶sub read {
Subroutine read: not called CC=54 SCAR=80.0
2521 0 my ($self, $input) = @_;
2522 0 my $xfer = 0;
2523 0 my $fname;
2524 0 my $ftype = 0;
2525 0 my $fid = 0;
2526 0 $xfer += $input->readStructBegin(\$fname);
2527 0 while (1)
2528 {
2529 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
2530 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
2531 0 last;
2532 }
2533 0 SWITCH: for($fid)
2534 {
2535 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"keyspace"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2536 0 $xfer += $input->readString(\$self->{keyspace});
2537 } else {
2538 0 $xfer += $input->skip($ftype);
2539 }
2540 0 last; };
2541 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2542 0 $xfer += $input->readString(\$self->{name});
2543 } else {
2544 0 $xfer += $input->skip($ftype);
2545 }
2546 0 last; };
2547 0 ▶ /^3$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"column_type"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2548 0 $xfer += $input->readString(\$self->{column_type});
2549 } else {
2550 0 $xfer += $input->skip($ftype);
2551 }
2552 0 last; };
2553 0 ▶ /^5$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^5$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"comparator_type"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2554 0 $xfer += $input->readString(\$self->{comparator_type});
2555 } else {
2556 0 $xfer += $input->skip($ftype);
2557 }
2558 0 last; };
2559 0 ▶ /^6$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^6$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"subcomparator_type"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2560 0 $xfer += $input->readString(\$self->{subcomparator_type});
2561 } else {
2562 0 $xfer += $input->skip($ftype);
2563 }
2564 0 last; };
2565 0 ▶ /^8$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^8$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"comment"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2566 0 $xfer += $input->readString(\$self->{comment});
2567 } else {
2568 0 $xfer += $input->skip($ftype);
2569 }
2570 0 last; };
2571 0 ▶ /^9$/ && do{ if ($ftype == TType::DOUBLE) {
Branch: 2 branches
BranchTrueFalseTotal
/^9$/ and do { if ($ftype == 4) { $xfer += $input->readDouble(\$self->{"row_cache_size"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 4) { } 0 0 0
2572 0 $xfer += $input->readDouble(\$self->{row_cache_size});
2573 } else {
2574 0 $xfer += $input->skip($ftype);
2575 }
2576 0 last; };
2577 0 ▶ /^11$/ && do{ if ($ftype == TType::DOUBLE) {
Branch: 2 branches
BranchTrueFalseTotal
/^11$/ and do { if ($ftype == 4) { $xfer += $input->readDouble(\$self->{"key_cache_size"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 4) { } 0 0 0
2578 0 $xfer += $input->readDouble(\$self->{key_cache_size});
2579 } else {
2580 0 $xfer += $input->skip($ftype);
2581 }
2582 0 last; };
2583 0 ▶ /^12$/ && do{ if ($ftype == TType::DOUBLE) {
Branch: 2 branches
BranchTrueFalseTotal
/^12$/ and do { if ($ftype == 4) { $xfer += $input->readDouble(\$self->{"read_repair_chance"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 4) { } 0 0 0
2584 0 $xfer += $input->readDouble(\$self->{read_repair_chance});
2585 } else {
2586 0 $xfer += $input->skip($ftype);
2587 }
2588 0 last; };
2589 0 ▶ /^13$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^13$/ and do { if ($ftype == 15) { { my $_size51 = 0; $self->{"column_metadata"} = []; my $_etype54 = 0; $xfer += $input->readListBegin(\$_etype54, \$_size51); for (my $_i55 = 0; $_i55 < $_size51; ++$_i55) { my $elem56 = undef; $elem56 = "Cassandra::ColumnDef"->new; $xfer += $elem56->read($input); push @{$$self{"column_metadata"};}, $elem56; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
2590 {
2591 0 my $_size51 = 0;
2592 0 $self->{column_metadata} = [];
2593 0 my $_etype54 = 0;
2594 0 $xfer += $input->readListBegin(\$_etype54, \$_size51);
2595 0 ▶ for (my $_i55 = 0; $_i55 < $_size51; ++$_i55)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i55 < $_size51) 0 0 0
2596 {
2597 0 my $elem56 = undef;
2598 0 $elem56 = new Cassandra::ColumnDef();
2599 0 $xfer += $elem56->read($input);
2600 0 push(@{$self->{column_metadata}},$elem56);
2601 }
2602 0 $xfer += $input->readListEnd();
2603 }
2604 } else {
2605 0 $xfer += $input->skip($ftype);
2606 }
2607 0 last; };
2608 0 ▶ /^14$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^14$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"gc_grace_seconds"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2609 0 $xfer += $input->readI32(\$self->{gc_grace_seconds});
2610 } else {
2611 0 $xfer += $input->skip($ftype);
2612 }
2613 0 last; };
2614 0 ▶ /^15$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^15$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"default_validation_class"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2615 0 $xfer += $input->readString(\$self->{default_validation_class});
2616 } else {
2617 0 $xfer += $input->skip($ftype);
2618 }
2619 0 last; };
2620 0 ▶ /^16$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^16$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"id"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2621 0 $xfer += $input->readI32(\$self->{id});
2622 } else {
2623 0 $xfer += $input->skip($ftype);
2624 }
2625 0 last; };
2626 0 ▶ /^17$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^17$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"min_compaction_threshold"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2627 0 $xfer += $input->readI32(\$self->{min_compaction_threshold});
2628 } else {
2629 0 $xfer += $input->skip($ftype);
2630 }
2631 0 last; };
2632 0 ▶ /^18$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^18$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"max_compaction_threshold"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2633 0 $xfer += $input->readI32(\$self->{max_compaction_threshold});
2634 } else {
2635 0 $xfer += $input->skip($ftype);
2636 }
2637 0 last; };
2638 0 ▶ /^19$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^19$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"row_cache_save_period_in_seconds"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2639 0 $xfer += $input->readI32(\$self->{row_cache_save_period_in_seconds});
2640 } else {
2641 0 $xfer += $input->skip($ftype);
2642 }
2643 0 last; };
2644 0 ▶ /^20$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^20$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"key_cache_save_period_in_seconds"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2645 0 $xfer += $input->readI32(\$self->{key_cache_save_period_in_seconds});
2646 } else {
2647 0 $xfer += $input->skip($ftype);
2648 }
2649 0 last; };
2650 0 ▶ /^21$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^21$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"memtable_flush_after_mins"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2651 0 $xfer += $input->readI32(\$self->{memtable_flush_after_mins});
2652 } else {
2653 0 $xfer += $input->skip($ftype);
2654 }
2655 0 last; };
2656 0 ▶ /^22$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^22$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"memtable_throughput_in_mb"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2657 0 $xfer += $input->readI32(\$self->{memtable_throughput_in_mb});
2658 } else {
2659 0 $xfer += $input->skip($ftype);
2660 }
2661 0 last; };
2662 0 ▶ /^23$/ && do{ if ($ftype == TType::DOUBLE) {
Branch: 2 branches
BranchTrueFalseTotal
/^23$/ and do { if ($ftype == 4) { $xfer += $input->readDouble(\$self->{"memtable_operations_in_millions"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 4) { } 0 0 0
2663 0 $xfer += $input->readDouble(\$self->{memtable_operations_in_millions});
2664 } else {
2665 0 $xfer += $input->skip($ftype);
2666 }
2667 0 last; };
2668 0 ▶ /^24$/ && do{ if ($ftype == TType::BOOL) {
Branch: 2 branches
BranchTrueFalseTotal
/^24$/ and do { if ($ftype == 2) { $xfer += $input->readBool(\$self->{"replicate_on_write"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 2) { } 0 0 0
2669 0 $xfer += $input->readBool(\$self->{replicate_on_write});
2670 } else {
2671 0 $xfer += $input->skip($ftype);
2672 }
2673 0 last; };
2674 0 ▶ /^25$/ && do{ if ($ftype == TType::DOUBLE) {
Branch: 2 branches
BranchTrueFalseTotal
/^25$/ and do { if ($ftype == 4) { $xfer += $input->readDouble(\$self->{"merge_shards_chance"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 4) { } 0 0 0
2675 0 $xfer += $input->readDouble(\$self->{merge_shards_chance});
2676 } else {
2677 0 $xfer += $input->skip($ftype);
2678 }
2679 0 last; };
2680 0 ▶ /^26$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^26$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"key_validation_class"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2681 0 $xfer += $input->readString(\$self->{key_validation_class});
2682 } else {
2683 0 $xfer += $input->skip($ftype);
2684 }
2685 0 last; };
2686 0 ▶ /^27$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^27$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"row_cache_provider"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2687 0 $xfer += $input->readString(\$self->{row_cache_provider});
2688 } else {
2689 0 $xfer += $input->skip($ftype);
2690 }
2691 0 last; };
2692 0 ▶ /^28$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^28$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"key_alias"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2693 0 $xfer += $input->readString(\$self->{key_alias});
2694 } else {
2695 0 $xfer += $input->skip($ftype);
2696 }
2697 0 last; };
2698 0 $xfer += $input->skip($ftype);
2699 }
2700 0 $xfer += $input->readFieldEnd();
2701 }
2702 0 $xfer += $input->readStructEnd();
2703 0 return $xfer;
2704 }
2705  
2706 0 ▶sub write {
Subroutine write: not called CC=27 SCAR=66.3
2707 0 my ($self, $output) = @_;
2708 0 my $xfer = 0;
2709 0 $xfer += $output->writeStructBegin('CfDef');
2710 0 ▶ if (defined $self->{keyspace}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"keyspace"}) 0 0 0
2711 0 $xfer += $output->writeFieldBegin('keyspace', TType::STRING, 1);
2712 0 $xfer += $output->writeString($self->{keyspace});
2713 0 $xfer += $output->writeFieldEnd();
2714 }
2715 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
2716 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 2);
2717 0 $xfer += $output->writeString($self->{name});
2718 0 $xfer += $output->writeFieldEnd();
2719 }
2720 0 ▶ if (defined $self->{column_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_type"}) 0 0 0
2721 0 $xfer += $output->writeFieldBegin('column_type', TType::STRING, 3);
2722 0 $xfer += $output->writeString($self->{column_type});
2723 0 $xfer += $output->writeFieldEnd();
2724 }
2725 0 ▶ if (defined $self->{comparator_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"comparator_type"}) 0 0 0
2726 0 $xfer += $output->writeFieldBegin('comparator_type', TType::STRING, 5);
2727 0 $xfer += $output->writeString($self->{comparator_type});
2728 0 $xfer += $output->writeFieldEnd();
2729 }
2730 0 ▶ if (defined $self->{subcomparator_type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"subcomparator_type"}) 0 0 0
2731 0 $xfer += $output->writeFieldBegin('subcomparator_type', TType::STRING, 6);
2732 0 $xfer += $output->writeString($self->{subcomparator_type});
2733 0 $xfer += $output->writeFieldEnd();
2734 }
2735 0 ▶ if (defined $self->{comment}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"comment"}) 0 0 0
2736 0 $xfer += $output->writeFieldBegin('comment', TType::STRING, 8);
2737 0 $xfer += $output->writeString($self->{comment});
2738 0 $xfer += $output->writeFieldEnd();
2739 }
2740 0 ▶ if (defined $self->{row_cache_size}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"row_cache_size"}) 0 0 0
2741 0 $xfer += $output->writeFieldBegin('row_cache_size', TType::DOUBLE, 9);
2742 0 $xfer += $output->writeDouble($self->{row_cache_size});
2743 0 $xfer += $output->writeFieldEnd();
2744 }
2745 0 ▶ if (defined $self->{key_cache_size}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key_cache_size"}) 0 0 0
2746 0 $xfer += $output->writeFieldBegin('key_cache_size', TType::DOUBLE, 11);
2747 0 $xfer += $output->writeDouble($self->{key_cache_size});
2748 0 $xfer += $output->writeFieldEnd();
2749 }
2750 0 ▶ if (defined $self->{read_repair_chance}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"read_repair_chance"}) 0 0 0
2751 0 $xfer += $output->writeFieldBegin('read_repair_chance', TType::DOUBLE, 12);
2752 0 $xfer += $output->writeDouble($self->{read_repair_chance});
2753 0 $xfer += $output->writeFieldEnd();
2754 }
2755 0 ▶ if (defined $self->{column_metadata}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"column_metadata"}) 0 0 0
2756 0 $xfer += $output->writeFieldBegin('column_metadata', TType::LIST, 13);
2757 {
2758 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{column_metadata}}));
2759 {
2760 0 foreach my $iter57 (@{$self->{column_metadata}})
2761 {
2762 0 $xfer += ${iter57}->write($output);
2763 }
2764 }
2765 0 $xfer += $output->writeListEnd();
2766 }
2767 0 $xfer += $output->writeFieldEnd();
2768 }
2769 0 ▶ if (defined $self->{gc_grace_seconds}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"gc_grace_seconds"}) 0 0 0
2770 0 $xfer += $output->writeFieldBegin('gc_grace_seconds', TType::I32, 14);
2771 0 $xfer += $output->writeI32($self->{gc_grace_seconds});
2772 0 $xfer += $output->writeFieldEnd();
2773 }
2774 0 ▶ if (defined $self->{default_validation_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"default_validation_class"}) 0 0 0
2775 0 $xfer += $output->writeFieldBegin('default_validation_class', TType::STRING, 15);
2776 0 $xfer += $output->writeString($self->{default_validation_class});
2777 0 $xfer += $output->writeFieldEnd();
2778 }
2779 0 ▶ if (defined $self->{id}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"id"}) 0 0 0
2780 0 $xfer += $output->writeFieldBegin('id', TType::I32, 16);
2781 0 $xfer += $output->writeI32($self->{id});
2782 0 $xfer += $output->writeFieldEnd();
2783 }
2784 0 ▶ if (defined $self->{min_compaction_threshold}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"min_compaction_threshold"}) 0 0 0
2785 0 $xfer += $output->writeFieldBegin('min_compaction_threshold', TType::I32, 17);
2786 0 $xfer += $output->writeI32($self->{min_compaction_threshold});
2787 0 $xfer += $output->writeFieldEnd();
2788 }
2789 0 ▶ if (defined $self->{max_compaction_threshold}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"max_compaction_threshold"}) 0 0 0
2790 0 $xfer += $output->writeFieldBegin('max_compaction_threshold', TType::I32, 18);
2791 0 $xfer += $output->writeI32($self->{max_compaction_threshold});
2792 0 $xfer += $output->writeFieldEnd();
2793 }
2794 0 ▶ if (defined $self->{row_cache_save_period_in_seconds}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"row_cache_save_period_in_seconds"}) 0 0 0
2795 0 $xfer += $output->writeFieldBegin('row_cache_save_period_in_seconds', TType::I32, 19);
2796 0 $xfer += $output->writeI32($self->{row_cache_save_period_in_seconds});
2797 0 $xfer += $output->writeFieldEnd();
2798 }
2799 0 ▶ if (defined $self->{key_cache_save_period_in_seconds}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key_cache_save_period_in_seconds"}) 0 0 0
2800 0 $xfer += $output->writeFieldBegin('key_cache_save_period_in_seconds', TType::I32, 20);
2801 0 $xfer += $output->writeI32($self->{key_cache_save_period_in_seconds});
2802 0 $xfer += $output->writeFieldEnd();
2803 }
2804 0 ▶ if (defined $self->{memtable_flush_after_mins}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"memtable_flush_after_mins"}) 0 0 0
2805 0 $xfer += $output->writeFieldBegin('memtable_flush_after_mins', TType::I32, 21);
2806 0 $xfer += $output->writeI32($self->{memtable_flush_after_mins});
2807 0 $xfer += $output->writeFieldEnd();
2808 }
2809 0 ▶ if (defined $self->{memtable_throughput_in_mb}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"memtable_throughput_in_mb"}) 0 0 0
2810 0 $xfer += $output->writeFieldBegin('memtable_throughput_in_mb', TType::I32, 22);
2811 0 $xfer += $output->writeI32($self->{memtable_throughput_in_mb});
2812 0 $xfer += $output->writeFieldEnd();
2813 }
2814 0 ▶ if (defined $self->{memtable_operations_in_millions}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"memtable_operations_in_millions"}) 0 0 0
2815 0 $xfer += $output->writeFieldBegin('memtable_operations_in_millions', TType::DOUBLE, 23);
2816 0 $xfer += $output->writeDouble($self->{memtable_operations_in_millions});
2817 0 $xfer += $output->writeFieldEnd();
2818 }
2819 0 ▶ if (defined $self->{replicate_on_write}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"replicate_on_write"}) 0 0 0
2820 0 $xfer += $output->writeFieldBegin('replicate_on_write', TType::BOOL, 24);
2821 0 $xfer += $output->writeBool($self->{replicate_on_write});
2822 0 $xfer += $output->writeFieldEnd();
2823 }
2824 0 ▶ if (defined $self->{merge_shards_chance}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"merge_shards_chance"}) 0 0 0
2825 0 $xfer += $output->writeFieldBegin('merge_shards_chance', TType::DOUBLE, 25);
2826 0 $xfer += $output->writeDouble($self->{merge_shards_chance});
2827 0 $xfer += $output->writeFieldEnd();
2828 }
2829 0 ▶ if (defined $self->{key_validation_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key_validation_class"}) 0 0 0
2830 0 $xfer += $output->writeFieldBegin('key_validation_class', TType::STRING, 26);
2831 0 $xfer += $output->writeString($self->{key_validation_class});
2832 0 $xfer += $output->writeFieldEnd();
2833 }
2834 0 ▶ if (defined $self->{row_cache_provider}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"row_cache_provider"}) 0 0 0
2835 0 $xfer += $output->writeFieldBegin('row_cache_provider', TType::STRING, 27);
2836 0 $xfer += $output->writeString($self->{row_cache_provider});
2837 0 $xfer += $output->writeFieldEnd();
2838 }
2839 0 ▶ if (defined $self->{key_alias}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key_alias"}) 0 0 0
2840 0 $xfer += $output->writeFieldBegin('key_alias', TType::STRING, 28);
2841 0 $xfer += $output->writeString($self->{key_alias});
2842 0 $xfer += $output->writeFieldEnd();
2843 }
2844 0 $xfer += $output->writeFieldStop();
2845 0 $xfer += $output->writeStructEnd();
2846 0 return $xfer;
2847 }
2848  
2849 package Cassandra::KsDef;
2850 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
2851 1 $Cassandra::KsDef::VERSION = '0.4.0';
2852 }
2853 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
2854 1 Cassandra::KsDef->mk_accessors( qw( name strategy_class strategy_options replication_factor cf_defs durable_writes ) );
2855  
2856 0 ▶sub new {
Subroutine new: not called CC=9 SCAR=45.0
2857 0 my $classname = shift;
2858 0 my $self = {};
2859 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
2860 0 $self->{name} = undef;
2861 0 $self->{strategy_class} = undef;
2862 0 $self->{strategy_options} = undef;
2863 0 $self->{replication_factor} = undef;
2864 0 $self->{cf_defs} = undef;
2865 0 $self->{durable_writes} = 1;
2866 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
2867 0 ▶ if (defined $vals->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"name"}) 0 0 0
2868 0 $self->{name} = $vals->{name};
2869 }
2870 0 ▶ if (defined $vals->{strategy_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"strategy_class"}) 0 0 0
2871 0 $self->{strategy_class} = $vals->{strategy_class};
2872 }
2873 0 ▶ if (defined $vals->{strategy_options}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"strategy_options"}) 0 0 0
2874 0 $self->{strategy_options} = $vals->{strategy_options};
2875 }
2876 0 ▶ if (defined $vals->{replication_factor}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"replication_factor"}) 0 0 0
2877 0 $self->{replication_factor} = $vals->{replication_factor};
2878 }
2879 0 ▶ if (defined $vals->{cf_defs}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"cf_defs"}) 0 0 0
2880 0 $self->{cf_defs} = $vals->{cf_defs};
2881 }
2882 0 ▶ if (defined $vals->{durable_writes}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"durable_writes"}) 0 0 0
2883 0 $self->{durable_writes} = $vals->{durable_writes};
2884 }
2885 }
2886 0 return bless ($self, $classname);
2887 }
2888  
2889 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
2890 0 return 'KsDef';
2891 }
2892  
2893 0 ▶sub read {
Subroutine read: not called CC=17 SCAR=57.2
2894 0 my ($self, $input) = @_;
2895 0 my $xfer = 0;
2896 0 my $fname;
2897 0 my $ftype = 0;
2898 0 my $fid = 0;
2899 0 $xfer += $input->readStructBegin(\$fname);
2900 0 while (1)
2901 {
2902 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
2903 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
2904 0 last;
2905 }
2906 0 SWITCH: for($fid)
2907 {
2908 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"name"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2909 0 $xfer += $input->readString(\$self->{name});
2910 } else {
2911 0 $xfer += $input->skip($ftype);
2912 }
2913 0 last; };
2914 0 ▶ /^2$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"strategy_class"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
2915 0 $xfer += $input->readString(\$self->{strategy_class});
2916 } else {
2917 0 $xfer += $input->skip($ftype);
2918 }
2919 0 last; };
2920 0 ▶ /^3$/ && do{ if ($ftype == TType::MAP) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 13) { { my $_size58 = 0; $self->{"strategy_options"} = {}; my $_ktype59 = 0; my $_vtype60 = 0; $xfer += $input->readMapBegin(\$_ktype59, \$_vtype60, \$_size58); for (my $_i62 = 0; $_i62 < $_size58; ++$_i62) { my $key63 = ""; my $val64 = ""; $xfer += $input->readString(\$key63); $xfer += $input->readString(\$val64); $self->{"strategy_options"}{$key63} = $val64; } ; $xfer += $input->readMapEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 13) { } 0 0 0
2921 {
2922 0 my $_size58 = 0;
2923 0 $self->{strategy_options} = {};
2924 0 my $_ktype59 = 0;
2925 0 my $_vtype60 = 0;
2926 0 $xfer += $input->readMapBegin(\$_ktype59, \$_vtype60, \$_size58);
2927 0 ▶ for (my $_i62 = 0; $_i62 < $_size58; ++$_i62)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i62 < $_size58) 0 0 0
2928 {
2929 0 my $key63 = '';
2930 0 my $val64 = '';
2931 0 $xfer += $input->readString(\$key63);
2932 0 $xfer += $input->readString(\$val64);
2933 0 $self->{strategy_options}->{$key63} = $val64;
2934 }
2935 0 $xfer += $input->readMapEnd();
2936 }
2937 } else {
2938 0 $xfer += $input->skip($ftype);
2939 }
2940 0 last; };
2941 0 ▶ /^4$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^4$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"replication_factor"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
2942 0 $xfer += $input->readI32(\$self->{replication_factor});
2943 } else {
2944 0 $xfer += $input->skip($ftype);
2945 }
2946 0 last; };
2947 0 ▶ /^5$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^5$/ and do { if ($ftype == 15) { { my $_size65 = 0; $self->{"cf_defs"} = []; my $_etype68 = 0; $xfer += $input->readListBegin(\$_etype68, \$_size65); for (my $_i69 = 0; $_i69 < $_size65; ++$_i69) { my $elem70 = undef; $elem70 = "Cassandra::CfDef"->new; $xfer += $elem70->read($input); push @{$$self{"cf_defs"};}, $elem70; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
2948 {
2949 0 my $_size65 = 0;
2950 0 $self->{cf_defs} = [];
2951 0 my $_etype68 = 0;
2952 0 $xfer += $input->readListBegin(\$_etype68, \$_size65);
2953 0 ▶ for (my $_i69 = 0; $_i69 < $_size65; ++$_i69)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i69 < $_size65) 0 0 0
2954 {
2955 0 my $elem70 = undef;
2956 0 $elem70 = new Cassandra::CfDef();
2957 0 $xfer += $elem70->read($input);
2958 0 push(@{$self->{cf_defs}},$elem70);
2959 }
2960 0 $xfer += $input->readListEnd();
2961 }
2962 } else {
2963 0 $xfer += $input->skip($ftype);
2964 }
2965 0 last; };
2966 0 ▶ /^6$/ && do{ if ($ftype == TType::BOOL) {
Branch: 2 branches
BranchTrueFalseTotal
/^6$/ and do { if ($ftype == 2) { $xfer += $input->readBool(\$self->{"durable_writes"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 2) { } 0 0 0
2967 0 $xfer += $input->readBool(\$self->{durable_writes});
2968 } else {
2969 0 $xfer += $input->skip($ftype);
2970 }
2971 0 last; };
2972 0 $xfer += $input->skip($ftype);
2973 }
2974 0 $xfer += $input->readFieldEnd();
2975 }
2976 0 $xfer += $input->readStructEnd();
2977 0 return $xfer;
2978 }
2979  
2980 0 ▶sub write {
Subroutine write: not called CC=9 SCAR=45.0
2981 0 my ($self, $output) = @_;
2982 0 my $xfer = 0;
2983 0 $xfer += $output->writeStructBegin('KsDef');
2984 0 ▶ if (defined $self->{name}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"name"}) 0 0 0
2985 0 $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
2986 0 $xfer += $output->writeString($self->{name});
2987 0 $xfer += $output->writeFieldEnd();
2988 }
2989 0 ▶ if (defined $self->{strategy_class}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"strategy_class"}) 0 0 0
2990 0 $xfer += $output->writeFieldBegin('strategy_class', TType::STRING, 2);
2991 0 $xfer += $output->writeString($self->{strategy_class});
2992 0 $xfer += $output->writeFieldEnd();
2993 }
2994 0 ▶ if (defined $self->{strategy_options}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"strategy_options"}) 0 0 0
2995 0 $xfer += $output->writeFieldBegin('strategy_options', TType::MAP, 3);
2996 {
2997 0 $xfer += $output->writeMapBegin(TType::STRING, TType::STRING, scalar(keys %{$self->{strategy_options}}));
2998 {
2999 0 ▶ while( my ($kiter71,$viter72) = each %{$self->{strategy_options}})
Branch: 1 branch
BranchTrueFalseTotal
if (() = each %{$$self{"strategy_options"};}) 0 0 0
3000 {
3001 0 $xfer += $output->writeString($kiter71);
3002 0 $xfer += $output->writeString($viter72);
3003 }
3004 }
3005 0 $xfer += $output->writeMapEnd();
3006 }
3007 0 $xfer += $output->writeFieldEnd();
3008 }
3009 0 ▶ if (defined $self->{replication_factor}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"replication_factor"}) 0 0 0
3010 0 $xfer += $output->writeFieldBegin('replication_factor', TType::I32, 4);
3011 0 $xfer += $output->writeI32($self->{replication_factor});
3012 0 $xfer += $output->writeFieldEnd();
3013 }
3014 0 ▶ if (defined $self->{cf_defs}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"cf_defs"}) 0 0 0
3015 0 $xfer += $output->writeFieldBegin('cf_defs', TType::LIST, 5);
3016 {
3017 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{cf_defs}}));
3018 {
3019 0 foreach my $iter73 (@{$self->{cf_defs}})
3020 {
3021 0 $xfer += ${iter73}->write($output);
3022 }
3023 }
3024 0 $xfer += $output->writeListEnd();
3025 }
3026 0 $xfer += $output->writeFieldEnd();
3027 }
3028 0 ▶ if (defined $self->{durable_writes}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"durable_writes"}) 0 0 0
3029 0 $xfer += $output->writeFieldBegin('durable_writes', TType::BOOL, 6);
3030 0 $xfer += $output->writeBool($self->{durable_writes});
3031 0 $xfer += $output->writeFieldEnd();
3032 }
3033 0 $xfer += $output->writeFieldStop();
3034 0 $xfer += $output->writeStructEnd();
3035 0 return $xfer;
3036 }
3037  
3038 package Cassandra::CqlRow;
3039 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
3040 1 $Cassandra::CqlRow::VERSION = '0.4.0';
3041 }
3042 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
3043 1 Cassandra::CqlRow->mk_accessors( qw( key columns ) );
3044  
3045 0 ▶sub new {
Subroutine new: not called CC=5 SCAR=34.0
3046 0 my $classname = shift;
3047 0 my $self = {};
3048 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
3049 0 $self->{key} = undef;
3050 0 $self->{columns} = undef;
3051 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
3052 0 ▶ if (defined $vals->{key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"key"}) 0 0 0
3053 0 $self->{key} = $vals->{key};
3054 }
3055 0 ▶ if (defined $vals->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"columns"}) 0 0 0
3056 0 $self->{columns} = $vals->{columns};
3057 }
3058 }
3059 0 return bless ($self, $classname);
3060 }
3061  
3062 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
3063 0 return 'CqlRow';
3064 }
3065  
3066 0 ▶sub read {
Subroutine read: not called CC=8 SCAR=42.8
3067 0 my ($self, $input) = @_;
3068 0 my $xfer = 0;
3069 0 my $fname;
3070 0 my $ftype = 0;
3071 0 my $fid = 0;
3072 0 $xfer += $input->readStructBegin(\$fname);
3073 0 while (1)
3074 {
3075 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
3076 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
3077 0 last;
3078 }
3079 0 SWITCH: for($fid)
3080 {
3081 0 ▶ /^1$/ && do{ if ($ftype == TType::STRING) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 11) { $xfer += $input->readString(\$self->{"key"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 11) { } 0 0 0
3082 0 $xfer += $input->readString(\$self->{key});
3083 } else {
3084 0 $xfer += $input->skip($ftype);
3085 }
3086 0 last; };
3087 0 ▶ /^2$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 15) { { my $_size74 = 0; $self->{"columns"} = []; my $_etype77 = 0; $xfer += $input->readListBegin(\$_etype77, \$_size74); for (my $_i78 = 0; $_i78 < $_size74; ++$_i78) { my $elem79 = undef; $elem79 = "Cassandra::Column"->new; $xfer += $elem79->read($input); push @{$$self{"columns"};}, $elem79; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
3088 {
3089 0 my $_size74 = 0;
3090 0 $self->{columns} = [];
3091 0 my $_etype77 = 0;
3092 0 $xfer += $input->readListBegin(\$_etype77, \$_size74);
3093 0 ▶ for (my $_i78 = 0; $_i78 < $_size74; ++$_i78)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i78 < $_size74) 0 0 0
3094 {
3095 0 my $elem79 = undef;
3096 0 $elem79 = new Cassandra::Column();
3097 0 $xfer += $elem79->read($input);
3098 0 push(@{$self->{columns}},$elem79);
3099 }
3100 0 $xfer += $input->readListEnd();
3101 }
3102 } else {
3103 0 $xfer += $input->skip($ftype);
3104 }
3105 0 last; };
3106 0 $xfer += $input->skip($ftype);
3107 }
3108 0 $xfer += $input->readFieldEnd();
3109 }
3110 0 $xfer += $input->readStructEnd();
3111 0 return $xfer;
3112 }
3113  
3114 0 ▶sub write {
Subroutine write: not called CC=4 SCAR=30.0
3115 0 my ($self, $output) = @_;
3116 0 my $xfer = 0;
3117 0 $xfer += $output->writeStructBegin('CqlRow');
3118 0 ▶ if (defined $self->{key}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"key"}) 0 0 0
3119 0 $xfer += $output->writeFieldBegin('key', TType::STRING, 1);
3120 0 $xfer += $output->writeString($self->{key});
3121 0 $xfer += $output->writeFieldEnd();
3122 }
3123 0 ▶ if (defined $self->{columns}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"columns"}) 0 0 0
3124 0 $xfer += $output->writeFieldBegin('columns', TType::LIST, 2);
3125 {
3126 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{columns}}));
3127 {
3128 0 foreach my $iter80 (@{$self->{columns}})
3129 {
3130 0 $xfer += ${iter80}->write($output);
3131 }
3132 }
3133 0 $xfer += $output->writeListEnd();
3134 }
3135 0 $xfer += $output->writeFieldEnd();
3136 }
3137 0 $xfer += $output->writeFieldStop();
3138 0 $xfer += $output->writeStructEnd();
3139 0 return $xfer;
3140 }
3141  
3142 package Cassandra::CqlResult;
3143 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
3144 1 $Cassandra::CqlResult::VERSION = '0.4.0';
3145 }
3146 1 ▶use base qw(Class::Accessor);
Subroutine BEGIN: called CC=1 SCAR=0.0
3147 1 Cassandra::CqlResult->mk_accessors( qw( type rows num ) );
3148  
3149 0 ▶sub new {
Subroutine new: not called CC=6 SCAR=37.4
3150 0 my $classname = shift;
3151 0 my $self = {};
3152 0 ▶ my $vals = shift || {};
Condition0%0/2
shift() || {}
l!l
00
MC/DC0%0/1
shift() || {}
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
3153 0 $self->{type} = undef;
3154 0 $self->{rows} = undef;
3155 0 $self->{num} = undef;
3156 0 ▶ if (UNIVERSAL::isa($vals,'HASH')) {
Branch: 1 branch
BranchTrueFalseTotal
if (UNIVERSAL::isa($vals, "HASH")) 0 0 0
3157 0 ▶ if (defined $vals->{type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"type"}) 0 0 0
3158 0 $self->{type} = $vals->{type};
3159 }
3160 0 ▶ if (defined $vals->{rows}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"rows"}) 0 0 0
3161 0 $self->{rows} = $vals->{rows};
3162 }
3163 0 ▶ if (defined $vals->{num}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $vals->{"num"}) 0 0 0
3164 0 $self->{num} = $vals->{num};
3165 }
3166 }
3167 0 return bless ($self, $classname);
3168 }
3169  
3170 0 ▶sub getName {
Subroutine getName: not called CC=1 SCAR=6.9
3171 0 return 'CqlResult';
3172 }
3173  
3174 0 ▶sub read {
Subroutine read: not called CC=10 SCAR=47.0
3175 0 my ($self, $input) = @_;
3176 0 my $xfer = 0;
3177 0 my $fname;
3178 0 my $ftype = 0;
3179 0 my $fid = 0;
3180 0 $xfer += $input->readStructBegin(\$fname);
3181 0 while (1)
3182 {
3183 0 $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
3184 0 ▶ if ($ftype == TType::STOP) {
Branch: 1 branch
BranchTrueFalseTotal
if ($ftype == 0) 0 0 0
3185 0 last;
3186 }
3187 0 SWITCH: for($fid)
3188 {
3189 0 ▶ /^1$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^1$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"type"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
3190 0 $xfer += $input->readI32(\$self->{type});
3191 } else {
3192 0 $xfer += $input->skip($ftype);
3193 }
3194 0 last; };
3195 0 ▶ /^2$/ && do{ if ($ftype == TType::LIST) {
Branch: 2 branches
BranchTrueFalseTotal
/^2$/ and do { if ($ftype == 15) { { my $_size81 = 0; $self->{"rows"} = []; my $_etype84 = 0; $xfer += $input->readListBegin(\$_etype84, \$_size81); for (my $_i85 = 0; $_i85 < $_size81; ++$_i85) { my $elem86 = undef; $elem86 = "Cassandra::CqlRow"->new; $xfer += $elem86->read($input); push @{$$self{"rows"};}, $elem86; } ; $xfer += $input->readListEnd; } ; } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 15) { } 0 0 0
3196 {
3197 0 my $_size81 = 0;
3198 0 $self->{rows} = [];
3199 0 my $_etype84 = 0;
3200 0 $xfer += $input->readListBegin(\$_etype84, \$_size81);
3201 0 ▶ for (my $_i85 = 0; $_i85 < $_size81; ++$_i85)
Branch: 1 branch
BranchTrueFalseTotal
if ($_i85 < $_size81) 0 0 0
3202 {
3203 0 my $elem86 = undef;
3204 0 $elem86 = new Cassandra::CqlRow();
3205 0 $xfer += $elem86->read($input);
3206 0 push(@{$self->{rows}},$elem86);
3207 }
3208 0 $xfer += $input->readListEnd();
3209 }
3210 } else {
3211 0 $xfer += $input->skip($ftype);
3212 }
3213 0 last; };
3214 0 ▶ /^3$/ && do{ if ($ftype == TType::I32) {
Branch: 2 branches
BranchTrueFalseTotal
/^3$/ and do { if ($ftype == 8) { $xfer += $input->readI32(\$self->{"num"}); } else { $xfer += $input->skip($ftype); } ; last } 0 0 0
if ($ftype == 8) { } 0 0 0
3215 0 $xfer += $input->readI32(\$self->{num});
3216 } else {
3217 0 $xfer += $input->skip($ftype);
3218 }
3219 0 last; };
3220 0 $xfer += $input->skip($ftype);
3221 }
3222 0 $xfer += $input->readFieldEnd();
3223 }
3224 0 $xfer += $input->readStructEnd();
3225 0 return $xfer;
3226 }
3227  
3228 0 ▶sub write {
Subroutine write: not called CC=5 SCAR=34.0
3229 0 my ($self, $output) = @_;
3230 0 my $xfer = 0;
3231 0 $xfer += $output->writeStructBegin('CqlResult');
3232 0 ▶ if (defined $self->{type}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"type"}) 0 0 0
3233 0 $xfer += $output->writeFieldBegin('type', TType::I32, 1);
3234 0 $xfer += $output->writeI32($self->{type});
3235 0 $xfer += $output->writeFieldEnd();
3236 }
3237 0 ▶ if (defined $self->{rows}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"rows"}) 0 0 0
3238 0 $xfer += $output->writeFieldBegin('rows', TType::LIST, 2);
3239 {
3240 0 $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{rows}}));
3241 {
3242 0 foreach my $iter87 (@{$self->{rows}})
3243 {
3244 0 $xfer += ${iter87}->write($output);
3245 }
3246 }
3247 0 $xfer += $output->writeListEnd();
3248 }
3249 0 $xfer += $output->writeFieldEnd();
3250 }
3251 0 ▶ if (defined $self->{num}) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->{"num"}) 0 0 0
3252 0 $xfer += $output->writeFieldBegin('num', TType::I32, 3);
3253 0 $xfer += $output->writeI32($self->{num});
3254 0 $xfer += $output->writeFieldEnd();
3255 }
3256 0 $xfer += $output->writeFieldStop();
3257 0 $xfer += $output->writeStructEnd();
3258 0 return $xfer;
3259 }
3260  
3261 1 1;
↑ Summary Lite.pm »