JWGoogleDAIStreamBuilder
@objcMembers
public class JWGoogleDAIStreamBuilder : NSObject, JWBuilder
The builder for JWGoogleDAIStream, object used to play ads using the DAI client.
-
Declaration
Swift
public typealias Output = JWGoogleDAIStream
-
Builds a
JWGoogleDAIStream
structure for use in Google DAI ads.Throws
throws An error if the stream is not setup properly.Declaration
Swift
@objc public func build() throws -> JWGoogleDAIStream
-
Sets the video and content source identifiers for the stream.
Note
Used for VoD. If live stream information is also set usingliveStreamInfo()
, callingbuild()
will throw an exception.Declaration
Swift
@discardableResult public func vodStreamInfo(videoID: String, cmsID: String) -> JWGoogleDAIStreamBuilder
Parameters
videoID
The video identifier for the stream.
cmsID
The content source identifier for the stream.
Return Value
The builder, so setters can be chained.
-
Sets the asset key for the stream.
Note
Used for live streams. If VoD stream information is also set usingvodStreamInfo()
, callingbuild()
will throw an exception.Declaration
Swift
@discardableResult public func liveStreamInfo(assetKey: String) -> JWGoogleDAIStreamBuilder
Parameters
assetKey
The stream’s asset key.
Return Value
The builder, so setters can be chained.
-
Sets the advertising configuration’s API key.
Declaration
Swift
@discardableResult public func apiKey(_ apiKey: String) -> JWGoogleDAIStreamBuilder
Parameters
apiKey
A stream request API key that is used to verify applications.
Return Value
The builder, so setters can be chained.
-
Sets ad tag parameters to be overridden on your stream request.
Declaration
Swift
@discardableResult public func adTagParameters(_ adTagParameters: [String : String]) -> JWGoogleDAIStreamBuilder
Parameters
adTagParameters
A limited set of ad tag parameters to be overridden on your stream request.
Return Value
The builder, so setters can be chained.