+ siftsMapping = getStructureMapping(seq, pdbFile, targetChainId,
+ pdb, maxChain, sqmpping, maxAlignseq, siftsClient);
+ seqToStrucMapping.add(siftsMapping);
+ maxChain.makeExactMapping(siftsMapping, seq);
+ maxChain.transferRESNUMFeatures(seq, "IEA: SIFTS");
+ maxChain.transferResidueAnnotation(siftsMapping, null);
+ ds.addPDBId(maxChain.sequence.getAllPDBEntries().get(0));
+
+ } catch (SiftsException e)
+ {
+ // fall back to NW alignment
+ Cache.log.error(e.getMessage());
+ StructureMapping nwMapping = getNWMappings(seq, pdbFile,
+ targetChainId, maxChain, pdb, maxAlignseq);
+ seqToStrucMapping.add(nwMapping);
+ maxChain.makeExactMapping(maxAlignseq, seq);
+ maxChain.transferRESNUMFeatures(seq, "IEA:Jalview"); // FIXME: is
+ // this
+ // "IEA:Jalview" ?
+ maxChain.transferResidueAnnotation(nwMapping, sqmpping);
+ ds.addPDBId(maxChain.sequence.getAllPDBEntries().get(0));
+ }
+ }
+ else
+ {
+ List<StructureMapping> foundSiftsMappings = new ArrayList<>();
+ for (PDBChain chain : pdb.getChains())
+ {
+ StructureMapping siftsMapping = null;
+ try
+ {
+ siftsMapping = getStructureMapping(seq,
+ pdbFile, chain.id, pdb, chain, sqmpping, maxAlignseq,
+ siftsClient);
+ foundSiftsMappings.add(siftsMapping);
+ chain.makeExactMapping(siftsMapping, seq);
+ chain.transferRESNUMFeatures(seq, "IEA: SIFTS");// FIXME: is this
+ // "IEA:SIFTS" ?
+ chain.transferResidueAnnotation(siftsMapping, null);
+ } catch (SiftsException e)
+ {
+ System.err.println(e.getMessage());
+ }
+ catch (Exception e)