Treex/Block/Read/Text.pm

filter: Statementstmt 100% 16 / 16 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 3 / 3 Podpod 100% 1 / 1 totaltotal 100% 22 / 22 CC 2 SCAR 4.1
CC
2
Cov
100%
next_document
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.5
« Treex/Core/Common.pm ↑ Summary Treex/Block/Write/Text.pm »
1 package Treex::Block::Read::Text;
2 3 $Treex::Block::Read::Text::VERSION = '2.20210102';
3 3 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 3 ▶use Treex::Core::Common;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 3 extends 'Treex::Block::Read::BaseTextReader';
6  
7 2 ▶sub next_document {
Subroutine next_document: called CC=2 SCAR=6.9
Pod documented
8 2 my ($self) = @_;
9 2 my $text = $self->next_document_text();
10 2 ▶ return if !defined $text;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $text 1 1 2
11  
12 1 my $document = $self->new_document();
13 1 my $zone = $document->create_zone( $self->language, $self->selector );
14 1 $zone->set_text($text);
15 1 return $document;
16 }
17  
18 3 1;
19  
20 __END__
« Treex/Core/Common.pm ↑ Summary Treex/Block/Write/Text.pm »