-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhostmask.h
More file actions
48 lines (35 loc) · 958 Bytes
/
hostmask.h
File metadata and controls
48 lines (35 loc) · 958 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/// \file
/// \brief Declaration of HostMask utility class
///
/// \author png!das-system
#ifndef HOSTMASK_H
#define HOSTMASK_H 1
#include <QDebug>
#include <QString>
#include "qirc.h"
namespace QIRC {
/// \brief Utility class to store an user hostmask
class HostMask {
public:
HostMask(QString nick, QString user, QString host);
HostMask(const HostMask& other);
QString nick() const;
void setNick(QString n);
QString user() const;
void setUser(QString u);
QString host() const;
void setHost(QString h);
QString toString() const;
bool operator ==(const HostMask& o) const;
bool operator !=(const HostMask& o) const;
protected:
/// \brief Nickname part of hostmask
QString m_nick;
/// \brief Username part of hostmask
QString m_user;
/// \brief Hostname part of hostmask
QString m_host;
};
};
QDebug& operator <<(QDebug& dbg, QIRC::HostMask& h);
#endif // !HOSTMASK_H