Exemplo n.º 1
0
 /// <summary>
 ///   Creates a new instance of the <see cref="ServiceDiscovery"/> class with
 ///   the specified <see cref="MulticastService"/>.
 /// </summary>
 /// <param name="mdns">
 ///   The underlaying <see cref="MulticastService"/> to use.
 /// </param>
 public ServiceDiscovery(MulticastService mdns)
 {
     this.Mdns            = mdns;
     mdns.QueryReceived  += OnQuery;
     mdns.AnswerReceived += OnAnswer;
 }
Exemplo n.º 2
0
 // Enforce multicast defaults, especially TTL.
 static ServiceProfile()
 {
     // Make sure MulticastService is inited.
     MulticastService.ReferenceEquals(null, null);
 }