Bio-Biblio
view release on metacpan or search on metacpan
lib/Bio/Biblio/IO/medlinexml.pm view on Meta::CPAN
$data .= $_ while <$fh>;
$self->{'_xml_parser'}->parse ($data);
}
} elsif ($self->{'_data'}) {
$self->{'_xml_parser'}->parse ($self->{'_data'});
} else {
$self->throw ("XML source to be parsed is unknown. Should be given in the new().");
}
# when parsing is done all citations have already been delivered
# to the caller using her callbacks - and nothing to be stored
# here, or parser put all citations into global @Cittaions where
# we want to copy there into this instance - so any caller can
# start parsing other XML input without overwriting already read
# citations from the first parser
if (@Citations) {
$self->{'_citations'} = [];
foreach my $cit (@Citations) {
push (@{ $self->{'_citations'} }, $cit);
undef $cit;
}
( run in 0.703 second using v1.01-cache-2.11-cpan-9b1e4054eb1 )