Class SsdpDevicePublisher
Allows publishing devices both as notification and responses to search requests.
Inherited Members
Namespace: Rssdp
Assembly: cs.temp.dll.dll
Syntax
public class SsdpDevicePublisher : SsdpDevicePublisherBase, IDisposable, ISsdpDevicePublisher
Remarks
This is the 'server' part of the system. You add your devices to an instance of this class so clients can find them.
Constructors
SsdpDevicePublisher()
Default constructor.
Declaration
public SsdpDevicePublisher()
Remarks
Uses the default ISsdpCommunicationsServer implementation and network settings for Windows and the SSDP specification.
SsdpDevicePublisher(ISsdpCommunicationsServer)
Partial constructor.
Declaration
public SsdpDevicePublisher(ISsdpCommunicationsServer communicationsServer)
Parameters
| Type | Name | Description |
|---|---|---|
| ISsdpCommunicationsServer | communicationsServer |
Remarks
Allows the caller to specify their own ISsdpCommunicationsServer implementation for full control over the networking, or for mocking/testing purposes..
SsdpDevicePublisher(ISsdpCommunicationsServer, ISsdpLogger)
Full constructor.
Declaration
public SsdpDevicePublisher(ISsdpCommunicationsServer communicationsServer, ISsdpLogger log)
Parameters
| Type | Name | Description |
|---|---|---|
| ISsdpCommunicationsServer | communicationsServer | |
| ISsdpLogger | log |
Remarks
Allows the caller to specify their own ISsdpCommunicationsServer implementation for full control over the networking, or for mocking/testing purposes..
SsdpDevicePublisher(Int32)
Partial constructor.
Declaration
public SsdpDevicePublisher(int localPort)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | localPort | The local port to use for socket communications, specify 0 to have the system choose it's own. |
Remarks
Uses the default ISsdpCommunicationsServer implementation and network settings for Windows and the SSDP specification, but specifies the local port to use for socket communications. Specify 0 to indicate the system should choose it's own port.
SsdpDevicePublisher(Int32, Int32)
Partial constructor.
Declaration
public SsdpDevicePublisher(int localPort, int multicastTimeToLive)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | localPort | The local port to use for socket communications, specify 0 to have the system choose it's own. |
| System.Int32 | multicastTimeToLive | The number of hops a multicast packet can make before it expires. Must be 1 or greater. |
Remarks
Uses the default ISsdpCommunicationsServer implementation and network settings for Windows and the SSDP specification, but specifies the local port to use and multicast time to live setting for socket communications.
Specify 0 for the localPort argument to indicate the system should choose it's own port.
The multicastTimeToLive is actually a number of 'hops' on the network and not a time based argument.
SsdpDevicePublisher(String)
Partial constructor.
Declaration
public SsdpDevicePublisher(string ipAddress)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | ipAddress | The IP address of the local network adapter to bind sockets to.
Null or empty string will use |