Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[bioontology-support] REST Web Services for Provisional Terms

Jim Balhoff balhoff at nescent.org
Thu May 2 20:10:28 PDT 2013


Here is some Java code I use for retrieving the permanent ID associated with a provisional term (I believe the element argument is the classBean element, using JDOM):

private static String findPermanentID(Element element) {
		for (Object item : element.getChild("relations").getChildren("entry")) {
			final Element entry = (Element)item;
			final String entryKey = entry.getChild("string").getValue();
			if (entryKey.equals("provisionalPermanentId")) {
				if (entry.getChild("null") != null) {
					return null;
				} else {
					return ((Element)(entry.getChildren("string").get(1))).getValue();
				}
			}
		}
		return null;
	}



As an aside, while it's working for me I think the schema for the provisional term data could be revised to be much easier to parse.

Best regards,
Jim

On May 2, 2013, at 2:34 PM, Trish Whetzel <whetzel at stanford.edu> wrote:

> Dear Thomas, 
> 
> Are you referring to the "permanent id" as the ID once the term is incorporated into an ontology?
> 
> Trish 
> 
> 
> On May 2, 2013, at 10:02 AM, Thomas Rodenhausen wrote:
> 
>> Hi,
>> how can I determine if a created provisional term has been assigned a permanent id?
>> 
>> In the responses I can see two Id fields, id and fullId. Does the permanent id go into one of those fields once it has been assigned or how does it work?
>> 
>> <classBean>
>>             <id>http://purl.bioontology.org/ontology/provisional/97510595-3bb2-458f-94e8-fe8e90b9c608</id>
>>             <fullId>http://purl.bioontology.org/ontology/provisional/97510595-3bb2-458f-94e8-fe8e90b9c608</fullId>
>> .....
>> </classBean>
>> 
>> Thanks you
>> Thomas 
>> _______________________________________________
>> bioontology-support mailing list
>> bioontology-support at lists.stanford.edu
>> https://mailman.stanford.edu/mailman/listinfo/bioontology-support
> 
> _______________________________________________
> bioontology-support mailing list
> bioontology-support at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/bioontology-support

____________________________________________
James P. Balhoff, Ph.D.
National Evolutionary Synthesis Center
2024 West Main St., Suite A200
Durham, NC 27705
USA





More information about the bioontology-support mailing list