Class AbstractMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>
- java.lang.Object
-
- psidev.psi.mi.jami.tab.io.writer.feeder.AbstractMitabColumnFeeder<T,P>
-
- All Implemented Interfaces:
MitabColumnFeeder<T,P>
- Direct Known Subclasses:
DefaultMitabColumnFeeder,MitabInteractionEvidenceFeeder,MitabModelledInteractionFeeder
public abstract class AbstractMitabColumnFeeder<T extends BinaryInteraction,P extends Participant> extends Object implements MitabColumnFeeder<T,P>
Abstract Mitab 2.5 column feeder- Since:
20/06/13
- Version:
- $Id$
- Author:
- Marine Dumousseau (marine@ebi.ac.uk)
-
-
Constructor Summary
Constructors Constructor Description AbstractMitabColumnFeeder(Writer writer)Constructor for AbstractMitabColumnFeeder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidescapeAndWriteString(String stringToEscape)This method replaces line breaks and tab characters with a space.protected WritergetWriter()Getter for the fieldwriter.voidwriteAlias(Alias alias)This methods write the dbsource, alias name and alias type of an aliasvoidwriteAliases(P participant)writeAliases.voidwriteAlternativeIdentifiers(P participant)writeAlternativeIdentifiers.voidwriteAnnotation(Annotation annotation)Writes an annotationvoidwriteBiologicalRole(P participant)writeBiologicalRole.voidwriteChecksum(Checksum checksum)Writes the checksumvoidwriteComplexExpansion(T binary)writeComplexExpansion.voidwriteConfidence(Confidence conf)This method will write a confidence with a text if text is not nullvoidwriteCvTerm(CvTerm cv)Write the CvTerm.protected voidwriteCvTermName(CvTerm cv)Write full name if not null, otherwise write shortnamevoidwriteDate(Date date)Writes created date of an interactionvoidwriteFeature(Feature feature)Writes a featurevoidwriteIdentifier(Xref identifier)This methods write the database, id and version of an identifiervoidwriteInteractionCausalRegulatoryMechanism(T interaction)writeInteractionType.voidwriteInteractionCausalStatement(T interaction)writeInteractionType.voidwriteInteractionChecksums(T interaction)writeInteractionChecksums.voidwriteInteractionType(T interaction)writeInteractionType.voidwriteInteractorOrganism(P participant)writeInteractorOrganism.voidwriteInteractorType(P participant)writeInteractorType.voidwriteOrganism(Organism organism)Write an organism.voidwriteParameter(Parameter parameter)Writes the parametervoidwriteParticipantAnnotations(P participant)writeParticipantAnnotations.voidwriteParticipantBiologicalEffect(P participant)writeBiologicalRole.voidwriteParticipantChecksums(P participant)writeParticipantChecksums.voidwriteParticipantFeatures(P participant)writeParticipantFeatures.voidwriteParticipantStoichiometry(P participant)writeParticipantStoichiometry.voidwriteParticipantXrefs(P participant)writeParticipantXrefs.voidwriteUniqueIdentifier(P participant)writeUniqueIdentifier.voidwriteXref(Xref xref)This methods write the database, id, version and qualifier of an xref-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface psidev.psi.mi.jami.tab.io.writer.feeder.MitabColumnFeeder
writeAlias, writeExperimentalRole, writeFirstAuthor, writeHostOrganism, writeInteractionAnnotations, writeInteractionConfidences, writeInteractionDetectionMethod, writeInteractionIdentifiers, writeInteractionParameters, writeInteractionXrefs, writeNegativeProperty, writeParticipantIdentificationMethod, writePublicationIdentifiers, writeSource
-
-
-
-
Method Detail
-
writeUniqueIdentifier
public void writeUniqueIdentifier(P participant) throws IOException
writeUniqueIdentifier.
- Specified by:
writeUniqueIdentifierin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeAlternativeIdentifiers
public void writeAlternativeIdentifiers(P participant) throws IOException
writeAlternativeIdentifiers.
- Specified by:
writeAlternativeIdentifiersin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeAliases
public void writeAliases(P participant) throws IOException
writeAliases.
- Specified by:
writeAliasesin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeInteractorOrganism
public void writeInteractorOrganism(P participant) throws IOException
writeInteractorOrganism.
- Specified by:
writeInteractorOrganismin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeInteractionType
public void writeInteractionType(T interaction) throws IOException
writeInteractionType.
- Specified by:
writeInteractionTypein interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
interaction- a T object.- Throws:
IOException- if any.
-
writeConfidence
public void writeConfidence(Confidence conf) throws IOException
This method will write a confidence with a text if text is not null- Specified by:
writeConfidencein interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
conf- aConfidenceobject.- Throws:
IOException- if any.
-
writeParameter
public void writeParameter(Parameter parameter) throws IOException
Writes the parameter- Specified by:
writeParameterin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
parameter- aParameterobject.- Throws:
IOException- if any.
-
writeOrganism
public void writeOrganism(Organism organism) throws IOException
Write an organism. Will duplicate taxid if needs to provide both common name and scientific name- Specified by:
writeOrganismin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
organism- aOrganismobject.- Throws:
IOException- if any.
-
writeCvTerm
public void writeCvTerm(CvTerm cv) throws IOException
Write the CvTerm. If it is null, it writes an empty column (-)- Specified by:
writeCvTermin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
cv- aCvTermobject.- Throws:
IOException- if any.
-
writeAlias
public void writeAlias(Alias alias) throws IOException
This methods write the dbsource, alias name and alias type of an alias- Specified by:
writeAliasin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
alias- aAliasobject.- Throws:
IOException- if any.
-
writeIdentifier
public void writeIdentifier(Xref identifier) throws IOException
This methods write the database, id and version of an identifier- Specified by:
writeIdentifierin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
identifier- aXrefobject.- Throws:
IOException- if any.
-
escapeAndWriteString
public void escapeAndWriteString(String stringToEscape) throws IOException
This method replaces line breaks and tab characters with a space. It escapes the StringToEscape with doble quote if it finds a special MITAB character- Specified by:
escapeAndWriteStringin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
stringToEscape- aStringobject.- Throws:
IOException- if any.
-
writeComplexExpansion
public void writeComplexExpansion(T binary) throws IOException
writeComplexExpansion.
- Specified by:
writeComplexExpansionin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
binary- a T object.- Throws:
IOException- if any.
-
writeBiologicalRole
public void writeBiologicalRole(P participant) throws IOException
writeBiologicalRole.
- Specified by:
writeBiologicalRolein interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeInteractorType
public void writeInteractorType(P participant) throws IOException
writeInteractorType.
- Specified by:
writeInteractorTypein interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeParticipantXrefs
public void writeParticipantXrefs(P participant) throws IOException
writeParticipantXrefs.
- Specified by:
writeParticipantXrefsin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeParticipantAnnotations
public void writeParticipantAnnotations(P participant) throws IOException
writeParticipantAnnotations.
- Specified by:
writeParticipantAnnotationsin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeDate
public void writeDate(Date date) throws IOException
Writes created date of an interaction- Specified by:
writeDatein interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
date- aDateobject.- Throws:
IOException- if any.
-
writeParticipantChecksums
public void writeParticipantChecksums(P participant) throws IOException
writeParticipantChecksums.
- Specified by:
writeParticipantChecksumsin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeInteractionChecksums
public void writeInteractionChecksums(T interaction) throws IOException
writeInteractionChecksums.
- Specified by:
writeInteractionChecksumsin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
interaction- a T object.- Throws:
IOException- if any.
-
writeChecksum
public void writeChecksum(Checksum checksum) throws IOException
Writes the checksum- Specified by:
writeChecksumin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
checksum- aChecksumobject.- Throws:
IOException- if any.
-
writeAnnotation
public void writeAnnotation(Annotation annotation) throws IOException
Writes an annotation- Specified by:
writeAnnotationin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
annotation- aAnnotationobject.- Throws:
IOException- if any.
-
writeXref
public void writeXref(Xref xref) throws IOException
This methods write the database, id, version and qualifier of an xref- Specified by:
writeXrefin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
xref- aXrefobject.- Throws:
IOException- if any.
-
writeParticipantFeatures
public void writeParticipantFeatures(P participant) throws IOException
writeParticipantFeatures.
- Specified by:
writeParticipantFeaturesin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeParticipantStoichiometry
public void writeParticipantStoichiometry(P participant) throws IOException
writeParticipantStoichiometry.
- Specified by:
writeParticipantStoichiometryin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeFeature
public void writeFeature(Feature feature) throws IOException
Writes a feature- Specified by:
writeFeaturein interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
feature- aFeatureobject.- Throws:
IOException- if any.
-
writeParticipantBiologicalEffect
public void writeParticipantBiologicalEffect(P participant) throws IOException
writeBiologicalRole.
- Specified by:
writeParticipantBiologicalEffectin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
participant- a P object.- Throws:
IOException- if any.
-
writeInteractionCausalRegulatoryMechanism
public void writeInteractionCausalRegulatoryMechanism(T interaction) throws IOException
writeInteractionType.
- Specified by:
writeInteractionCausalRegulatoryMechanismin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
interaction- a T object.- Throws:
IOException- if any.
-
writeInteractionCausalStatement
public void writeInteractionCausalStatement(T interaction) throws IOException
writeInteractionType.
- Specified by:
writeInteractionCausalStatementin interfaceMitabColumnFeeder<T extends BinaryInteraction,P extends Participant>- Parameters:
interaction- a T object.- Throws:
IOException- if any.
-
writeCvTermName
protected void writeCvTermName(CvTerm cv) throws IOException
Write full name if not null, otherwise write shortname- Parameters:
cv- aCvTermobject.- Throws:
IOException- if any.
-
-