Collection<DbReference> sourceRefs = XrefUtils.searchByType(interaction.getXref(), "source reference", "MI:0685"); Collection<DbReference> interactionAcs = XrefUtils.searchByType(interaction.getXref(), IDENTITY, IDENTITY_REF); interactionAcs.add(interaction.getXref().getPrimaryRef()); log.warn("The interaction identifiers provided is not an identity in the original XML");
bpXrefs.addAll(getXrefs(interaction.getXref()));
/** * Build a new Interaction with no participants but holding a copy of all other attributes of the given interaction. * <br/> WARNING: all attributes of the newly created interaction are the same as the source's (that is same object * instance). This is not an object clone. * * @param source the source interaction. * @return a target interaction which is a copy of the source interaction but the participants or * inferredInteractions. */ protected Interaction copyInteraction(Interaction source) { Interaction target = new Interaction(); // clone inner attributes target.setId(source.getId()); target.setImexId(source.getImexId()); // objects target.setNames(source.getNames()); target.setXref(source.getXref()); // collections target.getConfidences().addAll(source.getConfidences()); target.getExperiments().addAll(source.getExperiments()); target.getInteractionTypes().addAll(source.getInteractionTypes()); // added with mitab 27 target.setModelled(source.isModelled()); target.setIntraMolecular(source.isIntraMolecular()); target.setNegative(source.isNegative()); target.getParameters().addAll(source.getParameters()); target.getAttributes().addAll(source.getAttributes()); target.setAvailability(source.getAvailability()); return target; }
jInteraction.setXref( xrefConverter.toJaxb( mInteraction.getXref() ) );
jInteraction.setXref( xrefConverter.toJaxb( mInteraction.getXref() ) );
IntactConverterUtils.populateXref(psiObject.getXref(), interaction, xrefConverter); IntactConverterUtils.populateAnnotations(psiObject, interaction, getInstitution(), annotationConverter);