DNSSD
dummy-publicservice.cpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #include "publicservice.h"
00022 #include "servicebase_p.h"
00023 #include <QtCore/QStringList>
00024
00025 namespace DNSSD
00026 {
00027
00028 PublicService::PublicService(const QString& name, const QString& type, unsigned int port,
00029 const QString& domain, const QStringList&)
00030 : QObject(), ServiceBase(name, type, QString(), domain, port)
00031 {
00032 if (domain.isNull()) d->m_domain=QLatin1String("local.");
00033 }
00034
00035
00036 PublicService::~PublicService()
00037 {}
00038
00039 void PublicService::setServiceName(const QString& serviceName)
00040 {
00041 d->m_serviceName = serviceName;
00042 }
00043
00044 void PublicService::setDomain(const QString& domain)
00045 {
00046 d->m_domain = domain;
00047 }
00048
00049 void PublicService::setTextData(const QMap<QString,QByteArray>& textData)
00050 {
00051 d->m_textData = textData;
00052 }
00053
00054 void PublicService::setType(const QString& type)
00055 {
00056 d->m_type = type;
00057 }
00058
00059 void PublicService::setSubTypes(const QStringList&)
00060 {
00061
00062 }
00063
00064 void PublicService::setPort(unsigned short port)
00065 {
00066 d->m_port = port;
00067 }
00068
00069 QStringList PublicService::subtypes() const
00070 {
00071 return QStringList();
00072 }
00073
00074 bool PublicService::isPublished() const
00075 {
00076 return false;
00077 }
00078
00079 bool PublicService::publish()
00080 {
00081 return false;
00082 }
00083
00084 void PublicService::stop()
00085 {}
00086
00087 void PublicService::publishAsync()
00088 {
00089 emit published(false);
00090 }
00091
00092 void PublicService::virtual_hook(int, void*)
00093 {
00094 }
00095
00096 }
00097
00098 #include "publicservice.moc"