SourceXtractorPlusPlus 0.21
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
AttractorsPartitionConfig.cpp
Go to the documentation of this file.
1
17/*
18 * @file AttractorsPartitionConfig.cpp
19 * @author nikoapos
20 */
21
25
27
28using namespace Euclid::Configuration;
29namespace po = boost::program_options;
30
31namespace SourceXtractor {
32
33static const std::string USE_ATTRACTORS_PARTITION {"use-attractors-partition"};
34
40
42 return { {"Extraction", {
43 {USE_ATTRACTORS_PARTITION.c_str(), po::value<bool>()->default_value(false),
44 "Enables the use of attractors for partitioning"}
45 }}};
46}
47
49 if (args.at(USE_ATTRACTORS_PARTITION).as<bool>()) {
50 getDependency<PartitionStepConfig>().addPartitionStepCreator(
51 [](std::shared_ptr<SourceFactory> source_factory) {
52 return std::make_shared<AttractorsPartitionStep>(source_factory);
53 }
54 );
55 }
56}
57
58} // SourceXtractor namespace
static ConfigManager & getInstance(long id)
std::map< std::string, OptionDescriptionList > getProgramOptions() override
void initialize(const UserValues &args) override
static const std::string USE_ATTRACTORS_PARTITION