libzypp 17.38.6
architecturecomponent.h
Go to the documentation of this file.
1/*---------------------------------------------------------------------
2| ____ _ __ __ ___ |
3| |__ / \ / / . \ . \ |
4| / / \ V /| _/ _/ |
5| / /__ | | | | | | |
6| /_____||_| |_| |_| |
7| |
8----------------------------------------------------------------------/
9*
10* This file contains private API, this might break at any time between releases.
11* You have been warned!
12*
13*/
14#ifndef ZYPP_NG_SAT_COMPONENTS_ARCHITECTURECOMPONENT_H_INCLUDED
15#define ZYPP_NG_SAT_COMPONENTS_ARCHITECTURECOMPONENT_H_INCLUDED
16
17#include "poolcomponents.h"
18#include <zypp/ng/arch.h>
20#include <functional>
21
22namespace zyppng::sat {
23
31 public:
33 using ArchitectureProvider = std::function<zypp::Arch()>;
34
36
38 void setProvider( ArchitectureProvider provider );
39
43
44 InitStage stage() const override { return InitStage::Environment; }
45 int priority() const override { return 0; }
46
47 void attach(Pool &pool) override;
48 void prepare( Pool & pool ) override;
49 void onRepoAdded( Pool & pool, detail::RepoIdType id ) override;
50 void onReset( Pool & pool ) override;
51
52 private:
53 Pool *_pool = nullptr;
56 };
57
58
59} // namespace zyppng::sat
60
61#endif
Architecture.
Definition Arch.h:37
static Arch detectSystemArchitecture()
Determine system architecture evaluating uname and /proc/cpuinfo.
Definition Arch.cc:701
Simple serial number watcher.
std::function< zypp::Arch()> ArchitectureProvider
Provider function returning an Arch.
void onRepoAdded(Pool &pool, detail::RepoIdType id) override
void setProvider(ArchitectureProvider provider)
Set a custom architecture provider.
zypp::Arch arch() const
Get the current architecture.
int priority() const override
Fine-grained ordering within a stage.
Interface for components that run BEFORE the whatprovides index is built.
Orchestrator for a libsolv pool instance.
Definition pool.h:37
zypp::sat::detail::RepoIdType RepoIdType
This file contains private API, this might break at any time between releases.
InitStage
Execution stages for IPoolComponent (pre-index phase).
@ Environment
Arches, Locales, Namespace Callbacks (The Foundation).