/// <summary> /// Create Properties Json. /// </summary> /// <param name="fileName">File name of the current media content </param> /// <param name="title">Media title </param> /// <param name="genre">Media genre </param> /// <param name="language">Media language </param> /// <param name="year">Media year </param> /// <param name="cast">Media cast. Separate each name with commas </param> /// <param name="director">Media director or directors. Separate each value with commas </param> /// <param name="owner">Media's content owner </param> /// <param name="duration">Length of the media in seconds </param> /// <param name="parental">Recommended viewing age (All,+13,+18,Adult) </param> /// <param name="price">Purchase price on the website </param> /// <param name="rating">Average value on your user's perception on the content quality, performance... </param> /// <param name="audioType">Media file type of audio (Mono, Stereo, Dolby,…) </param> /// <param name="audioChannels">Number of media file channels (1, 5.1, …) </param> /// <param name="contentId">Internal ID for the media </param> /// <param name="transactionType">Rent: Media for rental Subscription: Media which has been acquired as part of a subscription EST (Electronic Sell Through): Media purchased Free: Media which has no economical transaction </param> /// <param name="quality">HD or SD </param> /// <param name="contentType">Trailer, Episode, Movie </param> /// <param name="manufacturer">Manufacturer of the device</param> /// <param name="deviceType">TV, Blu-Ray, Set-Top Box </param> /// <param name="deviceYear">Fabrication year </param> /// <param name="firmware">Firmware version</param> /// <returns>Json</returns> public static string CreateJsonProperties( string fileName, string title, string genre, string language, string year, string cast, string director, string owner, long duration, Parental parental, double price, string rating, AudioType audioType, double audioChannels, string contentId, TransactionType transactionType, Quality quality, ContentType contentType, string manufacturer, string deviceType, string deviceYear, string firmware) { return String.Format( @"{{""filename"":""{0}"",""content_metadata"":{{""title"":""{1}"",""genre"":""{2}"",""language"":""{3}"",""year"":""{4}"",""cast"":""{5}"",""director"":""{6}"",""owner"":""{7}"",""duration"":""{8}"",""parental"":""{9}"",""price"":""{10}"",""rating"":""{11}"",""audioType"":""{12}"",""audioChannels"":""{13}"",""duration"":""{14}""}},""quality"":""{15}"",""content_type"":""{16}"",""transaction_type"":""{17}"",""device"":{{""manufacturer"":""{18}"",""type"":""{19}"",""year"":""{20}"",""firmware"":""{21}""}},}}", fileName, title, genre, language, year, cast, director, owner, duration, parental, price, rating, audioType, audioChannels, duration, quality, contentType, transactionType, manufacturer, deviceType, deviceYear, firmware); }
/// <summary> /// Create Properties Json. /// </summary> /// <param name="fileName">File name of the current media content </param> /// <param name="title">Media title </param> /// <param name="genre">Media genre </param> /// <param name="language">Media language </param> /// <param name="year">Media year </param> /// <param name="cast">Media cast. Separate each name with commas </param> /// <param name="director">Media director or directors. Separate each value with commas </param> /// <param name="owner">Media's content owner </param> /// <param name="duration">Length of the media in seconds </param> /// <param name="parental">Recommended viewing age (All,+13,+18,Adult) </param> /// <param name="price">Purchase price on the website </param> /// <param name="rating">Average value on your user's perception on the content quality, performance... </param> /// <param name="audioType">Media file type of audio (Mono, Stereo, Dolby,…) </param> /// <param name="audioChannels">Number of media file channels (1, 5.1, …) </param> /// <param name="contentId">Internal ID for the media </param> /// <param name="transactionType">Rent: Media for rental Subscription: Media which has been acquired as part of a subscription EST (Electronic Sell Through): Media purchased Free: Media which has no economical transaction </param> /// <param name="quality">HD or SD </param> /// <param name="contentType">Trailer, Episode, Movie </param> /// <param name="manufacturer">Manufacturer of the device</param> /// <param name="deviceType">TV, Blu-Ray, Set-Top Box </param> /// <param name="deviceYear">Fabrication year </param> /// <param name="firmware">Firmware version</param> /// <returns>Json</returns> public static string CreateProperties( string fileName, string title, string genre, string language, string year, string cast, string director, string owner, long duration, Parental parental, double price, string rating, AudioType audioType, double audioChannels, string contentId, TransactionType transactionType, Quality quality, ContentType contentType, string manufacturer, string deviceType, string deviceYear, string firmware) { return StartApi.CreateJsonProperties( fileName, title, genre, language, year, cast, director, owner, duration, parental, price, rating, audioType, audioChannels, contentId, transactionType, quality, contentType, manufacturer, deviceType, deviceYear, firmware); }