Skip to content
Skip to link menu
Trinity API Reference
Trinity API Reference
dnssd
dnssd
dnssd
responder.h
1
/* This file is part of the KDE project
2
*
3
* Copyright (C) 2004 Jakub Stachowski <qbast@go2.pl>
4
*
5
* This library is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU Library General Public
7
* License as published by the Free Software Foundation; either
8
* version 2 of the License, or (at your option) any later version.
9
*
10
* This library is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
* Library General Public License for more details.
14
*
15
* You should have received a copy of the GNU Library General Public License
16
* along with this library; see the file COPYING.LIB. If not, write to
17
* the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18
* Boston, MA 02110-1301, USA.
19
*/
20
21
#ifndef DNSSDRESPONDER_H
22
#define DNSSDRESPONDER_H
23
24
#include <tqobject.h>
25
#include <tqsocketnotifier.h>
26
#include <tqsignal.h>
27
#include <config.h>
28
#ifdef HAVE_DNSSD
29
#include <avahi-client/client.h>
30
#else
31
#define DNSServiceRef void*
32
#define AvahiClientState void*
33
#endif
34
35
namespace
DNSSD
36
{
37
44
class
Responder
:
public
TQObject
45
{
46
TQ_OBJECT
47
48
public
:
49
Responder
();
50
51
~
Responder
();
52
53
static
Responder
&
self
();
54
#ifdef HAVE_DNSSD
55
AvahiClientState state()
const
;
56
AvahiClient* client()
const
{
return
m_client; }
57
#endif
58
void
process();
59
signals:
60
void
stateChanged(AvahiClientState);
61
private
:
62
#ifdef HAVE_DNSSD
63
AvahiClient* m_client;
64
#endif
65
static
Responder
* m_self;
66
#ifdef HAVE_DNSSD
67
friend
void
client_callback(AvahiClient*, AvahiClientState,
void
*);
68
#endif
69
70
};
71
72
/* Utils functions */
73
74
bool
domainIsLocal(
const
TQString& domain);
75
// Encodes domain name using utf8() or IDN
76
TQCString domainToDNS(
const
TQString &domain);
77
TQString DNSToDomain(
const
char
* domain);
78
79
80
}
81
82
#endif
DNSSD::Responder
This class should not be used directly.
Definition:
responder.h:45
dnssd
Skip menu "dnssd"
Main Page
Class Hierarchy
Alphabetical List
Class List
File List
Class Members
Related Pages
dnssd
Skip menu "dnssd"
arts
dcop
dnssd
interfaces
kspeech
interface
library
tdetexteditor
kate
kded
kdoctools
kimgio
kjs
libtdemid
libtdescreensaver
tdeabc
tdecmshell
tdecore
tdefx
tdehtml
tdeinit
tdeio
bookmarks
httpfilter
kpasswdserver
kssl
tdefile
tdeio
tdeioexec
tdeioslave
http
tdemdi
tdemdi
tdenewstuff
tdeparts
tdeprint
tderandr
tderesources
tdespell2
tdesu
tdeui
tdeunittest
tdeutils
tdewallet