Branch Coverage

blib/lib/Bio/Phylo/NeXML/Writable.pm
Criterion Covered Total %
branch 54 120 45.0


line true false branch
67 25 218 if (scalar @_ == 1 and ref $_[0] eq 'HASH') { }
218 0 elsif (my(%hash) = &looks_like_hash(@_)) { }
127 1443 0 if (&looks_like_object($meta_obj, $META_CONSTANT))
129 321 1122 unless ($meta{$id})
133 0 1443 if ($self->is_identifiable)
172 0 0 if ($meta{$id})
174 0 0 if ($meta{$id}[$i]->get_id == $meta_id)
180 0 0 unless ($meta{$id} and @{$meta{$id};})
200 71 729 if (my($meta) = @{$self->get_meta($predicate);}) { }
222 0 109 if ($meta and @{$meta;}) { }
277 110 0 if ($tag =~ qr/^[a-zA-Z]+\:?[a-zA-Z_]*$/) { }
303 11073 104 if (defined $name) { }
328 0 15558 if (scalar @_ == 1 and ref $_[0] eq 'HASH') { }
15558 0 elsif (scalar @_ % 2 == 0) { }
340 1496 15557 if ($key =~ /$fully_qualified_attribute_regex/)
342 0 1496 if ($prefix ne 'xmlns' and not exists $namespaces{$prefix})
369 1 0 if ($id =~ qr/^[a-zA-Z][a-zA-Z0-9\-_\.]*$/) { }
396 2 108 if ($uri)
419 9 108 if ($url)
442 109 0 if ($attrs and &looks_like_instance($attrs, 'HASH'))
469 2776 15014 if ($prefix) { }
493 0 0 unless ($ns_uri)
500 0 0 if ($namespaces->{$prefix} eq $ns_uri)
528 46684 15393 if (@_)
556 0 45884 unless $predicate
558 432 45452 if ($meta) { }
581 4 1531 if (my $tagstring = $tag{$self->get_id}) { }
1531 0 elsif (&looks_like_implementor($self, '_tag')) { }
608 213 22405 unless ($attributes{$id})
611 22121 497 if (defined $attributes{$id}{'label'}) { }
642 0 0 if (@{$meta;})
647 0 0 if ($has_contents) { }
648 0 0 if $closeme
651 0 0 $closeme ? :
710 0 15014 if ($attrs->{'label'}) { }
720 15014 0 unless ($attrs->{'id'})
723 0 15014 if (defined $self->is_identifiable and not $self->is_identifiable)
728 0 15014 if (not @{$self->get_meta;} and $attrs->{'about'})
733 0 15014 if ($self->can('get_taxa'))
734 0 0 if (my $taxa = $self->get_taxa) { }
735 0 0 if &looks_like_instance($taxa, 'Bio::Phylo')
744 0 15014 if ($self->can('get_taxon'))
745 0 0 if (my $taxon = $self->get_taxon) { }
755 15014 0 unless ($self->is_ns_suppressed)
761 0 15014 $arg ? :
779 13592 1424 if (my $id = $id{$self->get_id}) { }
813 3 151 if (my $base = $attrs->{'xml:base'})
825 2 149 if ($self->_type == 2) { }
867 0 0 unless (&looks_like_object($dom, 18))
883 0 0 if (&looks_like_implementor($self, 'get_sets'))
954 0 3489 ref $other ? :
979 0 0 if ($self->can('get_entities'))
981 0 0 if (&looks_like_implementor($ent, 'to_xml'))
987 0 0 if ($xml) { }
1013 0 0 if (&looks_like_object($dom, 18)) { }
1015 0 0 if ($self->can('get_entities'))
1017 0 0 if (&looks_like_implementor($ent, 'to_dom'))
1052 0 0 if $self->get_name
1053 0 0 if $self->get_link
1096 28406 0 if (not $self->isa('DBIx::Class::Core'))