Stay organized with collections Save and categorize content based on your preferences.
A class that manages a Cast session with a receiver device.
Sessions are created and managed automatically by the GCKSessionManager. The application should not directly call the session lifecycle methods such as start (GCKSession(Protected)) or endWithAction: (GCKSession(Protected)).
Inherits GCKSession.
- (instancetype) initWithDevice: (GCKDevice *) device sessionID: (nullable NSString *) sessionID sessionOptions: (nullable GCKSessionOptions *) sessionOptions castOptions: (GCKCastOptions *) castOptionsConstructs a new Cast session with the given Cast options.
nil
. sessionOptions The session options, if any; otherwise nil
. castOptions The Cast options.
Registers a channel with the session.
If the session is connected and the receiver application supports the channel's namespace, the channel will be automatically connected. If the session is not connected, the channel will remain in a disconnected state until the session is started.
YES
if the channel was registered successfully, NO
otherwise.
Removes a previously registered channel from the session.
YES
if the channel was unregistered successfully, NO
otherwise.
Adds a GCKCastDeviceStatusListener to this object's list of listeners.
The added listener is weakly held, and should be retained to avoid unexpected deallocation.
Sets the individual device's volume in a multizone group.
This is an asynchronous operation.
Sets the individual device's muted state in a multizone group.
This is an asynchronous operation.
Initializes a new session object for the given device, with default options.
nil
if it will be used to start a new session.
Initializes a new session object for the given device.
nil
if it will be used to start a new session. sessionOptions The session options, if any; otherwise nil
.
Sets the device's volume.
This is an asynchronous operation. The default implementation is a no-op that fails the request with a GCKErrorCodeUnsupportedFeature error.
void
.
Sets the device's mute state.
This is an asynchronous operation. The default implementation is a no-op that fails the request with a GCKErrorCodeUnsupportedFeature error.
void
.
Starts the session.
This is an asynchronous operation. Must be overridden by subclasses.
Provided by category GCKSession(Protected).
Ends the session with the specified action.
This is an asynchronous operation. Must be overridden by subclasses.
Provided by category GCKSession(Protected).
- (void) notifyDidStartWithSessionID: (NSString *) sessionIDCalled by subclasses to notify the framework that the session has been started.
Provided by category GCKSession(Protected).
- (void) notifyDidFailToStartWithError: (GCKError *) errorCalled by subclasses to notify the framework that the session has failed to start.
Provided by category GCKSession(Protected).
- (void) notifyDidEndWithError: (nullable NSError *) error willTryToResume: (BOOL) willTryToResumeCalled by subclasses to notify the framework that the session has ended.
nil
if the session was ended intentionally. willTryToResume Whether the session will try to resume itself automatically.
Provided by category GCKSession(Protected).
- (void) notifyDidReceiveDeviceVolume: (float) volume muted: (BOOL) mutedCalled by subclasses to notify the framework that updated device volume and mute state has been received from the device.
Provided by category GCKSession(Protected).
- (void) notifyDidReceiveDeviceStatus: (nullable NSString *) statusTextCalled by subclasses to notify the framework that updated status has been received from the device.
Provided by category GCKSession(Protected).
- (GCKActiveInputStatus) activeInputStatus readnonatomicassignThe device's current "active input" status.
- (GCKStandbyStatus) standbyStatus readnonatomicassignThe device's current "standby" status.
The metadata for the receiver application that is currently running on the receiver device, if any; otherwise nil
.
The device that this session is associated with.
readnonatomiccopyinheritedThe current session ID, if any.
- (GCKSessionOptions*) sessionOptions readnonatomicstronginheritedThe session options, if any.
The current session connection state.
readnonatomicassigninheritedA flag indicating whether the session is currently suspended.
The current device status text.
readnonatomiccopyinheritedThe session traits.
- (float) currentDeviceVolume readnonatomicassigninheritedThe current device volume, in the range [0.0, 1.0].
- (BOOL) currentDeviceMuted readnonatomicassigninheritedThe current device mute state.
readnonatomicstronginherited readnonatomicstronginheritedThe current media metadata, if any.
Will be nil
if the session does not support the media namespace or if no media is currently loaded on the receiver.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-18 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-09-18 UTC."],[[["`GCKCastSession` manages a Cast session and its lifecycle, including channels, device status, and volume control, but applications should avoid directly managing the session's start and end."],["`GCKCastSession` provides properties for accessing session status, device information (like volume and mute state), and media control via `remoteMediaClient`."],["`GCKSession` is an abstract base class for Cast sessions, requiring subclasses to implement session start/end logic and provides properties for session status, device details, and media information."],["Subclasses of `GCKSession` use protected methods to notify the framework about session lifecycle events like start, end, errors, and device status changes."]]],["The `GCKCastSession` class manages Cast sessions, created by `GCKSessionManager`. Key actions include constructing sessions with options, registering/removing channels, and adding/removing device status listeners. It supports setting device volume and mute states, requesting multizone status, and controlling media playback. Subclasses use methods to notify the framework about session lifecycle events, device status, and connection status. It provides properties for session, device, and media status, with deprecated methods.\n"]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4