[MOBY-guts] biomoby commit

Mark Wilkinson mwilkinson at pub.open-bio.org
Fri May 9 14:45:31 UTC 2003


mwilkinson
Fri May  9 10:45:30 EDT 2003
Update of /home/repository/moby/moby-live/Perl/MOBY
In directory pub.open-bio.org:/tmp/cvs-serv8532/Perl/MOBY

Modified Files:
	Central.pm 
Log Message:
retrieve relationship types
moby-live/Perl/MOBY Central.pm,1.66,1.67
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/Central.pm,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -r1.66 -r1.67
--- /home/repository/moby/moby-live/Perl/MOBY/Central.pm	2003/05/09 14:42:20	1.66
+++ /home/repository/moby/moby-live/Perl/MOBY/Central.pm	2003/05/09 14:45:30	1.67
@@ -2654,18 +2654,7 @@
 	my $Parser = new XML::DOM::Parser;
 	my $doc = $Parser->parse($payload);
 	my $DOM = $doc->getDocumentElement();
-
-	my $x = $DOM->getElementsByTagName("Ontology");
-	my $ontology; my @child;
-    if ($x->item(0)){@child = $x->item(0)->getChildNodes;}
-    foreach (@child){
-        $debug && &_LOG ($_->getNodeTypeName, "\t", $_->toString,"\n");
-        print $_->getNodeTypeName, $_->toString;
-		next unless ($_->getNodeType == TEXT_NODE);
-		my $name = $_->toString; chomp $name;
-		$ontology = $name;
-    }
-
+	my $ontology =  &_nodeTextContent($DOM, "Ontology");
 	my $OS = MOBY::OntologyServer->new(ontology => 'relationship');
 	print "getting relationshps for the $ontology ontology\n";
 	my %types = %{$OS->getRelationshipTypes(ontology => $ontology)};




More information about the MOBY-guts mailing list