• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • dnssd
 

dnssd

  • dnssd
sdevent.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 DNSSDSDEVENT_H
22 #define DNSSDSDEVENT_H
23 
24 #include <tqevent.h>
25 #include <tqstring.h>
26 #include <tqmap.h>
27 
28 namespace DNSSD
29 {
30 
31 enum Operation { SD_ERROR = 101,SD_ADDREMOVE, SD_PUBLISH, SD_RESOLVE};
32 
33 class ErrorEvent : public TQCustomEvent
34 {
35 public:
36  ErrorEvent() : TQCustomEvent(TQEvent::User+SD_ERROR)
37  {}
38 };
39 class AddRemoveEvent : public TQCustomEvent
40 {
41 public:
42  enum Operation { Add, Remove };
43  AddRemoveEvent(Operation op,const TQString& name,const TQString& type,
44  const TQString& domain) : TQCustomEvent(TQEvent::User+SD_ADDREMOVE),
45  m_op(op), m_name(name), m_type(type), m_domain(domain)
46  {}
47 
48  const Operation m_op;
49  const TQString m_name;
50  const TQString m_type;
51  const TQString m_domain;
52 };
53 
54 class PublishEvent : public TQCustomEvent
55 {
56 public:
57  PublishEvent(bool ok) : TQCustomEvent(TQEvent::User+SD_PUBLISH), m_ok(ok)
58  {}
59 
60  bool m_ok;
61 };
62 
63 class ResolveEvent : public TQCustomEvent
64 {
65 public:
66  ResolveEvent(const TQString& hostname, unsigned short port,
67  const TQMap<TQString,TQString>& txtdata)
68  : TQCustomEvent(TQEvent::User+SD_RESOLVE), m_hostname(hostname),
69  m_port(port), m_txtdata(txtdata)
70  {}
71 
72  const TQString m_hostname;
73  const unsigned short m_port;
74  const TQMap<TQString,TQString> m_txtdata;
75 };
76 
77 
78 }
79 
80 #endif
DNSSD
Definition: domainbrowser.cpp:36

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
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for dnssd by doxygen 1.8.11
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |