Fix some null warnings
[deliverable/tracecompass.git] / tmf / org.eclipse.tracecompass.tmf.core / src / org / eclipse / tracecompass / tmf / core / trace / ITmfTraceWithPreDefinedEvents.java
CommitLineData
409bea20
GB
1/*******************************************************************************
2 * Copyright (c) 2014 École Polytechnique de Montréal, Ericsson
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 * Contributors:
10 * Geneviève Bastien - Initial API and implementation
11 * Matthew Khouzam - Initial API and implementation
12 *******************************************************************************/
13
2bdf0193 14package org.eclipse.tracecompass.tmf.core.trace;
409bea20
GB
15
16import java.util.Set;
17
df2597e0 18import org.eclipse.jdt.annotation.NonNullByDefault;
2bdf0193 19import org.eclipse.tracecompass.tmf.core.event.ITmfEventType;
409bea20
GB
20
21/**
22 * This interface should be implemented by all trace classes who have a way to
23 * know in advance what events it may contain. It allows analyses and other
24 * external components to ask the list of events for the trace might contain.
25 *
26 * The methods from this interface will typically be called to determine whether
27 * or not it is worth reading a trace. If we can know in advance that a trace
28 * does not contain the events required by an analysis, then the analysis will
29 * not be run. So the response should not involve having to actually read the
30 * trace.
31 *
32 * @author Geneviève Bastien
33 * @author Matthew Khouzam
409bea20 34 */
df2597e0 35@NonNullByDefault
409bea20
GB
36public interface ITmfTraceWithPreDefinedEvents {
37
38 /**
39 * Return a set of event types declared in the trace, without actually
40 * reading the trace. This method can be called before reading a trace but
41 * after it is initialized, in order to compare this set with a set of
42 * events that a request handles, to determine whether or not it is worth
43 * reading the trace.
44 *
45 * Some trace types have ways to determine the events that were traced
46 * without having to read the whole trace and this is what this method will
47 * query. The presence of an event in the returned set does not guarantee
48 * that an event with this name actually happened during this trace, only
49 * that it can be there.
50 *
51 * The set should be immutable. Destructive set operations should be
52 * performed on a copy of this set.A helper class
53 * {@link TmfEventTypeCollectionHelper} will provide ways of working with
54 * this data structure.
55 *
56 * @return The set of events that might be present in the trace
57 */
e600c338 58 Set<? extends ITmfEventType> getContainedEventTypes();
409bea20
GB
59
60}
This page took 0.05681 seconds and 5 git commands to generate.