Methods
(static) close(callback, id)
Cleanup and close any pending lookups.
Parameters:
Name | Type | Description |
---|---|---|
callback |
function | The return callback. Returns an object with error field in case of failure. |
id |
integer | The mDNS object id returned from the 'create' API. |
(static) create(callback)
This function creates and returns a mDNS object.
Parameters:
Name | Type | Description |
---|---|---|
callback |
function | The return callback. Returns the object id or an object with error field in case of failure. |
(static) discovery(callback, id, timeout)
Perform mDNS service search.
Parameters:
Name | Type | Description |
---|---|---|
callback |
function | The return callback. Returns the responses or an object with error field in case of failure. |
id |
integer | The mDNS object id returned from the 'create' API. |
timeout |
integer | The time to wait for responses (seconds). |