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

force instanciation of MsRun throught MsRunSet

git-svn-id: https://subversion.renater.fr/xtandempipeline/trunk@336 b8ef2a07-7df7-436f-90b9-41648038564b
parent 1c443540
No related branches found
No related tags found
No related merge requests found
......@@ -14,7 +14,7 @@ public class MsRun implements GrpMsSample {
private HashSet<IdentificationDataSource> files = new HashSet<IdentificationDataSource>(
0);
public MsRun(String sample_name) {
protected MsRun(String sample_name) {
logger.debug("MsRun begin "+sample_name);
sampleName = sample_name;
......
......@@ -4,6 +4,7 @@ import java.util.ArrayList;
import java.util.Vector;
import fr.inra.pappso.xtandempipeline.XtandemPipelineSession;
import fr.inra.pappso.xtandempipeline.MsException.MSMSException;
import fr.inra.pappso.xtandempipeline.MsException.StopException;
import fr.inra.pappso.xtandempipeline.class_msms.MsRun;
import fr.inra.pappso.xtandempipeline.class_msms.MsRunSet;
......@@ -37,29 +38,36 @@ public class individual extends process {
// Ecrire le process et penser à relever des StopException
for (int i = 0; i < dataSources.size(); i++) {
// parsing
this.set_view("Analysing file : " + (i + 1) + "/" + dataSources.size()
+ "\n" + "Parsing file : " + dataSources.get(i).getName());
this.set_view("Analysing file : " + (i + 1) + "/"
+ dataSources.size() + "\n" + "Parsing file : "
+ dataSources.get(i).getName());
// Is sample exist? Get previous identification
Identification identtemp = null;
for (int m = 0; m < identifications.size(); m++) {
MsRunSet samples = identifications.get(m).get_samples();
MsRun test = new MsRun(dataSources.get(i).getName());
MsRun test = samples.getInstance(dataSources.get(i));
if (test == null) {
String message = "MsRun test is null";
logger.error(message);
throw new MSMSException(message);
}
if (samples.contains(test))
identtemp = identifications.get(m);
}
//xtandem handler;
//if (identtemp != null)
// handler = new xtandem(identtemp, dataSources.get(i));
//else
// handler = new xtandem(dataSources.get(i));
//new parse_file(handler, dataSources.get(i).);
// xtandem handler;
// if (identtemp != null)
// handler = new xtandem(identtemp, dataSources.get(i));
// else
// handler = new xtandem(dataSources.get(i));
// new parse_file(handler, dataSources.get(i).);
//
//if (identtemp == null)
// identifications.add(handler.get_identifications());
//Load identification from datasource
identifications.add(dataSources.get(i).loadIdentification(identtemp));
// if (identtemp == null)
// identifications.add(handler.get_identifications());
// Load identification from datasource
identifications.add(dataSources.get(i)
.loadIdentification(identtemp));
// verification pas arreté
if (this.isStop())
......
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