Computer Assisted Medical Intervention Tool Kit  version 6.0
Loading...
Searching...
No Matches
CMakeProjectManager Class Reference

#include <CMakeProjectManager.h>

Public Types

enum  CMakeProjectManagerStage {
  Check_System , Generate_Source_Files , Configure_CMake , Build_Project ,
  Run_CamiTK_Config , Check_Integration , Cleanup
}
 Known stages that can be set in the stage configuration. More...

Signals

void allStagesFinished (bool status)
 sent when all the stage are finished (with the given overall status)
void stageFinished (const QString &stage, bool success, const QString &output)
 sent when the given stage is finished (with the given status and output)
void stageStarted (const QString &stage)
 sent when the given stage is starting

Public Member Functions

 CMakeProjectManager (const QString &camitkFilePath, QObject *parent=nullptr)
 constructor
QString getCurrentStage () const
 current stage
QString getStageName (CMakeProjectManagerStage value) const
 utility method to get the QString equivalent of the given stage (underscores are replaced by space)
QStringList getStages () const
 get all the stages that were setup
void setStages (QList< CMakeProjectManagerStage > stagesToPerform)
 you can override default stages by sending an non empty list of stages to perform
void start ()
 starts all the setup stages
bool success () const
 current value of the process
 ~CMakeProjectManager ()

Detailed Description

Member Enumeration Documentation

◆ CMakeProjectManagerStage

Known stages that can be set in the stage configuration.

Enumerator
Check_System 

check that cmake, camitk-extensiongenerator and camitk-config are found and usable

Generate_Source_Files 

calls camitk-extensiongenerator (fist phase with destination dir equals to the CamiTK file path)

Configure_CMake 

cmake configure

Build_Project 

cmake build

Run_CamiTK_Config 

check camitk-config –config (output can be check for new Standard extension)

Check_Integration 

(for Standard extension) check what is build action extensions defined in the CamiTK file were build and properly loaded by camitk-config

Cleanup 

remove temporary directory used during the previous stages

Constructor & Destructor Documentation

◆ CMakeProjectManager()

CMakeProjectManager::CMakeProjectManager ( const QString & camitkFilePath,
QObject * parent = nullptr )

constructor

Parameters
camitkFilePaththe full path of the camitk file (with the .camitk extension)
parent(optional)

References Build_Project, Check_Integration, Check_System, Cleanup, Configure_CMake, Generate_Source_Files, and Run_CamiTK_Config.

◆ ~CMakeProjectManager()

CMakeProjectManager::~CMakeProjectManager ( )

Member Function Documentation

◆ allStagesFinished

void CMakeProjectManager::allStagesFinished ( bool status)
signal

◆ getCurrentStage()

QString CMakeProjectManager::getCurrentStage ( ) const

current stage

References getStageName().

◆ getStageName()

QString CMakeProjectManager::getStageName ( CMakeProjectManagerStage value) const

utility method to get the QString equivalent of the given stage (underscores are replaced by space)

Referenced by getCurrentStage(), and getStages().

◆ getStages()

QStringList CMakeProjectManager::getStages ( ) const

get all the stages that were setup

References getStageName().

◆ setStages()

void CMakeProjectManager::setStages ( QList< CMakeProjectManagerStage > stagesToPerform)

you can override default stages by sending an non empty list of stages to perform

◆ stageFinished

void CMakeProjectManager::stageFinished ( const QString & stage,
bool success,
const QString & output )
signal

sent when the given stage is finished (with the given status and output)

Note
the output concatenates standard output and standard error of the subprocess in a QString of value: "Standard Output:\n%1\nStandard Error:%2\n", where %1 is the standard output and %2 is the standard error
Examples
/build/camitk-9Ht7pk/camitk-6.0.0/sdk/libraries/extensiongenerator/CMakeProjectManager.h.

References success().

Referenced by CMakeProjectManagerPresenter::CMakeProjectManagerPresenter().

◆ stageStarted

void CMakeProjectManager::stageStarted ( const QString & stage)
signal

◆ start()

void CMakeProjectManager::start ( )

starts all the setup stages

◆ success()

bool CMakeProjectManager::success ( ) const

current value of the process

Referenced by stageFinished().


The documentation for this class was generated from the following files: