Class DefaultComplex
- java.lang.Object
-
- psidev.psi.mi.jami.model.impl.DefaultInteractor
-
- psidev.psi.mi.jami.model.impl.DefaultComplex
-
- All Implemented Interfaces:
Complex,Interaction<ModelledParticipant>,Interactor,ModelledInteraction,NamedInteraction<ModelledParticipant>
- Direct Known Subclasses:
MitabComplex
public class DefaultComplex extends DefaultInteractor implements Complex
Default implementation for complexes Notes: The equals and hashcode methods have NOT been overridden because the Complex object is a complex object. To compare Complex objects, you can use some comparators provided by default: - DefaultComplexComparator - UnambiguousComplexComparator - DefaultExactComplexComparator - UnambiguousExactComplexComparator - ComplexComparator- Since:
04/02/13
- Version:
- $Id$
- Author:
- Marine Dumousseau (marine@ebi.ac.uk)
-
-
Field Summary
-
Fields inherited from interface psidev.psi.mi.jami.model.Complex
COMPLEX, COMPLEX_MI
-
Fields inherited from interface psidev.psi.mi.jami.model.Interactor
UNKNOWN_INTERACTOR, UNKNOWN_INTERACTOR_MI
-
Fields inherited from interface psidev.psi.mi.jami.model.ModelledInteraction
ECO, ECO_MI
-
-
Constructor Summary
Constructors Constructor Description DefaultComplex(String name)Constructor for DefaultComplex.DefaultComplex(String name, String fullName)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, CvTerm interactorType)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, CvTerm interactorType, Organism organism)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, CvTerm interactorType, Organism organism, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, CvTerm interactorType, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, Organism organism)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, Organism organism, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, String fullName, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, CvTerm interactorType)Constructor for DefaultComplex.DefaultComplex(String name, CvTerm interactorType, Organism organism)Constructor for DefaultComplex.DefaultComplex(String name, CvTerm interactorType, Organism organism, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, CvTerm interactorType, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, Organism organism)Constructor for DefaultComplex.DefaultComplex(String name, Organism organism, Xref uniqueId)Constructor for DefaultComplex.DefaultComplex(String name, Xref uniqueId)Constructor for DefaultComplex.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanaddAllParticipants(Collection<? extends ModelledParticipant> participants)This method will add all the participant and set the interaction of the new participant to this current interactionbooleanaddParticipant(ModelledParticipant part)addParticipantvoidassignComplexAc(String accession)Assign a complex accession to a complex.voidassignComplexAc(String accession, String version)Assign a complex accession to a complex.protected voidclearPropertiesLinkedToAliases()clearPropertiesLinkedToAliasesprotected voidclearPropertiesLinkedToAnnotations()clearPropertiesLinkedToAnnotationsprotected voidclearPropertiesLinkedToChecksums()clearPropertiesLinkedToChecksumsprotected voidclearPropertiesLinkedToXrefs()Collection<Alias>getAliases()getAliasesCollection<Annotation>getAnnotations()getAnnotationsCollection<Checksum>getChecksums()getChecksumsStringgetComplexAc()Complex accession if the complex has been curated under the Complex Portal curation rules.StringgetComplexVersion()Complex version if the complex has been curated under the Complex Portal curation rules.Collection<CooperativeEffect>getCooperativeEffects()Getter for the fieldcooperativeEffects.DategetCreatedDate()Getter for the fieldcreatedDate.CvTermgetEvidenceType()Getter for the fieldevidenceType.Collection<Xref>getIdentifiers()getIdentifiersCollection<InteractionEvidence>getInteractionEvidences()Getter for the fieldinteractionEvidences.CvTermgetInteractionType()Getter for the fieldinteractionType.Collection<ModelledConfidence>getModelledConfidences()getModelledConfidencesCollection<ModelledParameter>getModelledParameters()getModelledParametersCollection<ModelledParticipant>getParticipants()getParticipantsStringgetPhysicalProperties()Getter for the fieldphysicalProperties.StringgetRecommendedName()Getter for the fieldrecommendedName.StringgetRigid()Getter for the fieldrigid.SourcegetSource()Getter for the fieldsource.StringgetSystematicName()Getter for the fieldsystematicName.DategetUpdatedDate()Getter for the fieldupdatedDate.Collection<Xref>getXrefs()getXrefsprotected voidinitialiseAliases()initialiseAliasesprotected voidinitialiseAnnotations()initialiseAnnotationsprotected voidinitialiseChecksums()initialiseChecksumsprotected voidinitialiseComponents()initialiseComponentsprotected voidinitialiseComponentsWith(Collection<ModelledParticipant> components)initialiseComponentsWithprotected voidinitialiseConfidences()initialiseConfidencesprotected voidinitialiseConfidencesWith(Collection<ModelledConfidence> confidences)initialiseConfidencesWithprotected voidinitialiseCooperativeEffects()initialiseCooperativeEffectsprotected voidinitialiseCooperativeEffectsWith(Collection<CooperativeEffect> cooperativeEffects)initialiseCooperativeEffectsWithprotected voidinitialiseInteractionEvidences()initialiseInteractionEvidencesprotected voidinitialiseInteractionEvidencesWith(Collection<InteractionEvidence> interactionEvidences)initialiseInteractionEvidencesWithprotected voidinitialiseParameters()initialiseParametersprotected voidinitialiseParametersWith(Collection<ModelledParameter> parameters)initialiseParametersWithprotected voidinitialiseXrefs()initialiseXrefsprotected voidprocessAddedAliasEvent(Alias added)processAddedAliasEventprotected voidprocessAddedAnnotationEvent(Annotation added)processAddedAnnotationEventprotected voidprocessAddedChecksumEvent(Checksum added)processAddedChecksumEventprotected voidprocessAddedXrefEvent(Xref added)processAddedXrefEventprotected voidprocessRemovedAliasEvent(Alias removed)processRemovedAliasEventprotected voidprocessRemovedAnnotationEvent(Annotation removed)processRemovedAnnotationEventprotected voidprocessRemovedChecksumEvent(Checksum removed)processRemovedChecksumEventprotected voidprocessRemovedXrefEvent(Xref removed)processRemovedXrefEventbooleanremoveAllParticipants(Collection<? extends ModelledParticipant> participants)This method will remove the participant and set the interaction of the removed participant to null.booleanremoveParticipant(ModelledParticipant part)removeParticipantvoidsetCreatedDate(Date created)Sets the created datevoidsetEvidenceType(CvTerm eco)Sets the evidence typevoidsetInteractionType(CvTerm term)Sets the interaction type.voidsetInteractorType(CvTerm interactorType)Sets the molecule type for this interactor If the given type is null, this method automatically sets the interactor type to 'unknown participant' (MI:0329)voidsetPhysicalProperties(String properties)Sets the physical properties of this complex.voidsetRecommendedName(String name)Sets the recommended name of this complex.voidsetRigid(String rigid)Sets the rigid of this interaction.voidsetSource(Source source)Sets the source reporting the interaction.voidsetSystematicName(String name)Sets the systematic name of this complex.voidsetUpdatedDate(Date updated)Sets the last update dateStringtoString()-
Methods inherited from class psidev.psi.mi.jami.model.impl.DefaultInteractor
getFullName, getInteractorType, getOrganism, getPreferredIdentifier, getPreferredName, getShortName, initialiseAliasesWith, initialiseAnnotationsWith, initialiseChecksumsWith, initialiseIdentifiers, initialiseIdentifiersWith, initialiseXrefsWith, setFullName, setOrganism, setShortName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface psidev.psi.mi.jami.model.Complex
getComparableParticipants
-
Methods inherited from interface psidev.psi.mi.jami.model.Interaction
getShortName, setShortName
-
Methods inherited from interface psidev.psi.mi.jami.model.Interactor
getFullName, getInteractorType, getOrganism, getPreferredIdentifier, getPreferredName, getShortName, setFullName, setOrganism, setShortName
-
Methods inherited from interface psidev.psi.mi.jami.model.NamedInteraction
getFullName, setFullName
-
-
-
-
Constructor Detail
-
DefaultComplex
public DefaultComplex(String name, CvTerm interactorType)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, String fullName, CvTerm interactorType)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, CvTerm interactorType, Organism organism)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, String fullName, CvTerm interactorType, Organism organism)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, CvTerm interactorType, Xref uniqueId)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, String fullName, CvTerm interactorType, Xref uniqueId)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, CvTerm interactorType, Organism organism, Xref uniqueId)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, String fullName, CvTerm interactorType, Organism organism, Xref uniqueId)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name)
Constructor for DefaultComplex.
- Parameters:
name- aStringobject.
-
DefaultComplex
public DefaultComplex(String name, Organism organism)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, String fullName, Organism organism)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, String fullName, Xref uniqueId)
Constructor for DefaultComplex.
-
DefaultComplex
public DefaultComplex(String name, Organism organism, Xref uniqueId)
Constructor for DefaultComplex.
-
-
Method Detail
-
initialiseAnnotations
protected void initialiseAnnotations()
initialiseAnnotations
- Overrides:
initialiseAnnotationsin classDefaultInteractor
-
initialiseChecksums
protected void initialiseChecksums()
initialiseChecksums
- Overrides:
initialiseChecksumsin classDefaultInteractor
-
initialiseAliases
protected void initialiseAliases()
initialiseAliases
- Overrides:
initialiseAliasesin classDefaultInteractor
-
initialiseXrefs
protected void initialiseXrefs()
initialiseXrefs
- Overrides:
initialiseXrefsin classDefaultInteractor
-
initialiseInteractionEvidences
protected void initialiseInteractionEvidences()
initialiseInteractionEvidences
-
initialiseInteractionEvidencesWith
protected void initialiseInteractionEvidencesWith(Collection<InteractionEvidence> interactionEvidences)
initialiseInteractionEvidencesWith
- Parameters:
interactionEvidences- aCollectionobject.
-
initialiseCooperativeEffects
protected void initialiseCooperativeEffects()
initialiseCooperativeEffects
-
initialiseCooperativeEffectsWith
protected void initialiseCooperativeEffectsWith(Collection<CooperativeEffect> cooperativeEffects)
initialiseCooperativeEffectsWith
- Parameters:
cooperativeEffects- aCollectionobject.
-
initialiseConfidences
protected void initialiseConfidences()
initialiseConfidences
-
initialiseConfidencesWith
protected void initialiseConfidencesWith(Collection<ModelledConfidence> confidences)
initialiseConfidencesWith
- Parameters:
confidences- aCollectionobject.
-
initialiseParameters
protected void initialiseParameters()
initialiseParameters
-
initialiseParametersWith
protected void initialiseParametersWith(Collection<ModelledParameter> parameters)
initialiseParametersWith
- Parameters:
parameters- aCollectionobject.
-
initialiseComponents
protected void initialiseComponents()
initialiseComponents
-
initialiseComponentsWith
protected void initialiseComponentsWith(Collection<ModelledParticipant> components)
initialiseComponentsWith
- Parameters:
components- aCollectionobject.
-
getSource
public Source getSource()
Getter for the field
source.- Specified by:
getSourcein interfaceModelledInteraction- Returns:
- a
Sourceobject.
-
setSource
public void setSource(Source source)
Sets the source reporting the interaction.- Specified by:
setSourcein interfaceModelledInteraction- Parameters:
source- : source for this interaction
-
getParticipants
public Collection<ModelledParticipant> getParticipants()
getParticipants
- Specified by:
getParticipantsin interfaceInteraction<ModelledParticipant>- Returns:
- a
Collectionobject.
-
addParticipant
public boolean addParticipant(ModelledParticipant part)
addParticipant
- Specified by:
addParticipantin interfaceInteraction<ModelledParticipant>- Parameters:
part- aModelledParticipantobject.- Returns:
- a boolean.
-
removeParticipant
public boolean removeParticipant(ModelledParticipant part)
removeParticipant
- Specified by:
removeParticipantin interfaceInteraction<ModelledParticipant>- Parameters:
part- aModelledParticipantobject.- Returns:
- a boolean.
-
addAllParticipants
public boolean addAllParticipants(Collection<? extends ModelledParticipant> participants)
This method will add all the participant and set the interaction of the new participant to this current interaction- Specified by:
addAllParticipantsin interfaceInteraction<ModelledParticipant>- Parameters:
participants- : participants to add- Returns:
- true if participant are added to the list of participants
-
removeAllParticipants
public boolean removeAllParticipants(Collection<? extends ModelledParticipant> participants)
This method will remove the participant and set the interaction of the removed participant to null.- Specified by:
removeAllParticipantsin interfaceInteraction<ModelledParticipant>- Parameters:
participants- : participants to remove- Returns:
- true if participant are removed from the list of participants
-
getInteractionEvidences
public Collection<InteractionEvidence> getInteractionEvidences()
Getter for the field
interactionEvidences.- Specified by:
getInteractionEvidencesin interfaceModelledInteraction- Returns:
- a
Collectionobject.
-
getModelledConfidences
public Collection<ModelledConfidence> getModelledConfidences()
getModelledConfidences
- Specified by:
getModelledConfidencesin interfaceModelledInteraction- Returns:
- a
Collectionobject.
-
getModelledParameters
public Collection<ModelledParameter> getModelledParameters()
getModelledParameters
- Specified by:
getModelledParametersin interfaceModelledInteraction- Returns:
- a
Collectionobject.
-
getCooperativeEffects
public Collection<CooperativeEffect> getCooperativeEffects()
Getter for the field
cooperativeEffects.- Specified by:
getCooperativeEffectsin interfaceModelledInteraction- Returns:
- a
Collectionobject.
-
getComplexAc
public String getComplexAc()
Complex accession if the complex has been curated under the Complex Portal curation rules. It can be null if the complex is not registered in the Complex Portal. This complex accession should be a shortcut to the complex-primary Xref in the collection of xrefs. Ex: CPX-123- Specified by:
getComplexAcin interfaceComplex- Returns:
- the complex accession
-
getComplexVersion
public String getComplexVersion()
Complex version if the complex has been curated under the Complex Portal curation rules. It can be null if the complex is not registered in the Complex Portal. This complex version should be a shortcut to the complex-primary Xref version in the collection of xrefs. Ex: 1- Specified by:
getComplexVersionin interfaceComplex- Returns:
- the complex version
-
assignComplexAc
public void assignComplexAc(String accession, String version)
Assign a complex accession to a complex. It will add the new complex-primary ref to the collection of xrefs- Specified by:
assignComplexAcin interfaceComplex- Parameters:
accession- : the complex accessionversion- : the version of the complex if it is provided. If version is null it will create the complex with version 1
-
assignComplexAc
public void assignComplexAc(String accession)
Assign a complex accession to a complex. It will add the new complex-primary ref to the collection of xrefs- Specified by:
assignComplexAcin interfaceComplex- Parameters:
accession- : the complex accession. If the version is added to the accession e.g. CPX-1234.2 the complex will be updated with the corresponding version, if not it is assumed version 1
-
getPhysicalProperties
public String getPhysicalProperties()
Getter for the field
physicalProperties.- Specified by:
getPhysicalPropertiesin interfaceComplex- Returns:
- a
Stringobject.
-
setPhysicalProperties
public void setPhysicalProperties(String properties)
Sets the physical properties of this complex. It will remove the old complex-properties annotation from the collection of annotations and replace it with the new complex-properties annotation. If the new complex-properties is null, all the existing complex-properties annotations will be removed from the collection of annotations- Specified by:
setPhysicalPropertiesin interfaceComplex- Parameters:
properties- : complex properties
-
getRecommendedName
public String getRecommendedName()
Getter for the field
recommendedName.- Specified by:
getRecommendedNamein interfaceComplex- Returns:
- a
Stringobject.
-
setRecommendedName
public void setRecommendedName(String name)
Sets the recommended name of this complex. It will remove the old recommended name from the collection of aliases and replace it with the new recommended name. If the new recommended name is null, all the existing recommended names will be removed from the collection of aliases- Specified by:
setRecommendedNamein interfaceComplex- Parameters:
name- : the recommended name
-
getSystematicName
public String getSystematicName()
Getter for the field
systematicName.- Specified by:
getSystematicNamein interfaceComplex- Returns:
- a
Stringobject.
-
setSystematicName
public void setSystematicName(String name)
Sets the systematic name of this complex. It will remove the old systematic name from the collection of aliases and replace it with the new systematic name. If the new systematic name is null, all the existing systematic names will be removed from the collection of aliases- Specified by:
setSystematicNamein interfaceComplex- Parameters:
name- : the systematic name
-
getEvidenceType
public CvTerm getEvidenceType()
Getter for the field
evidenceType.- Specified by:
getEvidenceTypein interfaceModelledInteraction- Returns:
- a
CvTermobject.
-
setEvidenceType
public void setEvidenceType(CvTerm eco)
Sets the evidence type- Specified by:
setEvidenceTypein interfaceModelledInteraction- Parameters:
eco- : the evidence type
-
setInteractorType
public void setInteractorType(CvTerm interactorType)
Sets the molecule type for this interactor If the given type is null, this method automatically sets the interactor type to 'unknown participant' (MI:0329)Sets the interactor type for this complex. If the given interactorType is null, it will set the interactor type to 'complex' (MI:0314)
- Specified by:
setInteractorTypein interfaceInteractor- Overrides:
setInteractorTypein classDefaultInteractor- Parameters:
interactorType- : molecule type
-
getRigid
public String getRigid()
Getter for the field
rigid.- Specified by:
getRigidin interfaceInteraction<ModelledParticipant>- Returns:
- a
Stringobject.
-
setRigid
public void setRigid(String rigid)
Sets the rigid of this interaction. It will remove the previous rigid from the list of checksum and add the new one. If rigid is null, it will remove all the rigid in the list of checksum- Specified by:
setRigidin interfaceInteraction<ModelledParticipant>- Parameters:
rigid- : the rigid
-
getUpdatedDate
public Date getUpdatedDate()
Getter for the field
updatedDate.- Specified by:
getUpdatedDatein interfaceInteraction<ModelledParticipant>- Returns:
- a
Dateobject.
-
setUpdatedDate
public void setUpdatedDate(Date updated)
Sets the last update date- Specified by:
setUpdatedDatein interfaceInteraction<ModelledParticipant>- Parameters:
updated- : last update date
-
getCreatedDate
public Date getCreatedDate()
Getter for the field
createdDate.- Specified by:
getCreatedDatein interfaceInteraction<ModelledParticipant>- Returns:
- a
Dateobject.
-
setCreatedDate
public void setCreatedDate(Date created)
Sets the created date- Specified by:
setCreatedDatein interfaceInteraction<ModelledParticipant>- Parameters:
created- : created date
-
getInteractionType
public CvTerm getInteractionType()
Getter for the field
interactionType.- Specified by:
getInteractionTypein interfaceInteraction<ModelledParticipant>- Returns:
- a
CvTermobject.
-
setInteractionType
public void setInteractionType(CvTerm term)
Sets the interaction type.- Specified by:
setInteractionTypein interfaceInteraction<ModelledParticipant>- Parameters:
term- : interaction type
-
getAnnotations
public Collection<Annotation> getAnnotations()
getAnnotations
- Specified by:
getAnnotationsin interfaceInteraction<ModelledParticipant>- Specified by:
getAnnotationsin interfaceInteractor- Overrides:
getAnnotationsin classDefaultInteractor- Returns:
- a
Collectionobject.
-
getChecksums
public Collection<Checksum> getChecksums()
getChecksums
- Specified by:
getChecksumsin interfaceInteraction<ModelledParticipant>- Specified by:
getChecksumsin interfaceInteractor- Overrides:
getChecksumsin classDefaultInteractor- Returns:
- a
Collectionobject.
-
getXrefs
public Collection<Xref> getXrefs()
getXrefs
- Specified by:
getXrefsin interfaceInteraction<ModelledParticipant>- Specified by:
getXrefsin interfaceInteractor- Overrides:
getXrefsin classDefaultInteractor- Returns:
- a
Collectionobject.
-
getIdentifiers
public Collection<Xref> getIdentifiers()
getIdentifiers
- Specified by:
getIdentifiersin interfaceInteraction<ModelledParticipant>- Specified by:
getIdentifiersin interfaceInteractor- Overrides:
getIdentifiersin classDefaultInteractor- Returns:
- a
Collectionobject.
-
getAliases
public Collection<Alias> getAliases()
getAliases
- Specified by:
getAliasesin interfaceInteractor- Specified by:
getAliasesin interfaceNamedInteraction<ModelledParticipant>- Overrides:
getAliasesin classDefaultInteractor- Returns:
- a
Collectionobject.
-
toString
public String toString()
- Overrides:
toStringin classDefaultInteractor
-
processAddedAnnotationEvent
protected void processAddedAnnotationEvent(Annotation added)
processAddedAnnotationEvent
- Parameters:
added- aAnnotationobject.
-
processRemovedAnnotationEvent
protected void processRemovedAnnotationEvent(Annotation removed)
processRemovedAnnotationEvent
- Parameters:
removed- aAnnotationobject.
-
clearPropertiesLinkedToAnnotations
protected void clearPropertiesLinkedToAnnotations()
clearPropertiesLinkedToAnnotations
-
processAddedChecksumEvent
protected void processAddedChecksumEvent(Checksum added)
processAddedChecksumEvent
- Parameters:
added- aChecksumobject.
-
processRemovedChecksumEvent
protected void processRemovedChecksumEvent(Checksum removed)
processRemovedChecksumEvent
- Parameters:
removed- aChecksumobject.
-
clearPropertiesLinkedToChecksums
protected void clearPropertiesLinkedToChecksums()
clearPropertiesLinkedToChecksums
-
processAddedAliasEvent
protected void processAddedAliasEvent(Alias added)
processAddedAliasEvent
- Parameters:
added- aAliasobject.
-
processRemovedAliasEvent
protected void processRemovedAliasEvent(Alias removed)
processRemovedAliasEvent
- Parameters:
removed- aAliasobject.
-
clearPropertiesLinkedToAliases
protected void clearPropertiesLinkedToAliases()
clearPropertiesLinkedToAliases
-
processAddedXrefEvent
protected void processAddedXrefEvent(Xref added)
processAddedXrefEvent
- Parameters:
added- aXrefobject.
-
processRemovedXrefEvent
protected void processRemovedXrefEvent(Xref removed)
processRemovedXrefEvent
- Parameters:
removed- aXrefobject.
-
clearPropertiesLinkedToXrefs
protected void clearPropertiesLinkedToXrefs()
-
-