From: Cyril P. <cpo...@us...> - 2005-12-07 15:49:28
|
Update of /cvsroot/gmod/apollo/src/java/apollo/dataadapter/chado In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25446/java/apollo/dataadapter/chado Modified Files: ChadoTransactionTransformer.java Log Message: Corrected the Name modification bug (need a new version of the triggers for this to work), the merging of tmp and existing transcripts and a gameXML roundtrip problem. ChadoTransactionTransformer : - added the transactions for keeping peptides naming logic in apollo : now peptides will have theire name(genename-peptide#) + theire uniquename (RICE#) . This was needed for bug 1374177 - Correcting the exon naming which was using geneId:start-stop instead of geneName:start-stop TransactionXMLAdapter.java: -When deleting an alternate transcript, adding the transcript's parent to the tnxml file. This is needed to commit alt transcripts transactions properly when roundtrippping with gameXML AnnotationEditor : Merging temp transcript with an existing one (bug# 1374224) . Now if the user merge a temp gene with an existing one, all the exons of the temp are moved to the existing, and the resulting transcript retains the name of the existing one. In this case, there is no more dialog asking the merged transcript's name. Index: ChadoTransactionTransformer.java =================================================================== RCS file: /cvsroot/gmod/apollo/src/java/apollo/dataadapter/chado/ChadoTransactionTransformer.java,v retrieving revision 1.62 retrieving revision 1.63 diff -C2 -d -r1.62 -r1.63 *** ChadoTransactionTransformer.java 5 Dec 2005 21:30:13 -0000 1.62 --- ChadoTransactionTransformer.java 7 Dec 2005 15:49:19 -0000 1.63 *************** *** 288,296 **** /** for now chado peptides are carrying around uniquenames(RICE#) ! not names(genename-peptide#), this may change, not sure */ private void updatePeptideName(String oldUniqueName, SeqFeatureI feature, List transformedTns) { ChadoUpdateTransaction cut = ! makeNameTransaction(oldUniqueName,feature,getPolypeptideType(),null,feature.getPeptideSequence().getAccessionNo()); transformedTns.add(cut); } --- 288,304 ---- /** for now chado peptides are carrying around uniquenames(RICE#) ! not names(genename-peptide#), this may change, not sure ! Change : now peptides will have theire name(genename-peptide#) + theire uniquename (RICE#) */ private void updatePeptideName(String oldUniqueName, SeqFeatureI feature, List transformedTns) { + + //TODO transitional state,peptide become SeqFeature instead of Sequence + //Get the peptide's feature name or the sequence if the SeqFeature is null + String pepNewName=feature.getPeptideSequence().getAccessionNo(); + if (feature.getProteinFeat() != null){ + pepNewName=feature.getProteinFeat().getName(); + } ChadoUpdateTransaction cut = ! makeNameTransaction(oldUniqueName,feature,getPolypeptideType(),null,pepNewName); transformedTns.add(cut); } *************** *** 423,427 **** SeqFeatureI transcript = exon.getRefFeature(); // should this be id or name - i think it should be name?? ! String geneName = transcript.getRefFeature().getId(); String oldChadoName = getChadoExonName(geneName,oldRange); //geneName+":"+oldRange.getStart()+"-"+oldRange.getEnd(); --- 431,437 ---- SeqFeatureI transcript = exon.getRefFeature(); // should this be id or name - i think it should be name?? ! //Yes, it should be name (CP 01/12/2005) ! //String geneName = transcript.getRefFeature().getId(); ! String geneName = transcript.getRefFeature().getName(); String oldChadoName = getChadoExonName(geneName,oldRange); //geneName+":"+oldRange.getStart()+"-"+oldRange.getEnd(); |