Skip to content
Snippets Groups Projects
Commit c25c9b65 authored by langella's avatar langella
Browse files

new interface for DataSource

git-svn-id: https://subversion.renater.fr/xtandempipeline/trunk@193 b8ef2a07-7df7-436f-90b9-41648038564b
parent ac00841b
No related branches found
No related tags found
No related merge requests found
......@@ -2,8 +2,12 @@ package fr.inra.pappso.xtandempipeline.class_msms.IdentificationDataFile;
import java.io.File;
public class IdentificationDataFile implements
Comparable<IdentificationDataFile> {
import javax.xml.stream.XMLStreamWriter;
import fr.inra.pappso.xtandempipeline.class_msms.Identification;
public abstract class IdentificationDataFile implements
Comparable<IdentificationDataFile>, IdentificationDataSource {
protected File file = null;
......@@ -12,6 +16,7 @@ public class IdentificationDataFile implements
return new IdentificationXtandemFile(file);
}
@Override
public String getName() {
return this.file.getName();
}
......@@ -33,4 +38,12 @@ public class IdentificationDataFile implements
return this.file.compareTo(toCompare.file);
}
@Override
abstract public Identification loadIdentification(
Identification previousIdentification);
@Override
abstract public void writeXpipPeptideSourceAttribute(XMLStreamWriter writer)
throws Exception;
}
package fr.inra.pappso.xtandempipeline.class_msms.IdentificationDataFile;
import javax.xml.stream.XMLStreamWriter;
import fr.inra.pappso.xtandempipeline.class_msms.Identification;
public interface IdentificationDataSource {
public String getName();
public Identification loadIdentification(
Identification previousIdentification);
public void writeXpipPeptideSourceAttribute(XMLStreamWriter writer)
throws Exception;
}
package fr.inra.pappso.xtandempipeline.class_msms.IdentificationDataFile;
import java.io.File;
import javax.xml.stream.XMLStreamWriter;
import fr.inra.pappso.xtandempipeline.class_msms.Identification;
public class IdentificationMascotFile extends IdentificationDataFile {
public IdentificationMascotFile(File mascotFile) {
this.file = mascotFile;
}
@Override
public Identification loadIdentification(
Identification previousIdentification) {
// TODO Auto-generated method stub
return null;
}
@Override
public void writeXpipPeptideSourceAttribute(XMLStreamWriter writer)
throws Exception {
// TODO Auto-generated method stub
}
}
......@@ -2,9 +2,27 @@ package fr.inra.pappso.xtandempipeline.class_msms.IdentificationDataFile;
import java.io.File;
import javax.xml.stream.XMLStreamWriter;
import fr.inra.pappso.xtandempipeline.class_msms.Identification;
public class IdentificationXtandemFile extends IdentificationDataFile {
public IdentificationXtandemFile (File xtandemFile) {
this.file = xtandemFile;
}
@Override
public Identification loadIdentification(
Identification previousIdentification) {
// TODO Auto-generated method stub
return null;
}
@Override
public void writeXpipPeptideSourceAttribute(XMLStreamWriter writer)
throws Exception {
// TODO Auto-generated method stub
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment