简体   繁体   中英

how we remove a published service from NSNetService class?

how can i remove a published service from NSNetService class?

can any one tell me to do it?

or need to get my device name unique at all times(if i done more than one publish)

An NSNetService instance is scheduled on the RunLoop so that it can regularly publish the Bonjour service via the mDNSResponder and that other devices on the network keep being informed the service exists.

Simply remove the NetService from your RunLoop should do the trick. Don't forget to call -stop before, in case your NetService is currently trying to publish.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM