Package com.bitheads.braincloud.services
Class PlaybackStreamService
java.lang.Object
com.bitheads.braincloud.services.PlaybackStreamService
public class PlaybackStreamService extends Object
-
Constructor Summary
Constructors Constructor Description PlaybackStreamService(BrainCloudClient client) -
Method Summary
Modifier and Type Method Description voidaddEvent(String playbackStreamId, String eventData, String summary, IServerCallback callback)Adds a stream event Service Name - PlaybackStream Service Operation - AddEventvoiddeleteStream(String playbackStreamId, IServerCallback callback)Deletes a stream Service Name - PlaybackStream Service Operation - DeleteStreamvoidendStream(String playbackStreamId, IServerCallback callback)Ends a stream Service Name - PlaybackStream Service Operation - EndStreamvoidgetRecentStreamsForInitiatingPlayer(String initiatingPlayerId, int maxNumStreams, IServerCallback callback)Gets recent stream summaries for initiating player Service Name - PlaybackStream Service Operation - GetRecentStreamsForInitiatingPlayervoidgetRecentStreamsForTargetPlayer(String targetPlayerId, int maxNumStreams, IServerCallback callback)Gets recent stream summaries for target player Service Name - PlaybackStream Service Operation - GetRecentStreamsForTargetPlayervoidprotectStreamUntil(String playbackStreamId, int numDays, IServerCallback callback)Protects a playback stream from being purged (but not deleted) for the given number of days (from now).voidreadStream(String playbackStreamId, IServerCallback callback)Reads a stream Service Name - PlaybackStream Service Operation - ReadStreamvoidstartStream(String targetPlayerId, boolean includeSharedData, IServerCallback callback)Starts a stream Service Name - PlaybackStream Service Operation - StartStream
-
Constructor Details
-
PlaybackStreamService
-
-
Method Details
-
startStream
public void startStream(String targetPlayerId, boolean includeSharedData, IServerCallback callback)Starts a stream Service Name - PlaybackStream Service Operation - StartStream- Parameters:
targetPlayerId- The player to start a stream withincludeSharedData- Whether to include shared data in the streamcallback- The callback.
-
readStream
Reads a stream Service Name - PlaybackStream Service Operation - ReadStream- Parameters:
playbackStreamId- Identifies the stream to readcallback- The callback.
-
endStream
Ends a stream Service Name - PlaybackStream Service Operation - EndStream- Parameters:
playbackStreamId- Identifies the stream to readcallback- The callback.
-
deleteStream
Deletes a stream Service Name - PlaybackStream Service Operation - DeleteStream- Parameters:
playbackStreamId- Identifies the stream to readcallback- The callback.
-
addEvent
public void addEvent(String playbackStreamId, String eventData, String summary, IServerCallback callback)Adds a stream event Service Name - PlaybackStream Service Operation - AddEvent- Parameters:
playbackStreamId- Identifies the stream to readeventData- Describes the eventsummary- Current summary data as of this eventcallback- The callback.
-
getRecentStreamsForInitiatingPlayer
public void getRecentStreamsForInitiatingPlayer(String initiatingPlayerId, int maxNumStreams, IServerCallback callback)Gets recent stream summaries for initiating player Service Name - PlaybackStream Service Operation - GetRecentStreamsForInitiatingPlayer- Parameters:
initiatingPlayerId- The player that started the streammaxNumStreams- The max number of streams to querycallback- The callback.
-
getRecentStreamsForTargetPlayer
public void getRecentStreamsForTargetPlayer(String targetPlayerId, int maxNumStreams, IServerCallback callback)Gets recent stream summaries for target player Service Name - PlaybackStream Service Operation - GetRecentStreamsForTargetPlayer- Parameters:
targetPlayerId- The player that was target of the streammaxNumStreams- The max number of streams to querycallback- The callback.
-
protectStreamUntil
Protects a playback stream from being purged (but not deleted) for the given number of days (from now). If the number of days given is less than the normal purge interval days (from createdAt), the longer protection date is applied. Can only be called by users involved in the playback stream. Service - Playback Stream Operation - PROTECT_STREAM_UNTIL- Parameters:
playbackStreamId- Identifies the stream to protectnumDays- The number of days the stream is to be protected (from now)callback- The method to be invoked when the server response is received
-