X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcreaDevManagerLib%2FmodelCDMProject.h;h=f354db9e51c6e3e56aa73f82a79a8b1204b93524;hb=9f11db34cb1acacf545f819d6b552a95835d93bd;hp=5df1550a28c11c0fafe6b146472bdba5342a8336;hpb=af76296378f6fc398f0f6f516506d19019ff8287;p=crea.git diff --git a/lib/creaDevManagerLib/modelCDMProject.h b/lib/creaDevManagerLib/modelCDMProject.h index 5df1550..f354db9 100644 --- a/lib/creaDevManagerLib/modelCDMProject.h +++ b/lib/creaDevManagerLib/modelCDMProject.h @@ -142,7 +142,7 @@ public: //Creations /** - * Creates a package and sets it as a children of the project. This method creates the package in the hard drive and also in the model. + * Creates a package and sets it as a children of the project. This method creates the package in the hard drive and also in the model. The created package is included in the project's CMakeLists file. * @param name Name of the package. * @param result Result of the operation. * @param authors Authors of the operation. If any space is found, it will be replaced by '_'. @@ -252,6 +252,21 @@ public: */ void CheckStructure(std::map& properties); + /** + * Checks if the given package is included in the CMakeLists file. + * @param package_name Name of the package to check. + * @return True if the package is included, otherwise returns False. + */ + bool IsPackageIncluded(const std::string& package_name); + + /** + * Sets the inclusion of the package in the project's CMakeLists file. If the package inclusion already exist in file, then the line is uncommented/commented depending on the requested action. If the package inclusion doesn't exist yet, then it is included if the request is an inclusion. + * @param package_name Name of the package to include/exclude. + * @param toInclude True if the request is an inclusion, False otherwise. + * @return True if the request was processed successfully. + */ + bool SetPackageInclude(const std::string& package_name, const bool& toInclude); + private: