KVIrc  4.9.2
DeveloperAPIs
KviIdentityProfile.h
Go to the documentation of this file.
1 #ifndef _KVI_IDENTITY_PROFILE_H_
2 #define _KVI_IDENTITY_PROFILE_H_
3 //=============================================================================
4 //
5 // File : KviIdentityProfile.h
6 // Creation date : Thu Oct 16 2008 16:37:48 by Elvio Basello
7 //
8 // This file is part of the KVIrc IRC client distribution
9 // Copyright (C) 2008 Elvio Basello (hellvis69 at netsons dot org)
10 //
11 // This program is FREE software. You can redistribute it and/or
12 // modify it under the terms of the GNU General Public License
13 // as published by the Free Software Foundation; either version 2
14 // of the License, or (at your option) any later version.
15 //
16 // This program is distributed in the HOPE that it will be USEFUL,
17 // but WITHOUT ANY WARRANTY; without even the implied warranty of
18 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
19 // See the GNU General Public License for more details.
20 //
21 // You should have received a copy of the GNU General Public License
22 // along with this program. If not, write to the Free Software Foundation,
23 // Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
24 //
25 //=============================================================================
26 
33 #include "kvi_settings.h"
34 #include "KviHeapObject.h"
35 #include "KviPointerList.h"
36 
37 #include <QString>
38 
40 
46 {
47 public:
53 
59 
60 protected:
61  QString m_szName;
62  QString m_szNetwork;
63  QString m_szNick;
64  QString m_szAltNick;
65  QString m_szUserName;
66  QString m_szRealName;
67 
68 public:
73  const QString & name() const { return m_szName; };
74 
79  const QString & network() const { return m_szNetwork; };
80 
85  const QString & nick() const { return m_szNick; };
86 
91  const QString & altNick() const { return m_szAltNick; };
92 
97  const QString & userName() const { return m_szUserName; };
98 
103  const QString & realName() const { return m_szRealName; };
104 
110  void setName(const QString & szName) { m_szName = szName; };
111 
117  void setNetwork(const QString & szNetwork) { m_szNetwork = szNetwork; };
118 
124  void setNick(const QString & szNick) { m_szNick = szNick; };
125 
131  void setAltNick(const QString & szAltNick) { m_szAltNick = szAltNick; };
132 
138  void setUserName(const QString & szUserName) { m_szUserName = szUserName; };
139 
145  void setRealName(const QString & szRealName) { m_szRealName = szRealName; };
146 
152  void copyFrom(const KviIdentityProfile & src);
153 
160  void save(KviConfigurationFile * pCfg, const QString & szPrefix);
161 
170  bool load(KviConfigurationFile * pCfg, const QString & szPrefix);
171 };
172 
173 #endif // _KVI_IDENTITY_PROFILE_H_
void setName(const QString &szName)
Sets the name of the profile.
Definition: KviIdentityProfile.h:110
Definition: KviHeapObject.h:124
const QString & nick() const
Returns the nickname of the profile.
Definition: KviIdentityProfile.h:85
QString m_szNetwork
Definition: KviIdentityProfile.h:62
const QString & userName() const
Returns the username of the profile.
Definition: KviIdentityProfile.h:97
void setNick(const QString &szNick)
Sets the nickname of the profile.
Definition: KviIdentityProfile.h:124
void setRealName(const QString &szRealName)
Sets the realname of the profile.
Definition: KviIdentityProfile.h:145
Definition: KviConfigurationFile.h:48
const QString & name() const
Returns the name of the profile.
Definition: KviIdentityProfile.h:73
void setAltNick(const QString &szAltNick)
Sets the alternative nickname of the profile.
Definition: KviIdentityProfile.h:131
QString m_szUserName
Definition: KviIdentityProfile.h:65
const QString & realName() const
Returns the realname of the profile.
Definition: KviIdentityProfile.h:103
bool save(KviThemeInfo &options, bool bSaveIcons)
Definition: KviOptions.cpp:986
void setNetwork(const QString &szNetwork)
Sets the network of the profile.
Definition: KviIdentityProfile.h:117
QString m_szName
Definition: KviIdentityProfile.h:61
const QString & altNick() const
Returns the alternative nickname of the profile.
Definition: KviIdentityProfile.h:91
QString m_szAltNick
Definition: KviIdentityProfile.h:64
QString m_szRealName
Definition: KviIdentityProfile.h:66
C++ Template based double linked pointer list class.
Heap Object.
void setUserName(const QString &szUserName)
Sets the username of the profile.
Definition: KviIdentityProfile.h:138
Class which manages the identity profile.
Definition: KviIdentityProfile.h:45
const QString & network() const
Returns the network of the profile.
Definition: KviIdentityProfile.h:79
This file contains compile time settings.
QString m_szNick
Definition: KviIdentityProfile.h:63
#define KVILIB_API
Definition: kvi_settings.h:125