use of org.eclipse.tracecompass.tmf.core.trace.indexer.checkpoint.TmfCheckpointIndexer in project tracecompass by tracecompass.
the class Uml2SDTestFacility method selectExperiment.
/**
* Selects the experiment.
* @param wait true to wait for indexing to finish else false
*/
public void selectExperiment(final boolean wait) {
TmfUml2SDTestTrace parser = new TmfUml2SDTestTrace();
ITmfTrace trace = setupTrace(parser);
parser.setTrace(trace);
final ITmfTrace[] traces = new ITmfTrace[] { trace };
fExperiment = new TmfExperiment(ITmfEvent.class, "TestExperiment", traces, TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null) {
@Override
protected ITmfTraceIndexer createIndexer(int interval) {
return new TmfCheckpointIndexer(this, interval);
}
};
trace.broadcast(new TmfTraceOpenedSignal(this, fExperiment, null));
trace.broadcast(new TmfTraceSelectedSignal(this, fExperiment));
if (wait) {
while (fExperiment.getNbEvents() == 0) {
delay(IUml2SDTestConstants.GUI_REFESH_DELAY);
}
waitForJobs();
delay(IUml2SDTestConstants.GUI_REFESH_DELAY);
}
}
Aggregations