JWJSONParser
@objcMembers
final public class JWJSONParser : NSObject
This JSON parser helps to convert a json object into a JWPlayerConfiguration using the different configuration builders provided by JWPlayerKit.
-
Convert the content of a file into a
JWPlayerConfiguration.Note
The provided file must follow a proper JSON format.Throws
An error if the file can not be converted properly.Declaration
Swift
public static func configFromUrl(_ url: URL) throws -> JWPlayerConfigurationParameters
urlThe
URLto read.Return Value
A
JWPlayerConfigurationused to configure aJWPlayer. -
Convert a JSON object into a
JWPlayerConfiguration.Throws
An error if the json data can not be converted properly.Declaration
Swift
public static func configFromJSON(_ jsonData: Data) throws -> JWPlayerConfigurationParameters
jsonDataThe JSON data.
Return Value
A
JWPlayerConfigurationused to configure aJWPlayer.
JWJSONParser Class Reference