![]() |
Home · Modules · Classes · Namespaces · Functions |
The QxtDiscoverableService class registers a service that can be discovered with Zeroconf, or resolve such a service More...
#include <QxtDiscoverableService>
Inherits QObject.
The QxtDiscoverableService class registers a service that can be discovered with Zeroconf, or resolve such a service
QxtDiscoverableService represents a service on the local network that can be discovered using Zeroconf. It can function to provide such a service so that other systems on the network can find it, or it can resolve the connection parameters for a service provided by another system on the network. Note that resolving a service requires that you already know the service name in addition to the service type for the remote service; to find all services on the network that offer a given service type, use QxtServiceBrowser.
When registering a service, you may specify a set of service subtypes to indicate what kind of optional capabilities your service offers. Other applications browsing for discoverable services (for instance, using QxtServiceBrowser) can limit their search to only those services that provide a given subtype. Use the properties inherited from QxtDiscoverableServiceName to configure the other service parameters.
For more information about Zeroconf, see the documentation available on www.zeroconf.org.
See also QxtDiscoverableServiceName and QxtServiceBrowser.
The ServiceFlags type is a typedef for QFlags<ServiceFlag>. It stores an OR combination of ServiceFlag values.
Constructs a QxtDiscoverableService object using the specified service type.
The service type may be a plain type name or it may be provided in the standard format specified by the Zeroconf specification.
The service name will be automatically generated based on the system's hostname.
Constructs a QxtDiscoverableService object using the specified service type.
The service type may be a plain type name or it may be provided in the standard format specified by the Zeroconf specification.
If the specified service name is already in use, it will be updated with a number to make it unique.
Destroys the QxtDiscoverableService.
TIf registered, the service will be unregistered.
Adds a subtype to the service.
See also serviceSubTypes, setServiceSubTypes, removeServiceSubType, and hasServiceSubType.
Tests to see if the specified service is available and known for the service.
When discovering a service, only subtypes that were included in the service discovery request will be available.
See also serviceSubTypes, setServiceSubTypes, addServiceSubType, and removeServiceSubType.
Returns the port number used for connecting to the service.
See also setPort.
Attempts to register the service on the local network.
If noAutoRename is set to true, registration will fail if another service of the same service type is already registered with the same service name. Otherwise, the service name will be updated with a number to make it unique.
See also registered and registrationError.
Releases the service.
If the service is registered, it will be unregistered. Any outstanding resolve attempt will be aborted.
Removes a subtype from the service.
See also serviceSubTypes, setServiceSubTypes, addServiceSubType, and hasServiceSubType.
Attempts to resolve the service in order to determine the host and port necessary to establish a connection.
If forceMulticast is set to true, QxtDiscoverableService will use a multicast request to resolve the service, even if the host name appears to be a unicast address (that is, outside the local network).
See also resolved and resolveError.
Returns a list of all subtypes known for the service.
When discovering a service, only subtypes that were included in the service discovery request will be included in this list.
See also setServiceSubTypes, addServiceSubType, removeServiceSubType, and hasServiceSubType.
Sets the port number used for connecting to the service.
When registering a service with a port number of 0 (the default), the service will not be found when browsing, but the service name will be marked as reserved.
Setting the port is only meaningful when registering a service.
See also port.
Sets the list of subtypes for this service.
See also serviceSubTypes, addServiceSubType, removeServiceSubType, and hasServiceSubType.
Returns the current state of the service.
Copyright © 2007-2010 Qxt Foundation |
Qxt 0.6.1 |