libzypp 17.37.10

zyppng::TrustKeyRequest Class Reference

`#include <zypp/ng/userrequest.h>`

Inheritance diagram for zyppng::TrustKeyRequest:

## Public Types
enum | KeyTrust { KEY_DONT_TRUST = 0 , KEY_TRUST_TEMPORARILY , KEY_TRUST_AND_IMPORT }
Public Types inherited from zyppng::Base
using | Ptr = std::shared_ptr<Base>
using | WeakPtr = std::weak_ptr<Base>

## Public Member Functions
| ZYPP_DECL_PRIVATE_CONSTR_ARGS (TrustKeyRequest, std::string label, KeyTrust trust=KEY_DONT_TRUST, UserData userData={})
void | setChoice (const KeyTrust sel)
KeyTrust | choice () const
const std::string | label () const
UserRequestType | type () const override
Public Member Functions inherited from zyppng::UserRequest
| UserRequest (UserData userData={})
| ~UserRequest () override
const UserData & | userData () const
UserData & | userData ()
Public Member Functions inherited from zyppng::Base
| Base ()
virtual | ~Base ()
WeakPtr | parent () const
void | addChild (const Base::Ptr &child)
void | removeChild (const Ptr &child)
const std::unordered_set< Ptr > & | children () const
std::thread::id | threadId () const
template<typename T>
std::vector< std::weak_ptr< T > > | findChildren () const
template<typename T>
std::shared_ptr< T > | shared_this () const
template<typename T>
std::shared_ptr< T > | shared_this ()
template<typename T>
std::weak_ptr< T > | weak_this () const
template<typename T>
std::weak_ptr< T > | weak_this ()
template<typename SenderFunc, typename ReceiverFunc>
auto | connect (SenderFunc &&sFun, typename internal::MemberFunction< ReceiverFunc >::ClassType &recv, ReceiverFunc &&rFunc)
template<typename SenderFunc, typename ReceiverFunc, typename ... Tracker>
std::enable_if_t< std::is_member_function_pointer_v< SenderFunc >, connection > | connectFunc (SenderFunc &&sFun, ReceiverFunc &&rFunc, const Tracker &...trackers)

## Private Attributes
std::string | _label
KeyTrust | _answer = KEY_DONT_TRUST

## Additional Inherited Members
Static Public Member Functions inherited from zyppng::Base
template<typename Obj, typename Functor>
static decltype(auto) | make_base_slot (Obj *o, Functor &&f)
template<typename SenderFunc, typename ReceiverFunc>
static auto | connect (typename internal::MemberFunction< SenderFunc >::ClassType &s, SenderFunc &&sFun, typename internal::MemberFunction< ReceiverFunc >::ClassType &recv, ReceiverFunc &&rFunc)
template<typename SenderFunc, typename ReceiverFunc, typename ... Tracker>
static auto | connectFunc (typename internal::MemberFunction< SenderFunc >::ClassType &s, SenderFunc &&sFun, ReceiverFunc &&rFunc, const Tracker &...trackers)
Protected Member Functions inherited from zyppng::Base
| Base (BasePrivate &dd)
Protected Attributes inherited from zyppng::Base
std::unique_ptr< BasePrivate > | d_ptr

## Detailed Description

Definition at line 70 of file userrequest.h.

## Member Enumeration Documentation

## ◆ KeyTrust

enum zyppng::TrustKeyRequest::KeyTrust

Keep in sync with zypp::KeyRingReport::KeyTrust, we do not want to include old APIs here if possible.

Enumerator
KEY_DONT_TRUST | User has chosen not to trust the key.
KEY_TRUST_TEMPORARILY | This basically means, we knew the key, but it was not trusted. User has chosen to continue, but not import the key.
KEY_TRUST_AND_IMPORT | Import the key. This means saving the key in the trusted database so next run it will appear as trusted. Nothing to do with KEY_TRUST_TEMPORARILY, as you CAN trust a key without importing it, basically you will be asked every time again. There are programs who prefer to manage the trust keyring on their own and use trustKey without importing it into rpm.

Definition at line 78 of file userrequest.h.

## Member Function Documentation

## ◆ ZYPP_DECL_PRIVATE_CONSTR_ARGS()

zyppng::TrustKeyRequest::ZYPP_DECL_PRIVATE_CONSTR_ARGS | ( | TrustKeyRequest | ,
|  | std::string | label,
|  | KeyTrust | trust = KEY_DONT_TRUST,
|  | UserData | userData = {} )

## ◆ setChoice()

void zyppng::TrustKeyRequest::setChoice | ( | const KeyTrust | sel | ) |

Definition at line 40 of file userrequest.cc.

## ◆ choice()

TrustKeyRequest::KeyTrust zyppng::TrustKeyRequest::choice | ( |  | ) | const

Definition at line 43 of file userrequest.cc.

## ◆ label()

const std::string zyppng::TrustKeyRequest::label | ( |  | ) | const

Definition at line 46 of file userrequest.cc.

## ◆ type()

UserRequestType zyppng::TrustKeyRequest::type | ( |  | ) | const
| override virtual

Implements zyppng::UserRequest.

Definition at line 49 of file userrequest.cc.

## Member Data Documentation

## ◆ _label

std::string zyppng::TrustKeyRequest::_label
| private

Definition at line 110 of file userrequest.h.

## ◆ _answer

KeyTrust zyppng::TrustKeyRequest::_answer = KEY_DONT_TRUST
| private

Definition at line 111 of file userrequest.h.

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

- zypp/ng/userrequest.h
- zypp/ng/userrequest.cc