ss: Fix some tests's copyright header
[deliverable/tracecompass.git] / statesystem / org.eclipse.tracecompass.statesystem.core.tests / src / org / eclipse / tracecompass / statesystem / core / tests / backend / ThreadedHistoryTreeBackendTest.java
CommitLineData
60cabb56 1/*******************************************************************************
b9d50127 2 * Copyright (c) 2016 Ericsson and others
60cabb56
PT
3 *
4 * All rights reserved. This program and the accompanying materials are
5 * made available under the terms of the Eclipse Public License v1.0 which
6 * accompanies this distribution, and is available at
7 * http://www.eclipse.org/legal/epl-v10.html
8 *******************************************************************************/
9
10package org.eclipse.tracecompass.statesystem.core.tests.backend;
11
12import java.io.File;
13import java.io.IOException;
14
15import org.eclipse.tracecompass.internal.statesystem.core.backend.historytree.ThreadedHistoryTreeBackend;
16import org.eclipse.tracecompass.statesystem.core.backend.IStateHistoryBackend;
17
18/**
19 * Test the {@link ThreadedHistoryTreeBackend} class.
20 *
21 * @author Patrick Tasse
60cabb56
PT
22 */
23public class ThreadedHistoryTreeBackendTest extends HistoryTreeBackendTest {
24
25 private static final int QUEUE_SIZE = 10;
26
27 /**
28 * Constructor
29 *
30 * @param reOpen
31 * True if the backend should be disposed and re-opened as a new
32 * backend from the file, or false to use the backend as-is
33 */
34 public ThreadedHistoryTreeBackendTest(Boolean reOpen) {
35 super(reOpen);
36 }
37
38 @Override
39 protected IStateHistoryBackend getBackendForBuilding(long startTime) throws IOException {
40 File historyTreeFile = File.createTempFile("ThreadedHistoryTreeBackendTest", ".ht");
41 fHistoryTreeFiles.add(historyTreeFile);
42 ThreadedHistoryTreeBackend backend = new ThreadedHistoryTreeBackend(SSID, historyTreeFile, PROVIDER_VERSION, startTime, QUEUE_SIZE, fBlockSize, fMaxChildren);
43 fBackendMap.put(backend, historyTreeFile);
44 return backend;
45 }
46}
This page took 0.028488 seconds and 5 git commands to generate.