| line | true | false | branch | 
 
| 254 | 0 | 0 | if (defined $coldb->{'dbdir'}) | 
 
| 286 | 0 | 0 | unless ref $coldb | 
 
| 290 | 0 | 0 | if $coldb->opened | 
 
| 296 | 0 | 0 | if (fctrunc($flags)) | 
 
| 298 | 0 | 0 | unless not -d $dbdir or remove_tree($dbdir) | 
 
| 304 | 0 | 0 | unless (-d $dbdir) | 
 
| 305 | 0 | 0 | unless fccreat($flags) | 
 
| 306 | 0 | 0 | unless make_path($dbdir) | 
 
| 312 | 0 | 0 | if (fcread($flags) and not fctrunc($flags)) | 
 
| 313 | 0 | 0 | unless $hdr = $coldb->readHeader | 
 
| 315 | 0 | 0 | unless $coldb->loadHeaderData($hdr) | 
 
| 324 | 0 | 0 | if (not $coldb->{'version'} or 'version'->parse($coldb->{'version'}) < 'version'->parse($min_version_compat)) { } | 
 
|  | 0 | 0 | elsif (not defined $coldb->{'xdmin'} && defined $coldb->{'xdmax'}) { } | 
 
| 337 | 0 | 0 | unless -r "$dbdir/tdf.hdr" | 
 
| 338 | 0 | 0 | if ($coldb->{'index_tdf'}) | 
 
| 339 | 0 | 0 | unless (require 'DiaColloDB/Relation/TDF.pm') | 
 
| 340 | 0 | 0 | $@ ? : | 
 
| 356 | 0 | 0 | -r "$dbdir/${attr}_enum.hdr" ? : | 
 
| 357 | 0 | 0 | unless $$coldb{"${attr}enum"} = $coldb->mmclass($ECLASS)->new('base', "${abase}enum", %efopts) | 
 
| 359 | 0 | 0 | unless $$coldb{"${attr}2t"} = $coldb->mmclass($MMCLASS)->new('base', "${abase}2t", %mmopts) | 
 
| 367 | 0 | 0 | unless $coldb->{'tenum'} = $coldb->mmclass($XECLASS)->new('base', "$dbdir/tenum", %efopts, 'pack_s', $coldb->{'pack_t'}) | 
 
| 370 | 0 | 0 | if ($coldb->{'index_xf'} // 1) | 
 
| 374 | 0 | 0 | unless $coldb->{'xf'} = 'DiaColloDB::Relation::Unigrams'->new('base', "$dbdir/xf", 'flags', $flags, 'mmap', $coldb->{'mmap'}, 'pack_i', $coldb->{'pack_id'}, 'pack_f', $coldb->{'pack_f'}, 'pack_d', $coldb->{'pack_date'}) | 
 
| 375 | 0 | 0 | if $coldb->{'xN'} and not $coldb->{'xf'}{'N'} | 
 
| 379 | 0 | 0 | if ($coldb->{'index_cof'} // 1) | 
 
| 384 | 0 | 0 | unless $coldb->{'cof'} = 'DiaColloDB::Relation::Cofreqs'->new('base', "$dbdir/cof", 'flags', $flags, 'mmap', $coldb->{'mmap'}, 'pack_i', $coldb->{'pack_id'}, 'pack_f', $coldb->{'pack_f'}, 'pack_d', $coldb->{'pack_date'}, 'dmax', $coldb->{'dmax'}, 'fmin', $coldb->{'cfmin'}) | 
 
| 388 | 0 | 0 | -r "$dbdir/ddc.hdr" ? : | 
 
| 392 | 0 | 0 | if ($coldb->{'index_tdf'}) | 
 
| 397 | 0 | 0 | -r "$dbdir/tdf.hdr" ? : | 
 
| 409 | 0 | 0 | ref $_[0] ? : | 
 
| 417 | 0 | 0 | unless ref $coldb | 
 
| 420 | 0 | 0 | unless defined $coldb->{$_} | 
 
| 421 | 0 | 0 | unless $coldb->{$_}->close | 
 
| 457 | 0 | 0 | if (not defined $hdr || fccreat($coldb->{'flags'})) { } | 
 
|  | 0 | 0 | elsif (defined $hdr) { } | 
 
| 487 | 0 | 0 | exists $coldb->{$_} ? : | 
 
| 565 | 0 | 0 | if (UNIVERSAL::can($coldb->{$rel}, 'profile')) { } | 
 
|  | 0 | 0 | elsif ($rel =~ /^(?:[ux]|f?1$)/) { } | 
 
|  | 0 | 0 | elsif ($rel =~ /^(?:c|f?1?2$)/) { } | 
 
|  | 0 | 0 | elsif ($rel =~ /^(?:v|vec|vs|vsem|sem|td[mf])$/) { } | 
 
| 609 | 0 | 0 | if (UNIVERSAL::isa($req, 'DDC::Any::CQTokInfl') or UNIVERSAL::isa($req, 'DDC::Any::CQTokExact')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($req, 'DDC::Any::CQTokSet') or UNIVERSAL::isa($req, 'DDC::Any::CQTokSetInfl')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($req, 'DDC::Any::CQTokRegex')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($req, 'DDC::Any::CQTokAny')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($req, 'ARRAY')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($req, 'Regexp') or $req =~ m[^/]) { } | 
 
|  | 0 | 0 | elsif (not ref $req) { } | 
 
| 666 | 0 | 0 | if ($date =~ /^[\s\*]*$/) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($date, 'Regexp') or $date =~ m[^/]) { } | 
 
|  | 0 | 0 | elsif ($date =~ /^\s*((?:[0-9]+|\*?))\s*[\-\:]+\s*((?:[0-9]+|\*?))\s*$/) { } | 
 
|  | 0 | 0 | elsif ($date =~ /[\s\,\|]+/) { } | 
 
| 672 | 0 | 0 | if $ddcmode | 
 
| 679 | 0 | 0 | if ($dlo // '') =~ /^\*?$/ | 
 
| 680 | 0 | 0 | if ($dhi // '') =~ /^\*?$/ | 
 
| 683 | 0 | 0 | if $_[0] >= $dlo | 
 
| 687 | 0 | 0 | if $ddcmode | 
 
| 698 | 0 | 0 | if ($fill) | 
 
| 699 | 0 | 0 | if not $dlo or $dlo < $coldb->{'xdmin'} | 
 
| 700 | 0 | 0 | if not $dhi or $dhi > $coldb->{'xdmax'} | 
 
| 704 | 0 | 0 | $slice ? : | 
 
| 707 | 0 | 0 | wantarray ? : | 
 
| 725 | 0 | 0 | if ($@ or not defined $q) | 
 
| 761 | 0 | 0 | UNIVERSAL::isa($req, 'HASH') ? : | 
 
|  | 0 | 0 | UNIVERSAL::isa($req, 'ARRAY') ? : | 
 
| 766 | 0 | 0 | if $req =~ s/^\s*\[(.*)\]\s*$/$1/ | 
 
| 776 | 0 | 0 | $parseas eq 'groupby' ? : | 
 
| 780 | 0 | 0 | if (not $areqs and $ddcmode <= 0 and $req =~ /^$sepre*			##-- initial separators (optional) | 
 
| 787 | 0 | 0 | if $coldb->{'debug'} | 
 
| 793 | 0 | 0 | if ($areqs) { } | 
 
| 797 | 0 | 0 | if (UNIVERSAL::isa($_, 'ARRAY')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($_, 'HASH')) { } | 
 
| 805 | 0 | 0 | if uc $_ eq 'WITH' | 
 
| 806 | 0 | 0 | /^($attrre)[:=]($valre)$/ ? : | 
 
| 808 | 0 | 0 | if defined $areq | 
 
| 812 | 0 | 0 | if defined $defaultIndex and not defined $areq | 
 
| 813 | 0 | 0 | if ($attr // '') eq '' | 
 
| 816 | 0 | 0 | if $coldb->{'debug'} | 
 
| 818 | 0 | 0 | if (UNIVERSAL::isa($areq, 'DDC::Any::CQuery')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($areq, 'ARRAY')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($areq, 'RegExp') or ($opts{'ddcmode'} || 0) < 1 and $areq and $areq =~ /^$regre$/) { } | 
 
|  | 0 | 0 | elsif (not $areq or $areq =~ /^\s*$reqre\s*$/) { } | 
 
|  | 0 | 0 | elsif ($ddcmode and ($areq // '') ne '') { } | 
 
| 821 | 0 | 0 | if $aq->can('setIndexName') and $attr ne '' | 
 
| 838 | 0 | 0 | ($vals->[0] // '*') eq '*' ? : | 
 
|  | 0 | 0 | @$vals <= 1 ? : | 
 
| 847 | 0 | 0 | unless $aq = $coldb->qparse($areq) | 
 
| 850 | 0 | 0 | $q ? : | 
 
| 861 | 0 | 0 | if not $err = $@ and defined $q | 
 
| 862 | 0 | 0 | if ($err =~ /syntax error/) | 
 
| 863 | 0 | 0 | if ($err =~ /unexpected ','/) { } | 
 
|  | 0 | 0 | elsif ($err =~ /expecting '='/) { } | 
 
|  | 0 | 0 | elsif ($err =~ /unexpected SYMBOL, expecting INTEGER at line \d+, near token \`([^\']*)\'/) { } | 
 
| 886 | 0 | 0 | UNIVERSAL::isa($_[0], 'DDC::Any::CQAnd') ? : | 
 
| 888 | 0 | 0 | if $opts{'mapand'} or not defined $opts{'mapand'} || $req0 =~ /\&\&/ | 
 
| 891 | 0 | 0 | if ref $opts{'qref'} | 
 
| 893 | 0 | 0 | if $coldb->{'debug'} | 
 
| 917 | 0 | 0 | unless $opts{'relax'} | 
 
| 924 | 0 | 0 | if (not defined $q) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQWith')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQueryOptions')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQToken')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFilter')) { } | 
 
| 934 | 0 | 0 | if @{$q->getWithin;} | 
 
| 935 | 0 | 0 | if $q->getContextSentencesCount | 
 
| 939 | 0 | 0 | if $q->getNegated | 
 
| 940 | 0 | 0 | if $q->can('getExpanders') and @{$q->getExpanders;} | 
 
| 943 | 0 | 0 | if (ref($q) =~ /^DDC::\w+::CQTok(?:Exact|Set|Regex|Any)$/) { } | 
 
|  | 0 | 0 | elsif (ref($q) =~ /^DDC::\w+::CQTokInfl$/) { } | 
 
|  | 0 | 0 | elsif (ref($q) =~ /^DDC::\w+::CQTokSetInfl$/) { } | 
 
|  | 0 | 0 | elsif (ref($q) =~ /^DDC::\w+::CQTokPrefix$/) { } | 
 
|  | 0 | 0 | elsif (ref($q) =~ /^DDC::\w+::CQTokSuffix$/) { } | 
 
|  | 0 | 0 | elsif (ref($q) =~ /^DDC::\w+::CQTokInfix$/) { } | 
 
| 958 | 0 | 0 | if $aq and $aq->isa('DDC::Any::CQTokAny') | 
 
| 963 | 0 | 0 | if ($q->isa('DDC::Any::CQFHasField')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFRandomSort') or $q->isa('DDC::Any::CQFRankSort')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFSort') and $q->getArg1 ne '' || $q->getArg2 ne '') { } | 
 
| 966 | 0 | 0 | if ($q->isa('DDC::Any::CQFHasFieldValue')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFHasFieldSet')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFHasFieldRegex')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFHasFieldPrefix')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFHasFieldSuffix')) { } | 
 
|  | 0 | 0 | elsif ($q->isa('DDC::Any::CQFHasFieldInfix')) { } | 
 
| 987 | 0 | 0 | if $aq and $aq->isa('DDC::Any::CQTokAny') | 
 
| 1007 | 0 | 0 | unless UNIVERSAL::isa($allowExtra, 'HASH') | 
 
| 1010 | 0 | 0 | if (not $opts{'allowUnknown'} || $coldb->hasAttr($attr) || $allowExtra && exists $allowExtra->{$attr}) { } | 
 
| 1058 | 0 | 0 | if UNIVERSAL::isa($gbreq, 'HASH') | 
 
| 1087 | 0 | 0 | $_->[1] && !UNIVERSAL::isa($_->[1], 'DDC::Any::CQTokAny') ? : | 
 
| 1093 | 0 | 0 | if (grep {$_;} @gbids) { } | 
 
| 1106 | 0 | 0 | unless $ts2g_sub | 
 
| 1112 | 0 | 0 | unless $ti2g_sub | 
 
| 1118 | 0 | 0 | if (@$gbattrs == 1) { } | 
 
| 1142 | 0 | 0 | unless $g2s | 
 
| 1147 | 0 | 0 | unless $s2g | 
 
| 1152 | 0 | 0 | unless $s2gx | 
 
| 1158 | 0 | 0 | if (@$gbattrs == 1) { } | 
 
| 1168 | 0 | 0 | unless $g2txt | 
 
| 1173 | 0 | 0 | unless $txt2g | 
 
| 1187 | 0 | 0 | unless defined $q | 
 
| 1192 | 0 | 0 | if $field =~ /^doc\.(.*)$/ | 
 
| 1193 | 0 | 0 | if (UNIVERSAL::isa($q, 'DDC::Any::CQTokAny')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($q, 'DDC::Any::CQTokExact') or UNIVERSAL::isa($q, 'DDC::Any::CQTokInfl')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($q, 'DDC::Any::CQTokSet') or UNIVERSAL::isa($q, 'DDC::Any::CQTokSetInfl')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($q, 'DDC::Any::CQTokRegex')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($q, 'DDC::Any::CQTokPrefix')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($q, 'DDC::Any::CQTokSuffix')) { } | 
 
|  | 0 | 0 | elsif (UNIVERSAL::isa($q, 'DDC::Any::CQTokInfix')) { } | 
 
| 1226 | 0 | 0 | $opts{'slice'} <= 0 ? : | 
 
| 1232 | 0 | 0 | if (not ref $req and $req =~ /^\s*(?:\#by)?\s*\[(.*)\]\s*$/) { } | 
 
| 1236 | 0 | 0 | unless my $gbq = $coldb->qparse("count(*) #by[$cbstr]") | 
 
| 1239 | 0 | 0 | if UNIVERSAL::isa($_, 'DDC::Any::CQCountKeyExprToken') | 
 
| 1247 | 0 | 0 | if ($_->[0] =~ /^doc\./) { } | 
 
| 1249 | 0 | 0 | if defined($filter = $coldb->query2filter($_->[0], $_->[1])) | 
 
| 1253 | 0 | 0 | if (defined $_->[1] and not UNIVERSAL::isa($_->[1], 'DDC::Any::CQTokAny')) | 
 
| 1254 | 0 | 0 | defined $gbrestr ? : | 
 
| 1309 | 0 | 0 | UNIVERSAL::isa($opts{'groupby'}, 'ARRAY') ? : | 
 
| 1315 | 0 | 0 | unless (defined($reldb = $coldb->relation($rel || 'cof'))) | 
 
| 1333 | 0 | 0 | if ref $that | 
 
| 1372 | 0 | 0 | if $opts{'slice2keys'} and not ref $opts{'slice2keys'} | 
 
| 1382 | 0 | 0 | UNIVERSAL::isa($opts{'groupby'}, 'ARRAY') ? : | 
 
| 1388 | 0 | 0 | unless (defined($reldb = $coldb->relation($rel || 'cof'))) | 
 
| 1443 | 0 | 0 | UNIVERSAL::isa($opts{'groupby'}, 'ARRAY') ? : | 
 
| 1449 | 0 | 0 | unless (defined($reldb = $coldb->relation($rel || 'cof'))) | 
 
| 1470 | 0 | 0 | defined $$opts{"a$_"} ? : | 
 
| 1471 | 0 | 0 | defined $opts->{$_} ? : | 
 
| 1473 | 0 | 0 | defined $$opts{"b$_"} ? : | 
 
| 1474 | 0 | 0 | defined $opts->{$_} ? : |