1#ifndef _KVI_IRCUSER_ENTRY_H_
2#define _KVI_IRCUSER_ENTRY_H_
72 ModeMask = UserOp | Voice | HalfOp | Op | ChanAdmin | ChanOwner
137 void setBot(
bool bIsBot) { m_bBot = bIsBot; };
151 void setUser(
const QString & szUser) { m_szUser = szUser; };
158 void setServer(
const QString & szServ) { m_szServer = szServ; };
165 void setRealName(
const QString & szReal);
186 void setAway(
bool bAway) { m_bAway = bAway; };
201 void setAvatar(std::unique_ptr<KviAvatar> upAvatar =
nullptr);
210 void setAvatar(
KviAvatar * upAvatar =
nullptr);
217 void setUserFlags(
const QString & szFlags) { m_szUserFlags = szFlags; };
241 bool hasUser() {
return (!m_szUser.isEmpty()); };
247 bool hasHost() {
return (!m_szHost.isEmpty()); };
271 const QString &
user() {
return m_szUser; };
277 const QString &
host() {
return m_szHost; };
283 const QString &
server() {
return m_szServer; };
289 const QString &
realName() {
return m_szRealName; };
301 int hops() {
return m_iHops; };
319 std::unique_ptr<KviAvatar> forgetAvatar();
341 void setAccountName(
const QString & szAccountName) { m_szAccountName = szAccountName; };
Avatar class.
Definition KviAvatar.h:54
The class which manages the user database.
Definition KviIrcUserDataBase.h:47
A class to handle the entries of the user database.
Definition KviIrcUserEntry.h:45
Gender m_eGender
Definition KviIrcUserEntry.h:90
std::unique_ptr< KviAvatar > m_upAvatar
Definition KviIrcUserEntry.h:96
const QString & userFlags()
Returns the user flags.
Definition KviIrcUserEntry.h:295
bool hasAccountName()
Returns true if the user has an account name.
Definition KviIrcUserEntry.h:347
bool hasRealName()
Returns true if the user has the realname set.
Definition KviIrcUserEntry.h:259
void setBot(bool bIsBot)
Sets the user as a bot.
Definition KviIrcUserEntry.h:137
UserMode
Defines the user mode in a channel.
Definition KviIrcUserEntry.h:65
QString m_szHost
Definition KviIrcUserEntry.h:85
int m_iHops
Definition KviIrcUserEntry.h:89
QString m_szServer
Definition KviIrcUserEntry.h:87
bool m_bNotFoundRegUserLookup
Definition KviIrcUserEntry.h:102
bool hasUser()
Returns true if the user has the username set.
Definition KviIrcUserEntry.h:241
void setServer(const QString &szServ)
Sets the server of the user.
Definition KviIrcUserEntry.h:158
bool isBot()
Returns true if the user is marked as a bot.
Definition KviIrcUserEntry.h:223
void setAway(bool bAway)
Sets the away state of the user.
Definition KviIrcUserEntry.h:186
bool isAway() const
Returns true if the user is in away mode.
Definition KviIrcUserEntry.h:229
QString m_szRegisteredUserName
Definition KviIrcUserEntry.h:103
void setGender(Gender g)
Sets the gender of the user.
Definition KviIrcUserEntry.h:144
bool hasServer()
Returns true if the user has the server set.
Definition KviIrcUserEntry.h:253
QString m_szRealName
Definition KviIrcUserEntry.h:88
int m_nRefs
Definition KviIrcUserEntry.h:98
QColor m_cachedColor
Definition KviIrcUserEntry.h:106
bool m_bAway
Definition KviIrcUserEntry.h:93
void setUserFlags(const QString &szFlags)
Sets the user global flags (eg: "G*")
Definition KviIrcUserEntry.h:217
const QString & accountName()
Returns the account name (if any)
Definition KviIrcUserEntry.h:336
bool m_bUseCustomColor
Definition KviIrcUserEntry.h:107
int nRefs()
Returns the number of references of the user in the database.
Definition KviIrcUserEntry.h:313
QString m_szAccountName
Definition KviIrcUserEntry.h:110
QString m_szUser
Definition KviIrcUserEntry.h:84
KviAvatar * avatar()
Returns the avatar of the user.
Definition KviIrcUserEntry.h:307
Gender gender()
Returns the gender of the user.
Definition KviIrcUserEntry.h:130
const QString & host()
Returns the hostname of the user.
Definition KviIrcUserEntry.h:277
bool m_bBot
Definition KviIrcUserEntry.h:99
void setHops(int iHops)
Sets the number of hops of the user.
Definition KviIrcUserEntry.h:172
int hops()
Returns the number of hops.
Definition KviIrcUserEntry.h:301
void setAccountName(const QString &szAccountName)
Sets the account name for the user.
Definition KviIrcUserEntry.h:341
void setUser(const QString &szUser)
Sets the username of the user.
Definition KviIrcUserEntry.h:151
QString m_szLastRegisteredMatchNick
Definition KviIrcUserEntry.h:104
void setHost(const QString &szHost)
Sets the hostname of the user.
Definition KviIrcUserEntry.h:179
bool m_bAvatarRequested
Definition KviIrcUserEntry.h:100
bool hasHost()
Returns true if the user has the hostname set.
Definition KviIrcUserEntry.h:247
void setAvatarRequested()
Mark that kvirc is trying (already tried) to get user's avatar.
Definition KviIrcUserEntry.h:330
bool isIrcOp() const
Returns true if the user is an irc operator.
Definition KviIrcUserEntry.h:235
void setSmartNickColor(const int iColor)
Sets the ircview smart nick color of the user.
Definition KviIrcUserEntry.h:124
bool avatarRequested() const
Returns true if kvirc already made an attempt to download user's avatar.
Definition KviIrcUserEntry.h:325
const QString & realName()
Returns the realname of the user.
Definition KviIrcUserEntry.h:289
QString m_szUserFlags
Definition KviIrcUserEntry.h:91
bool hasHops()
Returns true if the user has hops set.
Definition KviIrcUserEntry.h:265
int smartNickColor()
Returns the ircview smart nick color of the user.
Definition KviIrcUserEntry.h:117
const QString & server()
Returns the server of the user.
Definition KviIrcUserEntry.h:283
const QString & user()
Returns the username of the user.
Definition KviIrcUserEntry.h:271
bool m_bIrcOp
Definition KviIrcUserEntry.h:94
void setIrcOp(bool bIrcOp)
Sets the irc operator state of the user.
Definition KviIrcUserEntry.h:193
int m_iSmartNickColor
Definition KviIrcUserEntry.h:109
Gender
Defines the gender of the user.
Definition KviIrcUserEntry.h:54
#define g
Definition detector.cpp:72
This file contains compile time settings.
#define KVILIB_API
Definition kvi_settings.h:124
QString szHost
Definition libkvisetup.cpp:48