|
SlHelpers
|
Parse branches.conf into a map of branch -> properties (BranchProps). More...
#include <Branches.h>
Public Types | |
| enum | Filter : unsigned { BUILD = 1U << 0 , PUBLISH = 1U << 1 , EXCLUDED = 1U << 2 , ANY = ~0U } |
| Constants used for filter(). | |
| using | BranchesSet = std::unordered_set<std::string> |
| A set of branches. | |
| using | BranchesList = BranchProps::BranchesList |
| A list of branches. | |
| using | BranchesMap |
| Branch -> BranchProps mapping. | |
Public Member Functions | |
| const BranchesMap & | map () const noexcept |
| Obtain whole branch map. | |
| auto | begin () const noexcept |
| Obtain begin iterator of branches. | |
| auto | end () const noexcept |
| Obtain end iterator of branches. | |
| BranchesList | filter (unsigned include=ANY, unsigned exclude=EXCLUDED) const |
Obtain BranchesList according to a filter specified by include and exclude. | |
| const BranchProps & | props (std::string_view branch) const |
Return BranchProps for branch. | |
| const BranchesList & | merges (std::string_view branch) const |
Immediate branches that the specified branch merges. | |
| BranchesSet | mergesClosure (std::string_view branch) const |
Closure of branches that the specified branch merges. | |
Static Public Member Functions | |
| static Branches | create (std::string_view branchesConf) noexcept |
Parse provided branchesConf into Branches. | |
| static std::optional< Branches > | create () |
| Download branches.conf and parse it into Branches. | |
| static BranchesList | getBuildBranches (std::string_view branchesConf) noexcept |
Convert branchesConf to a list of branches which are built. | |
| static std::optional< BranchesList > | getBuildBranches () |
| Download branches.conf and convert it to a list of branches which are built. | |
Parse branches.conf into a map of branch -> properties (BranchProps).
Branch -> BranchProps mapping.
|
inlinenoexcept |
Obtain begin iterator of branches.
|
static |
|
staticnoexcept |
|
inlinenoexcept |
Obtain end iterator of branches.
| BranchesList SlKernCVS::Branches::filter | ( | unsigned | include = ANY, |
| unsigned | exclude = EXCLUDED ) const |
Obtain BranchesList according to a filter specified by include and exclude.
| include | Properties of branches to include in the output |
| exclude | Properties of branches to exclude from the output |
|
static |
Download branches.conf and convert it to a list of branches which are built.
|
staticnoexcept |
Convert branchesConf to a list of branches which are built.
| branchesConf | branches.conf to parse |
|
inlinenoexcept |
Obtain whole branch map.
|
inline |
Immediate branches that the specified branch merges.
| branch | Branch to find children of |
branch. | BranchesSet SlKernCVS::Branches::mergesClosure | ( | std::string_view | branch | ) | const |
Closure of branches that the specified branch merges.
| branch | Branch to find children of |
branch.