--- /dev/null
+using System;\r
+using System.Collections.Generic;\r
+using System.Linq;\r
+using System.Text;\r
+using System.Xml.Serialization;\r
+\r
+namespace HandBrake.Interop\r
+{\r
+ public class EncodeJob\r
+ {\r
+ public SourceType SourceType { get; set; }\r
+ public string SourcePath { get; set; }\r
+\r
+ /// <summary>\r
+ /// Gets or sets the 1-based index of the title to encode.\r
+ /// </summary>\r
+ public int Title { get; set; }\r
+\r
+ /// <summary>\r
+ /// Gets or sets the angle to encode. 0 for default, 1+ for specified angle.\r
+ /// </summary>\r
+ public int Angle { get; set; }\r
+ public int ChapterStart { get; set; }\r
+ public int ChapterEnd { get; set; }\r
+\r
+ /// <summary>\r
+ /// Gets or sets the list of chosen audio tracks (1-based)\r
+ /// </summary>\r
+ public List<int> ChosenAudioTracks { get; set; }\r
+ public Subtitles Subtitles { get; set; }\r
+ public bool UseDefaultChapterNames { get; set; }\r
+ public List<string> CustomChapterNames { get; set; }\r
+\r
+ public string OutputPath { get; set; }\r
+\r
+ public EncodingProfile EncodingProfile { get; set; }\r
+\r
+ // The length of video to encode.\r
+ [XmlIgnore]\r
+ public TimeSpan Length { get; set; }\r
+\r
+ [XmlElement("Length")]\r
+ public string XmlLength\r
+ {\r
+ get { return this.Length.ToString(); }\r
+ set { this.Length = TimeSpan.Parse(value); }\r
+ }\r
+\r
+ public EncodeJob Clone()\r
+ {\r
+ EncodeJob clone = new EncodeJob\r
+ {\r
+ SourceType = this.SourceType,\r
+ SourcePath = this.SourcePath,\r
+ Title = this.Title,\r
+ ChapterStart = this.ChapterStart,\r
+ ChapterEnd = this.ChapterEnd,\r
+ ChosenAudioTracks = new List<int>(this.ChosenAudioTracks),\r
+ Subtitles = this.Subtitles,\r
+ UseDefaultChapterNames = this.UseDefaultChapterNames,\r
+ OutputPath = this.OutputPath,\r
+ EncodingProfile = this.EncodingProfile,\r
+ Length = this.Length\r
+ };\r
+\r
+ return clone;\r
+ }\r
+ }\r
+}\r