ios版本:iOS 10.3 使用发布的ios sdk v3.4
嗨,我无法获得GCKCastOptions的'setSuspendSessionsWhenBackgrounded'选项。我确实将选项设置为YES以在后台控制MPRemoteCommandCenter上的CastSession的RemoteMediaClient。
但是当我在后台使用MPRemoteCommandCenter控制RemoteMediaClient时,我在记录器上收到此错误消息,并且castSession将暂停。
[--Logger--] __46-[GCKNSSLSocket sslPrivateInitWithBufferSize:]_block_invoke [(null)] Error reading from SSL buffer to stream buffer, status: -9805
[--Logger--] __46-[GCKNSSLSocket sslPrivateInitWithBufferSize:]_block_invoke.23 [(null)] Error writing from stream buffer to SSL buffer, status: -9805
[--Logger--] __46-[GCKNSSLSocket sslPrivateInitWithBufferSize:]_block_invoke.23 [(null)] Error writing from stream buffer to SSL buffer, status: -9805
[--Logger--] __46-[GCKNSSLSocket sslPrivateInitWithBufferSize:]_block_invoke.23 [(null)] Error writing from stream buffer to SSL buffer, status: -9805
[--Logger--] __46-[GCKNSSLSocket sslPrivateInitWithBufferSize:]_block_invoke.23 [(null)] Error writing from stream buffer to SSL buffer, status: -9805
[--Logger--] -[GCKCastDeviceConnector heartbeatChannelDidTimeout:] Receiver not responding to heartbeat, disconnecting.
我收到了这个错误,但GCKCastSession&的状态GCKSession stil的状态是GCKConnectionStateConnected。
当我收到错误消息时,打印sessionManager的连接状态。
GCKSessionManager *sessionManager = [GCKCastContext sharedInstance].sessionManager;
sessionManager.hasConnectedSession ==> YES;
sessionManager.hasConnectedCastSession ==> YES;
sessionManager.currentSession.connectionState ==> GCKConnectionStateConnected
sessionManager.currentCastSession.connectionState ==> GCKConnectionStateConnected
我认为如果GCKSession改变了断开连接状态或断开状态,也将会话状态设置为GCKConnectionStateDisconnected。
1)当我收到错误消息时,有没有办法获得GCKSession&的有效连接状态。 GCKCastSession?
2)如何在GCKSession超时后收到通知?