[MOBY-guts] biomoby commit

Dennis Wang dwang at pub.open-bio.org
Mon Jul 25 20:43:49 UTC 2005


dwang
Mon Jul 25 16:43:49 EDT 2005
Update of /home/repository/moby/moby-live/Perl/MOBY/Adaptor/moby
In directory pub.open-bio.org:/tmp/cvs-serv21390/Perl/MOBY/Adaptor/moby

Modified Files:
	queryapi.pm 
Log Message:
updated getRelationship and getObjectRelationship documentation to be concurrent with Mark's

moby-live/Perl/MOBY/Adaptor/moby queryapi.pm,1.8,1.9
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/Adaptor/moby/queryapi.pm,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- /home/repository/moby/moby-live/Perl/MOBY/Adaptor/moby/queryapi.pm	2005/07/25 18:20:16	1.8
+++ /home/repository/moby/moby-live/Perl/MOBY/Adaptor/moby/queryapi.pm	2005/07/25 20:43:49	1.9
@@ -589,6 +589,20 @@
 	die "getParentTerms not implemented in adaptor\n";
 }
 
+=head2 getObjectRelationships
+
+ Title     :	getObjectRelationships
+ Usage     :	my $un = $API->getObjectRelationships(%args)
+ Function  :	Execute a query for objects that have relationships with other objects
+ Args      :    object1_id => Integer - a bind value for object1_id on an underlying SQL-based data source
+ Returns   :    listref of hashrefs:
+                [{relationship_type => String,
+                object_lsid         => Integer,
+                object2_articlename => String}, ...]
+				one hashref for each relationship between two objects
+ Notes     : 	relationship_type from object_term2term, object_lsid from object, and object2_articlename from object_term2term
+ 
+=cut
 # custom query subroutine for selecting from object_term2term and object tables
 # used in Moby::OntologyServer.pm->retrieveObject()
 sub getObjectRelationships{
@@ -598,13 +612,16 @@
 =head2 getRelationship
 
  Title     :	getRelationship
- Usage     :	my $un = $API->general_query(@args)
- Function  :	Execute a query for a relationship between two tables on an underlying SQL-based data source
- Returns   :	array of array-refs representing resulting rows
- Args      :    String - direction in the ontology (eg. 'root')
- 				String - name of the table ontology
- 				Integer - a bind value for lsid
- 				String - a bind value for relationship_type
+ Usage     :	my $un = $API->getRelationships(%args)
+ Function  :	Execute a query for a relationship between two ontologies
+ Args      :    direction => String - direction in the ontology (eg. 'root')
+ 				ontology => String - name of the table ontology
+ 				term => Integer - a bind value for lsid
+ 				relationship => String - a bind value for relationship_type
+ Returns   :	reference to array containing array-refs representing the result set:
+ 				[[Integer lsid, String relationship_type], ...]
+ 				each array-ref represents one row
+ Notes	   :	Only returns distinct lsid from $ontology and relationship_type from $ontology_term2term
 
 =cut
 # relationship query for any table used in Moby::OntologyServer->_doRelationshipQuery()
@@ -613,6 +630,7 @@
 	die "getRelationship not implemented in adaptor\n";
 }
 
+# Not quite sure what this does...
 sub _checkURI {
 	die "_checkURI not implemented in adaptor\n";
 }




More information about the MOBY-guts mailing list