We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have a lot of devices and I want to group them by service, can you do it? ex: makeDiscoverable (String hostName, String serviceName);
makeDiscoverable ("My android device", "printer.tcp");
Look for devices that have the "printer.tcp" service registered instead of searching for them all startDiscovery ("printer.tcp")
The text was updated successfully, but these errors were encountered:
This doesn't work. But even if it did, everything is searched and then filterd out. (No performance advantage)
And you can build a filter by yourself (e.g. a specific string inside the hostname)
Sorry, something went wrong.
When @adroitandroid creates Release v2.0 you can use it like this:
val nearDiscovery = NearDiscovery.Builder() .setContext(this) .setDiscoverableTimeoutMillis(DISCOVERABLE_TIMEOUT_MILLIS) .setDiscoveryTimeoutMillis(DISCOVERY_TIMEOUT_MILLIS) .setDiscoverablePingIntervalMillis(DISCOVERABLE_PING_INTERVAL_MILLIS) .setDiscoveryListener(getNearDiscoveryListener(), Looper.getMainLooper()) .setFilter(Regex("printer.tcp")) // shows only devices with parameter "printer.tcp" .build()
NearDiscovery nearDiscovery = new NearDiscovery.Builder() .setContext(this) .setDiscoverableTimeoutMillis(DISCOVERABLE_TIMEOUT_MILLIS) .setDiscoveryTimeoutMillis(DISCOVERY_TIMEOUT_MILLIS) .setDiscoverablePingIntervalMillis(DISCOVERABLE_PING_INTERVAL_MILLIS) .setDiscoveryListener(getNearDiscoveryListener(), Looper.getMainLooper()) .setFilter(Regex("printer.tcp")) // shows only devices with parameter "printer.tcp" .build()
nearDiscovery.makeDiscoverable("hostName", "printer.tcp")
And the issue can be closed then
No branches or pull requests
I have a lot of devices and I want to group them by service, can you do it?
ex:
makeDiscoverable (String hostName, String serviceName);
makeDiscoverable ("My android device", "printer.tcp");
Look for devices that have the "printer.tcp" service registered instead of searching for them all
startDiscovery ("printer.tcp")
The text was updated successfully, but these errors were encountered: