附近的Android找不到IOS

时间:2018-12-12 23:26:22

标签: android google-nearby

我需要帮助来检测Android设备-Android和Android-IOS。 我可以在Android上找到Android,但IOS找不到。

class NearbyActivity{

....

 val major = preferenceUser.getMajor()!!.toShort()
             val minor = preferenceUser.getMinor()!!.toShort()

             var uuid = UUID.randomUUID()
             val messageFilter = MessageFilter.Builder()
                     .includeIBeaconIds(uuid, major, minor)
                     .includeNamespacedType("my_app", Message.MESSAGE_TYPE_I_BEACON_ID)
                     .build()



            val options = SubscribeOptions.Builder()
                    .setStrategy(Strategy.BLE_ONLY)
                    .setFilter(messageFilter)
                    .build()



            mMessagesListener?.let { mMsgListener ->
                //mMsgCliente.subscribe(mMessagesListener!!, options)
                Nearby.getMessagesClient(activity!!).subscribe(mMsgListener, options)

....
}

0 个答案:

没有答案