From: Tara L Andrews Date: Wed, 22 Feb 2012 21:11:02 +0000 (+0100) Subject: small conveniences X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=202ccb1893c888e21883362e19da98b90139efcb;p=scpubgit%2Fstemmatology.git small conveniences --- diff --git a/lib/Text/Tradition/Collation.pm b/lib/Text/Tradition/Collation.pm index 9076fb3..65984d6 100644 --- a/lib/Text/Tradition/Collation.pm +++ b/lib/Text/Tradition/Collation.pm @@ -28,6 +28,7 @@ has 'relations' => ( handles => { relationships => 'relationships', related_readings => 'related_readings', + get_relationship => 'get_relationship', del_relationship => 'del_relationship', }, writer => '_set_relations', diff --git a/lib/Text/Tradition/Parser/JSON.pm b/lib/Text/Tradition/Parser/JSON.pm index cc960b4..1d7b286 100644 --- a/lib/Text/Tradition/Parser/JSON.pm +++ b/lib/Text/Tradition/Parser/JSON.pm @@ -182,6 +182,9 @@ sub parse { foreach my $rdg ( grep { $_->is_lacuna } $c->readings ) { $c->del_reading( $rdg ) unless $c->reading_witnesses( $rdg ); } + + # Note that our ranks and common readings are set. + $c->_graphcalc_done(1); } =head2 make_nodes( $collation, $index, @tokenlist ) diff --git a/lib/Text/Tradition/Parser/Tabular.pm b/lib/Text/Tradition/Parser/Tabular.pm index 723c0aa..a561dde 100644 --- a/lib/Text/Tradition/Parser/Tabular.pm +++ b/lib/Text/Tradition/Parser/Tabular.pm @@ -241,6 +241,9 @@ sub parse { if $wit->has_layertext; } } + + # Note that our ranks and common readings are set. + $c->_graphcalc_done(1); } sub _make_nodes {