public UniprotFeatureChain retrieveUniprotFeatureChain( UniprotProtein uniProtEntry, String ac) { if (uniProtEntry != null && ac != null){ for (UniprotFeatureChain fc : uniProtEntry.getFeatureChains()){ String acFixed = ac; // if not of type primaryAc-PRO_xxxxx, it is not a feature chain. we have to build the feature chain ac if (ac.indexOf("-") == -1){ acFixed = uniProtEntry.getPrimaryAc() + "-" + ac; } if (acFixed.equals(fc.getPrimaryAc())){ return fc; } } } return null; } }
protein.getFeatureChains().add( chain );
protein.getFeatureChains().add( chain );
protein.getFeatureChains().add( chain );