[Bioperl-guts-l] bioperl commit

Hilmar Lapp lapp at pub.open-bio.org
Sun Aug 29 00:06:37 EDT 2004


lapp
Sun Aug 29 00:06:37 EDT 2004
Update of /home/repository/bioperl/bioperl-live/Bio/OntologyIO
In directory pub.open-bio.org:/tmp/cvs-serv13250/Bio/OntologyIO

Modified Files:
	simplehierarchy.pm 
Log Message:
Fixed omitted related_to relationship from setting the ontology etc.

bioperl-live/Bio/OntologyIO simplehierarchy.pm,1.9,1.10
===================================================================
RCS file: /home/repository/bioperl/bioperl-live/Bio/OntologyIO/simplehierarchy.pm,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- /home/repository/bioperl/bioperl-live/Bio/OntologyIO/simplehierarchy.pm	2004/05/23 22:48:55	1.9
+++ /home/repository/bioperl/bioperl-live/Bio/OntologyIO/simplehierarchy.pm	2004/08/29 04:06:37	1.10
@@ -243,7 +243,9 @@
 					   -engine => $self->_ont_engine());
 
     # set up the ontology of the relationship types
-    foreach ($self->_part_of_relationship(), $self->_is_a_relationship()) {
+    foreach ($self->_part_of_relationship(), 
+             $self->_is_a_relationship(), 
+             $self->_related_to_relationship()) {
 	$_->ontology($ont);
     }
 
@@ -366,10 +368,7 @@
 sub _part_of_relationship {
     my ( $self, $term ) = @_;
 
-    $self->{ "_part_of_relationship" } ||= Bio::Ontology::RelationshipType->get_instance( 'PART_OF' );
-	return $self->{ "_part_of_relationship" };
-#    return $self->_ont_engine()->part_of_relationship();
-
+    return $self->_ont_engine()->part_of_relationship();
 
 } # _part_of_relationship 
 
@@ -379,14 +378,19 @@
 sub _is_a_relationship {
     my ( $self, $term ) = @_;
 
-    $self->{ "_is_a_relationship" } ||= Bio::Ontology::RelationshipType->get_instance( 'IS_A' );
-	return $self->{ "_is_a_relationship" };
-#    return $self->_ont_engine()->is_a_relationship();
-
+    return $self->_ont_engine()->is_a_relationship();
 
 } # _is_a_relationship 
 
 
+# This simply delegates. See SimpleGOEngine
+sub _related_to_relationship {
+    my ( $self, $term ) = @_;
+
+    return $self->_ont_engine()->related_to_relationship();
+
+} # _is_a_relationship 
+
 
 # This simply delegates. See SimpleGOEngine
 sub _add_relationship {



More information about the Bioperl-guts-l mailing list