停止来自蓝牙 GKSession 的不相关日志?
如何在GKSession
开始搜索时停止以下代码?
BTM: posting notification BluetoothAvailabilityChangedNotification
2011-05-17 20:25:05.666 BLUConnect[2120:307] BTM: Adding new device 0x110db0 Jahangir Nawaz’s iPhone 00:23:DF:3C:BC:5B 0xf5210003
2011-05-17 20:25:05.669 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:06.406 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
2011-05-17 20:25:06.466 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 11 result = 305
2011-05-17 20:25:06.491 BLUConnect[2120:307] BTM: received BT_SERVICE_CONNECT event type with 0 currently connected services
2011-05-17 20:25:06.494 BLUConnect[2120:307] BTM: posting notification BluetoothDeviceConnectFailedNotification
2011-05-17 20:25:07.467 BLUConnect[2120:307] BTM: received BT_LOCAL_DEVICE_CONNECTION_STATUS_CHANGED event
2011-05-17 20:25:07.469 BLUConnect[2120:307] BTM: posting notification BluetoothConnectionStatusChangedNotification
2011-05-17 20:25:11.571 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:12.576 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
2011-05-17 20:25:13.581 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 11 result = 305
2011-05-17 20:25:13.590 BLUConnect[2120:307] BTM: received BT_SERVICE_CONNECT event type with 0 currently connected services
2011-05-17 20:25:13.591 BLUConnect[2120:307] BTM: posting notification BluetoothDeviceConnectFailedNotification
2011-05-17 20:25:14.587 BLUConnect[2120:307] BTM: received BT_LOCAL_DEVICE_CONNECTION_STATUS_CHANGED event
2011-05-17 20:25:14.589 BLUConnect[2120:307] BTM: posting notification BluetoothConnectionStatusChangedNotification
2011-05-17 20:25:15.594 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:16.598 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
2011-05-17 20:25:17.604 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 11 result = 305
2011-05-17 20:25:17.613 BLUConnect[2120:307] BTM: received BT_SERVICE_CONNECT event type with 0 currently connected services
2011-05-17 20:25:17.614 BLUConnect[2120:307] BTM: posting notification BluetoothDeviceConnectFailedNotification
2011-05-17 20:25:18.611 BLUConnect[2120:307] BTM: received BT_LOCAL_DEVICE_CONNECTION_STATUS_CHANGED event
2011-05-17 20:25:18.613 BLUConnect[2120:307] BTM: posting notification BluetoothConnectionStatusChangedNotification
2011-05-17 20:25:19.618 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:20.624 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
How to stop the following code when GKSession
starts search?
BTM: posting notification BluetoothAvailabilityChangedNotification
2011-05-17 20:25:05.666 BLUConnect[2120:307] BTM: Adding new device 0x110db0 Jahangir Nawaz’s iPhone 00:23:DF:3C:BC:5B 0xf5210003
2011-05-17 20:25:05.669 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:06.406 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
2011-05-17 20:25:06.466 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 11 result = 305
2011-05-17 20:25:06.491 BLUConnect[2120:307] BTM: received BT_SERVICE_CONNECT event type with 0 currently connected services
2011-05-17 20:25:06.494 BLUConnect[2120:307] BTM: posting notification BluetoothDeviceConnectFailedNotification
2011-05-17 20:25:07.467 BLUConnect[2120:307] BTM: received BT_LOCAL_DEVICE_CONNECTION_STATUS_CHANGED event
2011-05-17 20:25:07.469 BLUConnect[2120:307] BTM: posting notification BluetoothConnectionStatusChangedNotification
2011-05-17 20:25:11.571 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:12.576 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
2011-05-17 20:25:13.581 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 11 result = 305
2011-05-17 20:25:13.590 BLUConnect[2120:307] BTM: received BT_SERVICE_CONNECT event type with 0 currently connected services
2011-05-17 20:25:13.591 BLUConnect[2120:307] BTM: posting notification BluetoothDeviceConnectFailedNotification
2011-05-17 20:25:14.587 BLUConnect[2120:307] BTM: received BT_LOCAL_DEVICE_CONNECTION_STATUS_CHANGED event
2011-05-17 20:25:14.589 BLUConnect[2120:307] BTM: posting notification BluetoothConnectionStatusChangedNotification
2011-05-17 20:25:15.594 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:16.598 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
2011-05-17 20:25:17.604 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 11 result = 305
2011-05-17 20:25:17.613 BLUConnect[2120:307] BTM: received BT_SERVICE_CONNECT event type with 0 currently connected services
2011-05-17 20:25:17.614 BLUConnect[2120:307] BTM: posting notification BluetoothDeviceConnectFailedNotification
2011-05-17 20:25:18.611 BLUConnect[2120:307] BTM: received BT_LOCAL_DEVICE_CONNECTION_STATUS_CHANGED event
2011-05-17 20:25:18.613 BLUConnect[2120:307] BTM: posting notification BluetoothConnectionStatusChangedNotification
2011-05-17 20:25:19.618 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0xffffffff eventType = 0 event = 0 result = 0
2011-05-17 20:25:20.624 BLUConnect[2120:307] BTM: _btServiceEventCallback: service = 0x800 eventType = 0 event = 1 result = 0
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我认为这是在苹果的库中,似乎没有直接的方法可以关闭它 - 我会提交一个“错误”票......
我很确定,不可能重载/覆盖 NSLog 方法为了避免这些日志。
请问是否有特殊需要关闭此功能?
您好,
马蒂亚斯
I think this is within Apple's lib, it seems that there is no direct way of switching it off - I would submit a "bug" ticket ...
I'm pretty sure, that it is not possible to overload/overwrite the NSLog method in order to avoid those logs.
May I ask whether there is a specific need for switching this off?
Greetings,
matthias
这是不可能的。日志会自动按照苹果提供的创建和使用 GKSession 的方法执行。除了减少控制台中的混乱之外,我看不出有任何需要关闭它们的合理理由。
干杯,
西德
This is impossible. The logs happen automatically do to the methods apple give you to create and use GKSessions. I can't see any legitimate reason for NEEDING to switch them off other than to reduce clutter in your console.
Cheers,
Sidd