1 /*******************************************************************************
2 * Copyright (c) 2013 École Polytechnique de Montréal
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
10 * Geneviève Bastien - Initial API and implementation
11 *******************************************************************************/
13 package org
.eclipse
.linuxtools
.tmf
.core
.analysis
;
15 import org
.eclipse
.linuxtools
.tmf
.core
.exceptions
.TmfAnalysisException
;
16 import org
.eclipse
.linuxtools
.tmf
.core
.trace
.ITmfTrace
;
17 import org
.osgi
.framework
.Bundle
;
20 * Interface for modules helpers that provide basic module information and
21 * creates module from a source when requested.
23 * @author Geneviève Bastien
26 public interface IAnalysisModuleHelper
{
28 // ------------------------------------
30 // ------------------------------------
33 * Gets the id of the analysis module
35 * @return The id of the module
40 * Gets the name of the analysis module
42 * @return The id of the module
47 * Gets whether the analysis should be run automatically at trace opening
49 * @return true if analysis is to be run automatically
51 boolean isAutomatic();
54 * Gets a generic help message/documentation for this analysis module
56 * This help text will be displayed to the user and may contain information
57 * on what the module does, how to use it and how to correctly generate the
58 * trace to make it available
60 * TODO: Help texts could be quite long. They should reside in their own
61 * file and be accessed either with text, for a command line man page, or
62 * through the eclipse help context. There should be a custom way to make it
63 * available through the helper, without instantiating the analysis, though
64 * help text after analysis instantiation may be richer.
66 * @return The generic help text
71 * Gets the icon for this module
73 * @return The icon path
78 * Gets the bundle this analysis module is part of
85 * Does an analysis apply to a given trace type (otherwise, it is not shown)
88 * The trace to analyze
89 * @return whether the analysis applies
91 boolean appliesToTraceType(Class
<?
extends ITmfTrace
> traceclass
);
93 // ---------------------------------------
95 // ---------------------------------------
98 * Creates a new instance of the {@link IAnalysisModule} represented by this
99 * helper and initializes it with the trace.
102 * The trace to be linked to the module
103 * @return A new {@link IAnalysisModule} instance initialized with the
105 * @throws TmfAnalysisException
106 * Exceptions that occurred when setting trace
108 IAnalysisModule
newModule(ITmfTrace trace
) throws TmfAnalysisException
;
This page took 0.037598 seconds and 6 git commands to generate.