// qhostaddress.sip generated by MetaSIP on Fri Sep 28 17:07:47 2007 // // This file is part of the QtNetwork Python extension module. // // Copyright (c) 2007 // Phil Thompson // // This file is part of PyQt. // // This copy of PyQt is free software; you can redistribute it and/or modify it // under the terms of the GNU General Public License version 2 as published by // the Free Software Foundation and appearing in the file LICENSE included in the // packaging of this file. // // PyQt is supplied in the hope that it will be useful, but WITHOUT ANY // WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS // FOR A PARTICULAR PURPOSE. See the GNU General Public License for more // details. // // You should have received a copy of the GNU General Public License along with // PyQt; see the file LICENSE. If not, write to the Free Software Foundation, // Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. %ModuleCode #include %End class QHostAddress { %TypeHeaderCode #include %End public: enum SpecialAddress { Null, Broadcast, LocalHost, LocalHostIPv6, Any, AnyIPv6, }; QHostAddress(); QHostAddress(QHostAddress::SpecialAddress address); explicit QHostAddress(quint32 ip4Addr); explicit QHostAddress(const QString &address); QHostAddress(const QHostAddress ©); ~QHostAddress(); void setAddress(quint32 ip4Addr); bool setAddress(const QString &address); QAbstractSocket::NetworkLayerProtocol protocol() const; quint32 toIPv4Address() const; QString toString() const; QString scopeId() const; void setScopeId(const QString &id); bool operator==(const QHostAddress &address) const; bool operator==(QHostAddress::SpecialAddress address) const; %If (Qt_4_2_0 -) bool operator!=(const QHostAddress &address) const; %End %If (Qt_4_2_0 -) bool operator!=(QHostAddress::SpecialAddress address) const; %End bool isNull() const; void clear(); }; bool operator==(QHostAddress::SpecialAddress address1, const QHostAddress &address2); %If (Qt_4_2_0 -) uint qHash(const QHostAddress &key); %End %If (Qt_4_2_0 -) QDataStream &operator<<(QDataStream &, const QHostAddress &); %End %If (Qt_4_2_0 -) QDataStream &operator>>(QDataStream &, QHostAddress &); %End