libnick 2024.9.2
A cross-platform base for native Nickvision applications.
Loading...
Searching...
No Matches
passwordcontent.h
Go to the documentation of this file.
1
23#ifndef PASSWORDCONTENT_H
24#define PASSWORDCONTENT_H
25
26namespace Nickvision::Keyring
27{
31 enum class PasswordContent
32 {
33 Numeric = 1,
34 Uppercase = 2,
35 Lowercase = 4,
36 Special = 8
37 };
38
40 {
41 return static_cast<PasswordContent>(~static_cast<int>(a));
42 }
43
45 {
46 return static_cast<PasswordContent>(static_cast<int>(a) | static_cast<int>(b));
47 }
48
50 {
51 return static_cast<PasswordContent>(static_cast<int>(a) & static_cast<int>(b));
52 }
53
55 {
56 return static_cast<PasswordContent>(static_cast<int>(a) ^ static_cast<int>(b));
57 }
58
60 {
61 return reinterpret_cast<PasswordContent&>(reinterpret_cast<int&>(a) |= static_cast<int>(b));
62 }
63
65 {
66 return reinterpret_cast<PasswordContent&>(reinterpret_cast<int&>(a) &= static_cast<int>(b));
67 }
68
70 {
71 return reinterpret_cast<PasswordContent&>(reinterpret_cast<int&>(a) ^= static_cast<int>(b));
72 }
73}
74
75#endif //PASSWORDCONTENT_H
Definition credential.h:30
CredentialCheckStatus & operator|=(CredentialCheckStatus &a, CredentialCheckStatus b)
Definition credentialcheckstatus.h:59
PasswordContent
Flags to describe the content of a password.
Definition passwordcontent.h:32
@ Uppercase
The password contains uppercase characters.
@ Numeric
The password contains numeric characters.
@ Special
The password contains special characters.
@ Lowercase
The password contains lowercase characters.
CredentialCheckStatus & operator^=(CredentialCheckStatus &a, CredentialCheckStatus b)
Definition credentialcheckstatus.h:69
constexpr CredentialCheckStatus operator|(CredentialCheckStatus a, CredentialCheckStatus b)
Definition credentialcheckstatus.h:44
constexpr CredentialCheckStatus operator~(CredentialCheckStatus a)
Definition credentialcheckstatus.h:39
constexpr CredentialCheckStatus operator^(CredentialCheckStatus a, CredentialCheckStatus b)
Definition credentialcheckstatus.h:54
CredentialCheckStatus & operator&=(CredentialCheckStatus &a, CredentialCheckStatus b)
Definition credentialcheckstatus.h:64
constexpr CredentialCheckStatus operator&(CredentialCheckStatus a, CredentialCheckStatus b)
Definition credentialcheckstatus.h:49