/*
 * This file was generated by dbusxml2cpp version 0.6
 * Command line was: dbusxml2cpp -m -p avahi_server_interface /home/qba/src/kdelibs/dnssd/org.freedesktop.Avahi.Server.xml
 *
 * dbusxml2cpp is Copyright (C) 2006 Trolltech ASA. All rights reserved.
 *
 * This is an auto-generated file.
 * Do not edit! All changes made to it will be lost.
 */

#ifndef AVAHI_SERVER_INTERFACE_H_1175535514
#define AVAHI_SERVER_INTERFACE_H_1175535514

#include <QtCore/QObject>
#include <QtCore/QByteRef>
#include <QtCore/QList>
#include <QtCore/QMap>
#include <QtCore/QString>
#include <QtCore/QStringList>
#include <QtCore/QVariant>
#include <QtDBus/QtDBus>

// wait 100ms after last service
#define TIMEOUT_LAN 100

/*
 * Proxy class for interface org.freedesktop.Avahi.Server
 */
class OrgFreedesktopAvahiServerInterface: public QDBusAbstractInterface
{
    Q_OBJECT
public:
    static inline const char *staticInterfaceName()
    { return "org.freedesktop.Avahi.Server"; }

public:
    OrgFreedesktopAvahiServerInterface(const QString &service, const QString &path, const QDBusConnection &connection, QObject *parent = 0);

    ~OrgFreedesktopAvahiServerInterface();

public Q_SLOTS: // METHODS
    inline QDBusReply<QDBusObjectPath> AddressResolverNew(int interface, int protocol, const QString &address, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(address) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("AddressResolverNew"), argumentList);
    }

    inline QDBusReply<QDBusObjectPath> DomainBrowserNew(int interface, int protocol, const QString &domain, int btype, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(domain) << qVariantFromValue(btype) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("DomainBrowserNew"), argumentList);
    }

    inline QDBusReply<QDBusObjectPath> EntryGroupNew()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("EntryGroupNew"), argumentList);
    }

    inline QDBusReply<uint> GetAPIVersion()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetAPIVersion"), argumentList);
    }

    inline QDBusReply<QString> GetAlternativeHostName(const QString &name)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(name);
        return callWithArgumentList(QDBus::Block, QLatin1String("GetAlternativeHostName"), argumentList);
    }

    inline QDBusReply<QString> GetAlternativeServiceName(const QString &name)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(name);
        return callWithArgumentList(QDBus::Block, QLatin1String("GetAlternativeServiceName"), argumentList);
    }

    inline QDBusReply<QString> GetDomainName()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetDomainName"), argumentList);
    }

    inline QDBusReply<QString> GetHostName()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetHostName"), argumentList);
    }

    inline QDBusReply<QString> GetHostNameFqdn()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetHostNameFqdn"), argumentList);
    }

    inline QDBusReply<uint> GetLocalServiceCookie()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetLocalServiceCookie"), argumentList);
    }

    inline QDBusReply<int> GetNetworkInterfaceIndexByName(const QString &name)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(name);
        return callWithArgumentList(QDBus::Block, QLatin1String("GetNetworkInterfaceIndexByName"), argumentList);
    }

    inline QDBusReply<QString> GetNetworkInterfaceNameByIndex(int index)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(index);
        return callWithArgumentList(QDBus::Block, QLatin1String("GetNetworkInterfaceNameByIndex"), argumentList);
    }

    inline QDBusReply<int> GetState()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetState"), argumentList);
    }

    inline QDBusReply<QString> GetVersionString()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("GetVersionString"), argumentList);
    }

    inline QDBusReply<QDBusObjectPath> HostNameResolverNew(int interface, int protocol, const QString &name, int aprotocol, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(name) << qVariantFromValue(aprotocol) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("HostNameResolverNew"), argumentList);
    }

    inline QDBusReply<bool> IsNSSSupportAvailable()
    {
        QList<QVariant> argumentList;
        return callWithArgumentList(QDBus::Block, QLatin1String("IsNSSSupportAvailable"), argumentList);
    }

    inline QDBusReply<QDBusObjectPath> RecordBrowserNew(int interface, int protocol, const QString &name, ushort clazz, ushort type, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(name) << qVariantFromValue(clazz) << qVariantFromValue(type) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("RecordBrowserNew"), argumentList);
    }

    inline QDBusReply<int> ResolveAddress(int interface, int protocol, const QString &address, uint flags, int &protocol_, int &aprotocol, QString &address_, QString &name, uint &flags_)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(address) << qVariantFromValue(flags);
        QDBusMessage reply = callWithArgumentList(QDBus::Block, QLatin1String("ResolveAddress"), argumentList);
        if (reply.type() == QDBusMessage::ReplyMessage && reply.arguments().count() == 6) {
            protocol_ = qdbus_cast<int>(reply.arguments().at(1));
            aprotocol = qdbus_cast<int>(reply.arguments().at(2));
            address_ = qdbus_cast<QString>(reply.arguments().at(3));
            name = qdbus_cast<QString>(reply.arguments().at(4));
            flags_ = qdbus_cast<uint>(reply.arguments().at(5));
        }
        return reply;
    }

    inline QDBusReply<int> ResolveHostName(int interface, int protocol, const QString &name, int aprotocol, uint flags, int &protocol_, QString &name_, int &aprotocol_, QString &address, uint &flags_)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(name) << qVariantFromValue(aprotocol) << qVariantFromValue(flags);
        QDBusMessage reply = callWithArgumentList(QDBus::Block, QLatin1String("ResolveHostName"), argumentList);
        if (reply.type() == QDBusMessage::ReplyMessage && reply.arguments().count() == 6) {
            protocol_ = qdbus_cast<int>(reply.arguments().at(1));
            name_ = qdbus_cast<QString>(reply.arguments().at(2));
            aprotocol_ = qdbus_cast<int>(reply.arguments().at(3));
            address = qdbus_cast<QString>(reply.arguments().at(4));
            flags_ = qdbus_cast<uint>(reply.arguments().at(5));
        }
        return reply;
    }

    inline QDBusReply<int> ResolveService(int interface, int protocol, const QString &name, const QString &type, const QString &domain, int aprotocol, uint flags, int &protocol_, QString &name_, QString &type_, QString &domain_, QString &host, int &aprotocol_, QString &address, ushort &port, QList<QByteArray> &txt, uint &flags_)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(name) << qVariantFromValue(type) << qVariantFromValue(domain) << qVariantFromValue(aprotocol) << qVariantFromValue(flags);
        QDBusMessage reply = callWithArgumentList(QDBus::Block, QLatin1String("ResolveService"), argumentList);
        if (reply.type() == QDBusMessage::ReplyMessage && reply.arguments().count() == 11) {
            protocol_ = qdbus_cast<int>(reply.arguments().at(1));
            name_ = qdbus_cast<QString>(reply.arguments().at(2));
            type_ = qdbus_cast<QString>(reply.arguments().at(3));
            domain_ = qdbus_cast<QString>(reply.arguments().at(4));
            host = qdbus_cast<QString>(reply.arguments().at(5));
            aprotocol_ = qdbus_cast<int>(reply.arguments().at(6));
            address = qdbus_cast<QString>(reply.arguments().at(7));
            port = qdbus_cast<ushort>(reply.arguments().at(8));
            txt = qdbus_cast<QList<QByteArray> >(reply.arguments().at(9));
            flags_ = qdbus_cast<uint>(reply.arguments().at(10));
        }
        return reply;
    }

    inline QDBusReply<QDBusObjectPath> ServiceBrowserNew(int interface, int protocol, const QString &type, const QString &domain, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(type) << qVariantFromValue(domain) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("ServiceBrowserNew"), argumentList);
    }

    inline QDBusReply<QDBusObjectPath> ServiceResolverNew(int interface, int protocol, const QString &name, const QString &type, const QString &domain, int aprotocol, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(name) << qVariantFromValue(type) << qVariantFromValue(domain) << qVariantFromValue(aprotocol) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("ServiceResolverNew"), argumentList);
    }

    inline QDBusReply<QDBusObjectPath> ServiceTypeBrowserNew(int interface, int protocol, const QString &domain, uint flags)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(interface) << qVariantFromValue(protocol) << qVariantFromValue(domain) << qVariantFromValue(flags);
        return callWithArgumentList(QDBus::Block, QLatin1String("ServiceTypeBrowserNew"), argumentList);
    }

    inline QDBusReply<void> SetHostName(const QString &name)
    {
        QList<QVariant> argumentList;
        argumentList << qVariantFromValue(name);
        return callWithArgumentList(QDBus::Block, QLatin1String("SetHostName"), argumentList);
    }

Q_SIGNALS: // SIGNALS
    void StateChanged(int state, const QString &error);
};


namespace DNSSD {
    void registerTypes();
    QString domainToDNS(const QString &domain);
    QString DNSToDomain(const QString &domain);
}

namespace org {
  namespace freedesktop {
    namespace Avahi {
      typedef ::OrgFreedesktopAvahiServerInterface Server;
    }
  }
}
#endif
