[XMLPipeDB-developer] GenMAPP multitaxon support - CMSI 486T
Brought to you by:
kdahlquist,
zugzugglug
From: Richard B. <rbr...@gm...> - 2011-07-07 02:37:53
|
Update on status: Over the past two weeks I have spent time doing the following: 1. Reviewed the taxon id code changes which Don Murphy coded and were merged to create version 2.0 b64 2. Reviewed the UniprotDatabaseProfile, UniprotSpeciesProfile, SpeciesProfile, Profile and DatabaseProfile files 3. Reviewed and discussed the process by which GenMAPP matches *single*taxon ids found in a Postgres db with the known species profiles. Current actions: During the last few days I have started coding in the ability for the species matching functionality to surface multiple taxon ids from within a Postgres db. The process being the following steps: 1. Grab all the taxon ids from the Postgres db The current iteration of the software already does this. In the checkRequirements method in UniprotDatabaseProfile.java, a query of the Postgres db acquires all taxon id's and stores them in ResultSet result variable. 2. Check to find match between the taxon ids from Postgres against existing species profiles for known species. The current iteration compares each taxon id in ResultSet result variable. First taxon id from result: If match was found, then that species profile with associated taxon id was added to the speciesProfilesFound arraylist. If no match was found, a generic species profile associated with the current taxon id was added to the speciesProfilesFound arraylist. Next taxon id from result If match was found, then that species profile with associated taxon id was added to the speciesProfilesFound arraylist. If no match was found, a generic species profile associated with the current taxon id was added to the speciesProfilesFound arraylist. Repeat until no more taxon ids are found in ResultSet result variable. 3. Replace the JComboBox with a JList to allow the user to choose a selection of multiple species to export. Use the getSelectedIndices method for JList to determine which species have been selected for export. 4. Modify the export process to run a pass for each species selected to generate a multispecies gdb. details to be determined. ----------------------------------------------------------------------------------------------------------------------------------------------------------- Discussion for tomorrows call: We previously discussed allowing user input to manually add taxon ids and associate them to the generic profile. Unless I don't really understand the reasoning behind this, it seems to me that it is unnecessary. Why would we add a taxon id during the export process that isn't already in the Postgres data? The current implementation already captures every taxon id in speciesProfilesFound regardless if its a known species or not. So it seems that we don't need to make any modifications in surfacing taxon ids from a Postgres db. Then we can go directly to #3 above which I have mostly coded, but can't seem to figure out how and where to populate the JList. In reviewing constructor documentation it indicates 4 ways to instantiate. My first choice was to create an empty JList [ JList () ] and populate it later but I don't see a method to do so such as addItems or something similar. I then tried to instantiate with speciesProfileFound as an array argument: JList ( SpeciesProfile[] speciesProfilesFound ) but can't resolve. Anyway, I look forward to our call at 9am tomorrow. Richard |