- java.lang.Object
-
- psidev.psi.mi.jami.enricher.impl.minimal.MinimalEntityEnricher<P,F>
-
- All Implemented Interfaces:
EntityEnricher<P,F>
,MIEnricher<P>
- Direct Known Subclasses:
FullEntityEnricher
,MinimalEntityUpdater
,MinimalParticipantEnricher
public class MinimalEntityEnricher<P extends Entity,F extends Feature> extends Object implements EntityEnricher<P,F>
The entity enricher is an enricher which can enrich either single participant or a collection. The entity enricher has subEnrichers and no fetchers.- Since:
- 19/06/13
- Author:
- Gabriel Aldam (galdam@ebi.ac.uk)
-
-
Constructor Summary
Constructors Constructor Description MinimalEntityEnricher()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
enrich(Collection<P> participantsToEnrich)
enrich.void
enrich(P participantToEnrich)
enrich.void
enrich(P objectToEnrich, P objectSource)
enrich.FeatureEnricher<F>
getFeatureEnricher()
The current enricher used for features.CompositeInteractorEnricher
getInteractorEnricher()
Getter for the fieldinteractorEnricher
.EntityEnricherListener
getParticipantEnricherListener()
The current listener that participant changes are reported to.protected void
processFeatures(P participantToEnrich)
processFeatures.void
processFeatures(P objectToEnrich, P objectSource)
processFeatures.protected void
processInteractor(P participantToEnrich)
processInteractor.void
processInteractor(P objectToEnrich, P objectSource)
processInteractor.void
processOtherProperties(P participantToEnrich)
processOtherProperties.void
processOtherProperties(P objectToEnrich, P objectSource)
processOtherProperties.void
setFeatureEnricher(FeatureEnricher<F> featureEnricher)
setFeatureEnricher.void
setInteractorEnricher(CompositeInteractorEnricher interactorEnricher)
setInteractorEnricher.void
setParticipantEnricherListener(EntityEnricherListener listener)
setParticipantEnricherListener.
-
-
-
Method Detail
-
enrich
public void enrich(Collection<P> participantsToEnrich) throws EnricherException
enrich.
- Specified by:
enrich
in interfaceMIEnricher<P extends Entity>
- Parameters:
participantsToEnrich
- aCollection
object.- Throws:
EnricherException
- if any.
-
enrich
public void enrich(P objectToEnrich, P objectSource) throws EnricherException
enrich.
- Specified by:
enrich
in interfaceMIEnricher<P extends Entity>
- Parameters:
objectToEnrich
- a P object.objectSource
- a P object.- Throws:
EnricherException
- if any.
-
enrich
public void enrich(P participantToEnrich) throws EnricherException
enrich.
- Specified by:
enrich
in interfaceMIEnricher<P extends Entity>
- Parameters:
participantToEnrich
- a P object.- Throws:
EnricherException
- if any.
-
processOtherProperties
public void processOtherProperties(P objectToEnrich, P objectSource) throws EnricherException
processOtherProperties.
- Parameters:
objectToEnrich
- a P object.objectSource
- a P object.- Throws:
EnricherException
- if any.
-
processInteractor
public void processInteractor(P objectToEnrich, P objectSource) throws EnricherException
processInteractor.
- Parameters:
objectToEnrich
- a P object.objectSource
- a P object.- Throws:
EnricherException
- if any.
-
processFeatures
public void processFeatures(P objectToEnrich, P objectSource) throws EnricherException
processFeatures.
- Parameters:
objectToEnrich
- a P object.objectSource
- a P object.- Throws:
EnricherException
- if any.
-
processOtherProperties
public void processOtherProperties(P participantToEnrich) throws EnricherException
processOtherProperties.
- Parameters:
participantToEnrich
- a P object.- Throws:
EnricherException
- if any.
-
processFeatures
protected void processFeatures(P participantToEnrich) throws EnricherException
processFeatures.
- Parameters:
participantToEnrich
- a P object.- Throws:
EnricherException
- if any.
-
processInteractor
protected void processInteractor(P participantToEnrich) throws EnricherException
processInteractor.
- Parameters:
participantToEnrich
- a P object.- Throws:
EnricherException
- if any.
-
setParticipantEnricherListener
public void setParticipantEnricherListener(EntityEnricherListener listener)
setParticipantEnricherListener.
Sets the listener for Participant events. If null, events will not be reported.- Specified by:
setParticipantEnricherListener
in interfaceEntityEnricher<P extends Entity,F extends Feature>
- Parameters:
listener
- aEntityEnricherListener
object.
-
getParticipantEnricherListener
public EntityEnricherListener getParticipantEnricherListener()
The current listener that participant changes are reported to. If null, events are not being reported.- Specified by:
getParticipantEnricherListener
in interfaceEntityEnricher<P extends Entity,F extends Feature>
- Returns:
- TThe current listener. Can be null.
-
setFeatureEnricher
public void setFeatureEnricher(FeatureEnricher<F> featureEnricher)
setFeatureEnricher.
Will attempt to add the featureEnricher as a proteinListener if this is valid. If the proteinEnricher already has a listener, this will be preserved using a listener manager.- Specified by:
setFeatureEnricher
in interfaceEntityEnricher<P extends Entity,F extends Feature>
- Parameters:
featureEnricher
- aFeatureEnricher
object.
-
getFeatureEnricher
public FeatureEnricher<F> getFeatureEnricher()
The current enricher used for features. If null, features are not currently being enriched.- Specified by:
getFeatureEnricher
in interfaceEntityEnricher<P extends Entity,F extends Feature>
- Returns:
- The current enricher. May be null.
-
setInteractorEnricher
public void setInteractorEnricher(CompositeInteractorEnricher interactorEnricher)
setInteractorEnricher.
- Specified by:
setInteractorEnricher
in interfaceEntityEnricher<P extends Entity,F extends Feature>
- Parameters:
interactorEnricher
- aCompositeInteractorEnricher
object.
-
getInteractorEnricher
public CompositeInteractorEnricher getInteractorEnricher()
Getter for the field
interactorEnricher
.- Specified by:
getInteractorEnricher
in interfaceEntityEnricher<P extends Entity,F extends Feature>
- Returns:
- a
CompositeInteractorEnricher
object.
-
-