1
//=============================================================================
4
// Creation date : Sat Aug 17 14:09:18 2002 GMT by Szymon Stefanek
6
// This file is part of the KVirc irc client distribution
7
// Copyright (C) 2002-2008 Szymon Stefanek (pragma at kvirc dot net)
9
// This program is FREE software. You can redistribute it and/or
10
// modify it under the terms of the GNU General Public License
11
// as published by the Free Software Foundation; either version 2
12
// of the License, or (at your opinion) any later version.
14
// This program is distributed in the HOPE that it will be USEFUL,
15
// but WITHOUT ANY WARRANTY; without even the implied warranty of
16
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
17
// See the GNU General Public License for more details.
19
// You should have received a copy of the GNU General Public License
20
// along with this program. If not, write to the Free Software Foundation,
21
// Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23
//=============================================================================
34
KviUrl::KviUrl(const KviUrl & u)
39
KviUrl::KviUrl(const char * szUrl)
41
m_szUrl = QString::fromLocal8Bit(szUrl);
45
KviUrl::KviUrl(const QString &szUrl)
59
m_szProtocol = url.scheme();
60
m_szHost = url.host();
61
m_szPath = url.encodedPath();
64
m_szPath.append(QChar('?'));
65
m_szPath.append(url.encodedQuery());
67
if(m_szPath.isEmpty()) m_szPath=QString("/");
68
m_szUser = url.userName();
69
m_szPass = url.password();
70
m_uPort = url.port() > 0 ? url.port() : 80 ;
74
KviUrl & KviUrl::operator=(const QString& szUrl)
81
KviUrl & KviUrl::operator=(const KviUrl &u)
84
m_szProtocol = u.m_szProtocol;
85
m_szHost = u.m_szHost;
86
m_szPath = u.m_szPath;
87
m_szUser = u.m_szUser;
88
m_szPass = u.m_szPass;