Traceability

tte.impl
Class Engine

java.lang.Object
  extended by tte.impl.Engine
All Implemented Interfaces:
IEngine

public class Engine
extends java.lang.Object
implements IEngine


Field Summary
static java.lang.String ANALYZER_EXT_POINT_ID
          id of the documentAnalyzers extension point.
static java.lang.String DEFAULT_ANALYZER_DEFAULT_CONVERSION_METHOD_ID
          id of the default conversion method of the default documentAnalyzers extension.
static java.lang.String DEFAULT_ANALYZER_DEFAULT_EDITION_METHOD_ID
          id of the default edition method of the default documentAnalyzers extension.
static java.lang.String DEFAULT_ANALYZER_ID
          id of the default documentAnalyzers extension.
 
Constructor Summary
Engine()
          Creates a new instance of Engine.
 
Method Summary
static void cleanCachedElements()
          Cleans static elements that are in cache.
 void editElement(Element element)
           
static ExtendedAnalyzer[] getAnalyzers()
          Gets analyzers from extensions to DocumentAnalyzer extension point.
static ExtendedAnalyzer getAnalyzerWithID(java.lang.String anID)
          Gets analyzer from extensions to DocumentAnalyzer extension point which id is given in parameter.
 java.lang.String getProjectFilename()
           
static ExtendedRule[] getRules(Project aProject)
          gets the rules availables from extensions to RulesSet extension point and add them to the project rule definition.
 void newProject(java.lang.String filename)
          Creates a new project in the filename passed in parameter.
 void newProjectWithOverwrite(java.lang.String filename)
           
 void printReport(Project aProject, java.lang.String outputFileStr)
          
 void printRulesReport(Project aProject, java.lang.String outputFileStr)
          
 void reloadProject(Project aProject)
          
 void reloadProjectForcing(Project aProject, java.lang.Boolean update)
          
static java.util.Map<java.lang.String,java.lang.Object> ttmMap()
          Gets the Map needed for the emf xml saved format.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ANALYZER_EXT_POINT_ID

public static final java.lang.String ANALYZER_EXT_POINT_ID
id of the documentAnalyzers extension point.

See Also:
Constant Field Values

DEFAULT_ANALYZER_ID

public static final java.lang.String DEFAULT_ANALYZER_ID
id of the default documentAnalyzers extension.

See Also:
Constant Field Values

DEFAULT_ANALYZER_DEFAULT_CONVERSION_METHOD_ID

public static final java.lang.String DEFAULT_ANALYZER_DEFAULT_CONVERSION_METHOD_ID
id of the default conversion method of the default documentAnalyzers extension.

See Also:
Constant Field Values

DEFAULT_ANALYZER_DEFAULT_EDITION_METHOD_ID

public static final java.lang.String DEFAULT_ANALYZER_DEFAULT_EDITION_METHOD_ID
id of the default edition method of the default documentAnalyzers extension.

See Also:
Constant Field Values
Constructor Detail

Engine

public Engine()
Creates a new instance of Engine.

Method Detail

ttmMap

public static java.util.Map<java.lang.String,java.lang.Object> ttmMap()
Gets the Map needed for the emf xml saved format.

Returns:
the Map needed for the emf xml saved format

cleanCachedElements

public static void cleanCachedElements()
Cleans static elements that are in cache.


getProjectFilename

public final java.lang.String getProjectFilename()
Specified by:
getProjectFilename in interface IEngine
Returns:
the filename of the last loaded project
See Also:
IEngine.getProjectFilename()

newProject

public final void newProject(java.lang.String filename)
                      throws ProjectFileAlreadyDefinedException,
                             CannotCreateProjectFileException
Creates a new project in the filename passed in parameter.

Specified by:
newProject in interface IEngine
Parameters:
filename - that will contain the traceability project structure
Throws:
ProjectFileAlreadyDefinedException - indicates the project that the user want to create already exists
CannotCreateProjectFileException - indicates that an exception occured during the project creation
See Also:
IEngine.newProject(java.lang.String)

newProjectWithOverwrite

public final void newProjectWithOverwrite(java.lang.String filename)
                                   throws ProjectFileAlreadyDefinedException,
                                          CannotCreateProjectFileException
Specified by:
newProjectWithOverwrite in interface IEngine
Parameters:
filename - that will contain the traceability project structure
Throws:
ProjectFileAlreadyDefinedException - indicates the project that the user want to create already exists
CannotCreateProjectFileException - indicates that an exception occured during the project creation
See Also:
{@inheritDoc}

reloadProject

public final void reloadProject(Project aProject)
                         throws FilesNeedToBeReloadException,
                                ResourceLoadingException,
                                MustBeTTMKindFileException,
                                AnalysisException

Specified by:
reloadProject in interface IEngine
Throws:
FilesNeedToBeReloadException - indicates that some files in project have changed since the last reloading action
ResourceLoadingException - indicates the loading of resource failed
MustBeTTMKindFileException - indicates that the extension of filename in parameter is wrong
AnalysisException - indicates that exceptions occured during project analysis
See Also:
tte.IEngine#reloadProject(java.lang.String)

reloadProjectForcing

public final void reloadProjectForcing(Project aProject,
                                       java.lang.Boolean update)
                                throws ResourceLoadingException,
                                       MustBeTTMKindFileException,
                                       AnalysisException

Specified by:
reloadProjectForcing in interface IEngine
update - boolean indicates if the user want to update modified file during reloading action
Throws:
ResourceLoadingException - indicates the loading of resource failed
MustBeTTMKindFileException - indicates that the extension of filename in parameter is wrong
AnalysisException - indicates that exceptions occured during project analysis
See Also:
tte.IEngine#reloadProjectForcing(java.lang.String, java.lang.Boolean)

editElement

public final void editElement(Element element)
                       throws EditionException,
                              AnalyzerMethodException
Throws:
EditionException
AnalyzerMethodException

printReport

public final void printReport(Project aProject,
                              java.lang.String outputFileStr)
                       throws ReportGenerationException,
                              MustBeTTMKindFileException

Specified by:
printReport in interface IEngine
Throws:
ReportGenerationException - indicates that some exception occured during report generation
MustBeTTMKindFileException - indicates that the extension of filename in parameter is wrong
See Also:
tte.IEngine#printReport(java.lang.String)

printRulesReport

public final void printRulesReport(Project aProject,
                                   java.lang.String outputFileStr)
                            throws ReportGenerationException,
                                   MustBeTTMKindFileException

Specified by:
printRulesReport in interface IEngine
Throws:
ReportGenerationException - indicates that some exception occured during report generation
MustBeTTMKindFileException - indicates that the extension of filename in parameter is wrong
See Also:
tte.IEngine#printRulesReport(java.lang.String)

getRules

public static ExtendedRule[] getRules(Project aProject)
gets the rules availables from extensions to RulesSet extension point and add them to the project rule definition.

Parameters:
aProject - is the project in which rules definition will be added
Returns:
an array of rules getted from RulesSet extensions

getAnalyzerWithID

public static ExtendedAnalyzer getAnalyzerWithID(java.lang.String anID)
Gets analyzer from extensions to DocumentAnalyzer extension point which id is given in parameter.

Parameters:
anID - is the id of the analyzer requested
Returns:
the analyzer corresponding to the id in parameter

getAnalyzers

public static ExtendedAnalyzer[] getAnalyzers()
Gets analyzers from extensions to DocumentAnalyzer extension point.

Returns:
an array of analyzers from extensions to DocumentAnalyzer extension point

Traceability

Copyright (c) 2005 TOPCASED Contributors 2005 - 2007. All rights reserved.