Loading...
Searching...
No Matches
NetworkServiceDiscovery::Advertiser Struct Reference

An object which runs a thread to repeatedly broadcast the existence of a discoverable service. More...

#include <juce_NetworkServiceDiscovery.h>

Inheritance diagram for NetworkServiceDiscovery::Advertiser:

Public Member Functions

 Advertiser (const String &serviceTypeUID, const String &serviceDescription, int broadcastPort, int connectionPort, RelativeTime minTimeBetweenBroadcasts=RelativeTime::seconds(1.5))
 Creates and starts an Advertiser thread, broadcasting with the given properties.
 
 ~Advertiser () override
 Destructor.
 

Detailed Description

An object which runs a thread to repeatedly broadcast the existence of a discoverable service.

To use, simply create an instance of an Advertiser and it'll broadcast until you delete it.

Constructor & Destructor Documentation

◆ Advertiser()

NetworkServiceDiscovery::Advertiser::Advertiser ( const String & serviceTypeUID,
const String & serviceDescription,
int broadcastPort,
int connectionPort,
RelativeTime minTimeBetweenBroadcasts = RelativeTime::seconds(1.5) )

Creates and starts an Advertiser thread, broadcasting with the given properties.

Parameters
serviceTypeUIDA user-supplied string to define the type of service this represents
serviceDescriptionA description string that will appear in the Service::description field for clients
broadcastPortThe port number on which to broadcast the service discovery packets
connectionPortThe port number that will be sent to appear in the Service::port field
minTimeBetweenBroadcastsThe interval to wait between sending broadcast messages

◆ ~Advertiser()

NetworkServiceDiscovery::Advertiser::~Advertiser ( )
override

Destructor.


The documentation for this struct was generated from the following file:
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram