]> granicus.if.org Git - handbrake/commitdiff
AppServices Tidyup Contd
authorScott <sr55.hb@outlook.com>
Sat, 26 Sep 2015 20:58:03 +0000 (21:58 +0100)
committerScott <sr55.hb@outlook.com>
Sat, 26 Sep 2015 20:58:03 +0000 (21:58 +0100)
Made most of the exposed objects immutable.

13 files changed:
win/CS/HandBrake.ApplicationServices/Interop/HandBrakeEncoderHelpers.cs
win/CS/HandBrake.ApplicationServices/Interop/HandBrakeUnitConversionHelpers.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/BitrateLimits.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Encoding/HBAudioEncoder.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Encoding/HBContainer.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Encoding/HBMixdown.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Encoding/HBRate.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Encoding/HBVideoEncoder.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Language.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/RangeLimits.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/Size.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/SourceVideoInfo.cs
win/CS/HandBrake.ApplicationServices/Interop/Model/VideoQualityLimits.cs

index cddfd363447141f8143ff8615723c90d0cee90a5..67f1c5483b86dd8686f3b73ea7ec1578a71a94f4 100644 (file)
@@ -486,7 +486,7 @@ namespace HandBrake.ApplicationServices.Interop
 \r
             HBFunctions.hb_audio_bitrate_get_limits((uint)encoder.Id, sampleRate, mixdown.Id, ref low, ref high);\r
 \r
-            return new BitrateLimits { Low = low, High = high };\r
+            return new BitrateLimits(low, high);\r
         }\r
 \r
         /// <summary>\r
@@ -507,13 +507,7 @@ namespace HandBrake.ApplicationServices.Interop
 \r
             HBFunctions.hb_video_quality_get_limits((uint)encoder.Id, ref low, ref high, ref granularity, ref direction);\r
 \r
-            return new VideoQualityLimits\r
-                {\r
-                    Low = low, \r
-                    High = high, \r
-                    Granularity = granularity, \r
-                    Ascending = direction == 0\r
-                };\r
+            return new VideoQualityLimits(low, high, granularity, direction == 0);\r
         }\r
 \r
         /// <summary>\r
@@ -574,13 +568,7 @@ namespace HandBrake.ApplicationServices.Interop
             int direction = 0;\r
             HBFunctions.hb_audio_quality_get_limits((uint)encoderId, ref low, ref high, ref granularity, ref direction);\r
 \r
-            return new RangeLimits\r
-            {\r
-                Low = low, \r
-                High = high, \r
-                Granularity = granularity, \r
-                Ascending = direction == 0\r
-            };\r
+            return new RangeLimits(direction == 0, granularity, high, low);\r
         }\r
 \r
         /// <summary>\r
@@ -598,13 +586,7 @@ namespace HandBrake.ApplicationServices.Interop
             int direction = 0;\r
             HBFunctions.hb_audio_compression_get_limits((uint)encoderId, ref low, ref high, ref granularity, ref direction);\r
 \r
-            return new RangeLimits\r
-            {\r
-                Low = low, \r
-                High = high, \r
-                Granularity = granularity, \r
-                Ascending = direction == 0\r
-            };\r
+            return new RangeLimits(direction == 0, granularity, high, low);\r
         }\r
 \r
         /// <summary>\r
index 7b981b7af5cf12c56a6ac8d43e51ab7f2a3b7fcb..2f01e18258e8a253f10a204f5382c67e61114e7a 100644 (file)
@@ -75,13 +75,7 @@ namespace HandBrake.ApplicationServices.Interop
         /// </returns>\r
         internal static HBVideoEncoder NativeToVideoEncoder(hb_encoder_s encoder)\r
         {\r
-            return new HBVideoEncoder\r
-            {\r
-                Id = encoder.codec, \r
-                ShortName = encoder.short_name, \r
-                DisplayName = encoder.name, \r
-                CompatibleContainers = encoder.muxers\r
-            };\r
+            return new HBVideoEncoder(encoder.muxers, encoder.name, encoder.codec, encoder.short_name);\r
         }\r
 \r
         /// <summary>\r
@@ -95,18 +89,16 @@ namespace HandBrake.ApplicationServices.Interop
         /// </returns>\r
         internal static HBAudioEncoder NativeToAudioEncoder(hb_encoder_s encoder)\r
         {\r
-            var result = new HBAudioEncoder\r
-                             {\r
-                                 Id = encoder.codec, \r
-                                 ShortName = encoder.short_name, \r
-                                 DisplayName = encoder.name, \r
-                                 CompatibleContainers = encoder.muxers,\r
-                                 QualityLimits = HandBrakeEncoderHelpers.GetAudioQualityLimits(encoder.codec), \r
-                                 DefaultQuality = HBFunctions.hb_audio_quality_get_default((uint)encoder.codec), \r
-                                 CompressionLimits = HandBrakeEncoderHelpers.GetAudioCompressionLimits(encoder.codec), \r
-                                 DefaultCompression =\r
-                                 HBFunctions.hb_audio_compression_get_default((uint)encoder.codec)\r
-                             };\r
+            var result = new HBAudioEncoder(\r
+                encoder.muxers,\r
+                HandBrakeEncoderHelpers.GetAudioCompressionLimits(encoder.codec),\r
+                HBFunctions.hb_audio_compression_get_default((uint)encoder.codec),\r
+                HBFunctions.hb_audio_quality_get_default((uint)encoder.codec),\r
+                encoder.name,\r
+                encoder.codec,\r
+                HandBrakeEncoderHelpers.GetAudioQualityLimits(encoder.codec),\r
+                encoder.short_name\r
+                );\r
 \r
             return result;\r
         }\r
@@ -122,11 +114,7 @@ namespace HandBrake.ApplicationServices.Interop
         /// </returns>\r
         internal static HBRate NativeToRate(hb_rate_s rate)\r
         {\r
-            return new HBRate\r
-                {\r
-                    Name = rate.name, \r
-                    Rate = rate.rate\r
-                };\r
+            return new HBRate(rate.name, rate.rate);\r
         }\r
 \r
         /// <summary>\r
@@ -140,12 +128,7 @@ namespace HandBrake.ApplicationServices.Interop
         /// </returns>\r
         internal static HBMixdown NativeToMixdown(hb_mixdown_s mixdown)\r
         {\r
-            return new HBMixdown\r
-                {\r
-                    Id = mixdown.amixdown, \r
-                    ShortName = mixdown.short_name, \r
-                    DisplayName = mixdown.name\r
-                };\r
+            return new HBMixdown(mixdown.name, mixdown.amixdown, mixdown.short_name);\r
         }\r
 \r
         /// <summary>\r
@@ -159,13 +142,7 @@ namespace HandBrake.ApplicationServices.Interop
         /// </returns>\r
         internal static HBContainer NativeToContainer(hb_container_s container)\r
         {\r
-            return new HBContainer\r
-                {\r
-                    DisplayName = container.name, \r
-                    ShortName = container.short_name, \r
-                    DefaultExtension = container.default_extension, \r
-                    Id = container.format\r
-                };\r
+            return new HBContainer(container.default_extension, container.name, container.format, container.short_name);\r
         }\r
 \r
         /// <summary>\r
@@ -181,12 +158,7 @@ namespace HandBrake.ApplicationServices.Interop
         {\r
             string englishName = InteropUtilities.ToStringFromUtf8Ptr(language.eng_name);\r
             string nativeName = InteropUtilities.ToStringFromUtf8Ptr(language.native_name);\r
-            return new Language\r
-                {\r
-                    Code = language.iso639_2, \r
-                    EnglishName = englishName, \r
-                    NativeName = nativeName\r
-                };\r
+            return new Language(englishName, nativeName, language.iso639_2);\r
         }\r
 \r
         /// <summary>\r
index 62ff642004adcac8614944b14d6202cab1dfeea2..533c73a5bf79189692604dbecaead4e618771aea 100644 (file)
@@ -15,13 +15,28 @@ namespace HandBrake.ApplicationServices.Interop.Model
     public class BitrateLimits\r
     {\r
         /// <summary>\r
-        /// Gets or sets the inclusive lower limit for the bitrate.\r
+        /// Initializes a new instance of the <see cref="BitrateLimits"/> class.\r
         /// </summary>\r
-        public int Low { get; set; }\r
+        /// <param name="low">\r
+        /// The low.\r
+        /// </param>\r
+        /// <param name="high">\r
+        /// The high.\r
+        /// </param>\r
+        public BitrateLimits(int low, int high)\r
+        {\r
+            this.Low = low;\r
+            this.High = high;\r
+        }\r
 \r
         /// <summary>\r
-        /// Gets or sets the inclusive upper limit for the bitrate.\r
+        /// Gets the inclusive lower limit for the bitrate.\r
         /// </summary>\r
-        public int High { get; set; }\r
+        public int Low { get; private set; }\r
+\r
+        /// <summary>\r
+        /// Gets the inclusive upper limit for the bitrate.\r
+        /// </summary>\r
+        public int High { get; private set; }\r
     }\r
 }\r
index 5bef508f8e73f35441f7606c5ca1a43836d4092d..2d2e5b26d2e49f8290124fb82afb305718a2b0ce 100644 (file)
@@ -17,34 +17,73 @@ namespace HandBrake.ApplicationServices.Interop.Model.Encoding
     public class HBAudioEncoder\r
     {\r
         /// <summary>\r
-        /// Gets or sets the compatible containers.\r
+        /// Initializes a new instance of the <see cref="HBAudioEncoder"/> class.\r
         /// </summary>\r
-        public int CompatibleContainers { get; set; }\r
+        /// <param name="compatibleContainers">\r
+        /// The compatible containers.\r
+        /// </param>\r
+        /// <param name="compressionLimits">\r
+        /// The compression limits.\r
+        /// </param>\r
+        /// <param name="defaultCompression">\r
+        /// The default compression.\r
+        /// </param>\r
+        /// <param name="defaultQuality">\r
+        /// The default quality.\r
+        /// </param>\r
+        /// <param name="displayName">\r
+        /// The display name.\r
+        /// </param>\r
+        /// <param name="id">\r
+        /// The id.\r
+        /// </param>\r
+        /// <param name="qualityLimits">\r
+        /// The quality limits.\r
+        /// </param>\r
+        /// <param name="shortName">\r
+        /// The short name.\r
+        /// </param>\r
+        public HBAudioEncoder(int compatibleContainers, RangeLimits compressionLimits, float defaultCompression, float defaultQuality, string displayName, int id, RangeLimits qualityLimits, string shortName)\r
+        {\r
+            this.CompatibleContainers = compatibleContainers;\r
+            this.CompressionLimits = compressionLimits;\r
+            this.DefaultCompression = defaultCompression;\r
+            this.DefaultQuality = defaultQuality;\r
+            this.DisplayName = displayName;\r
+            this.Id = id;\r
+            this.QualityLimits = qualityLimits;\r
+            this.ShortName = shortName;\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets the compatible containers.\r
+        /// </summary>\r
+        public int CompatibleContainers { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the compression limits.\r
+        /// Gets the compression limits.\r
         /// </summary>\r
-        public RangeLimits CompressionLimits { get; set; }\r
+        public RangeLimits CompressionLimits { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the default compression.\r
+        /// Gets the default compression.\r
         /// </summary>\r
-        public float DefaultCompression { get; set; }\r
+        public float DefaultCompression { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the default quality.\r
+        /// Gets the default quality.\r
         /// </summary>\r
-        public float DefaultQuality { get; set; }\r
+        public float DefaultQuality { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the display name.\r
+        /// Gets the display name.\r
         /// </summary>\r
-        public string DisplayName { get; set; }\r
+        public string DisplayName { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the id.\r
+        /// Gets the id.\r
         /// </summary>\r
-        public int Id { get; set; }\r
+        public int Id { get; private set; }\r
 \r
         /// <summary>\r
         /// Gets a value indicating whether the encoder is passthrough.\r
index 2a91c4e70c96711d2dfa68d248d19674f637f936..832d3513d85c5cd897206076458a022fd1cac10d 100644 (file)
@@ -15,23 +15,46 @@ namespace HandBrake.ApplicationServices.Interop.Model.Encoding
     public class HBContainer\r
     {\r
         /// <summary>\r
-        /// Gets or sets the default extension.\r
+        /// Initializes a new instance of the <see cref="HBContainer"/> class.\r
         /// </summary>\r
-        public string DefaultExtension { get; set; }\r
+        /// <param name="defaultExtension">\r
+        /// The default extension.\r
+        /// </param>\r
+        /// <param name="displayName">\r
+        /// The display name.\r
+        /// </param>\r
+        /// <param name="id">\r
+        /// The id.\r
+        /// </param>\r
+        /// <param name="shortName">\r
+        /// The short name.\r
+        /// </param>\r
+        public HBContainer(string defaultExtension, string displayName, int id, string shortName)\r
+        {\r
+            this.DefaultExtension = defaultExtension;\r
+            this.DisplayName = displayName;\r
+            this.Id = id;\r
+            this.ShortName = shortName;\r
+        }\r
 \r
         /// <summary>\r
-        /// Gets or sets the display name.\r
+        /// Gets the default extension.\r
         /// </summary>\r
-        public string DisplayName { get; set; }\r
+        public string DefaultExtension { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the id.\r
+        /// Gets the display name.\r
         /// </summary>\r
-        public int Id { get; set; }\r
+        public string DisplayName { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the short name.\r
+        /// Gets the id.\r
         /// </summary>\r
-        public string ShortName { get; set; }\r
+        public int Id { get; private set; }\r
+\r
+        /// <summary>\r
+        /// Gets the short name.\r
+        /// </summary>\r
+        public string ShortName { get; private set; }\r
     }\r
 }
\ No newline at end of file
index 18e7288e7f6e47b8ca520e8f881b6ff1aab59ab8..04927b9dd44145452af934f8c7ad05b165ca2614 100644 (file)
@@ -14,23 +14,38 @@ namespace HandBrake.ApplicationServices.Interop.Model.Encoding
     /// </summary>\r
     public class HBMixdown\r
     {\r
-        #region Public Properties\r
-\r
         /// <summary>\r
-        /// Gets or sets the display name.\r
+        /// Initializes a new instance of the <see cref="HBMixdown"/> class.\r
         /// </summary>\r
-        public string DisplayName { get; set; }\r
+        /// <param name="displayName">\r
+        /// The display name.\r
+        /// </param>\r
+        /// <param name="id">\r
+        /// The id.\r
+        /// </param>\r
+        /// <param name="shortName">\r
+        /// The short name.\r
+        /// </param>\r
+        public HBMixdown(string displayName, int id, string shortName)\r
+        {\r
+            this.DisplayName = displayName;\r
+            this.Id = id;\r
+            this.ShortName = shortName;\r
+        }\r
 \r
         /// <summary>\r
-        /// Gets or sets the id.\r
+        /// Gets the display name.\r
         /// </summary>\r
-        public int Id { get; set; }\r
+        public string DisplayName { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the short name.\r
+        /// Gets the id.\r
         /// </summary>\r
-        public string ShortName { get; set; }\r
+        public int Id { get; private set; }\r
 \r
-        #endregion\r
+        /// <summary>\r
+        /// Gets the short name.\r
+        /// </summary>\r
+        public string ShortName { get; private set; }\r
     }\r
 }
\ No newline at end of file
index e3315878dbb0e02203d3201f786513fc15eaab8c..d3287cddbbbb90bd8fed8e2c3335b6dd983f1954 100644 (file)
@@ -15,13 +15,28 @@ namespace HandBrake.ApplicationServices.Interop.Model.Encoding
     public class HBRate\r
     {\r
         /// <summary>\r
-        /// Gets or sets the name to use for this rate.\r
+        /// Initializes a new instance of the <see cref="HBRate"/> class.\r
         /// </summary>\r
-        public string Name { get; set; }\r
+        /// <param name="name">\r
+        /// The name.\r
+        /// </param>\r
+        /// <param name="rate">\r
+        /// The rate.\r
+        /// </param>\r
+        public HBRate(string name, int rate)\r
+        {\r
+            this.Name = name;\r
+            this.Rate = rate;\r
+        }\r
 \r
         /// <summary>\r
-        /// Gets or sets the raw rate.\r
+        /// Gets the name to use for this rate.\r
         /// </summary>\r
-        public int Rate { get; set; }\r
+        public string Name { get; private set; }\r
+\r
+        /// <summary>\r
+        /// Gets the raw rate.\r
+        /// </summary>\r
+        public int Rate { get; private set; }\r
     }\r
 }\r
index a764f76b36aed51bd5ec4586092a4953cf448e69..a1e60b2dec9527b5b10ea4fd9a6df57b0a1fb237 100644 (file)
@@ -20,24 +20,47 @@ namespace HandBrake.ApplicationServices.Interop.Model.Encoding
     public class HBVideoEncoder\r
     {\r
         /// <summary>\r
-        /// Gets or sets the compatible containers.\r
+        /// Initializes a new instance of the <see cref="HBVideoEncoder"/> class.\r
         /// </summary>\r
-        public int CompatibleContainers { get; set; }\r
+        /// <param name="compatibleContainers">\r
+        /// The compatible containers.\r
+        /// </param>\r
+        /// <param name="displayName">\r
+        /// The display name.\r
+        /// </param>\r
+        /// <param name="id">\r
+        /// The id.\r
+        /// </param>\r
+        /// <param name="shortName">\r
+        /// The short name.\r
+        /// </param>\r
+        public HBVideoEncoder(int compatibleContainers, string displayName, int id, string shortName)\r
+        {\r
+            this.CompatibleContainers = compatibleContainers;\r
+            this.DisplayName = displayName;\r
+            this.Id = id;\r
+            this.ShortName = shortName;\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets the compatible containers.\r
+        /// </summary>\r
+        public int CompatibleContainers { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the display name.\r
+        /// Gets the display name.\r
         /// </summary>\r
-        public string DisplayName { get; set; }\r
+        public string DisplayName { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the id.\r
+        /// Gets the id.\r
         /// </summary>\r
-        public int Id { get; set; }\r
+        public int Id { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the short name.\r
+        /// Gets the short name.\r
         /// </summary>\r
-        public string ShortName { get; set; }\r
+        public string ShortName { get; private set; }\r
 \r
         /// <summary>\r
         /// Gets the list of presets this encoder supports. (null if the encoder doesn't support presets)\r
index 89e997ef83232fe732bcb5c1e13b1cd089b2ddd3..a110f2590c160c9a99eb5c47f13396aca28337dc 100644 (file)
@@ -15,19 +15,38 @@ namespace HandBrake.ApplicationServices.Interop.Model
     public class Language\r
     {\r
         /// <summary>\r
-        /// Gets or sets the english name of the language.\r
+        /// Initializes a new instance of the <see cref="Language"/> class.\r
         /// </summary>\r
-        public string EnglishName { get; set; }\r
+        /// <param name="englishName">\r
+        /// The english name.\r
+        /// </param>\r
+        /// <param name="nativeName">\r
+        /// The native name.\r
+        /// </param>\r
+        /// <param name="code">\r
+        /// The code.\r
+        /// </param>\r
+        public Language(string englishName, string nativeName, string code)\r
+        {\r
+            this.EnglishName = englishName;\r
+            this.NativeName = nativeName;\r
+            this.Code = code;\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets the english name of the language.\r
+        /// </summary>\r
+        public string EnglishName { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the native name of the language.\r
+        /// Gets the native name of the language.\r
         /// </summary>\r
-        public string NativeName { get; set; }\r
+        public string NativeName { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the language code.\r
+        /// Gets the language code.\r
         /// </summary>\r
-        public string Code { get; set; }\r
+        public string Code { get; private set; }\r
 \r
         /// <summary>\r
         /// Gets the display string for the language.\r
index e10e16a71fc94c7bd3f59792f9f2cbc2e621ede2..b25c610dd84d55066ed284128daa8328b69e3c30 100644 (file)
@@ -15,23 +15,46 @@ namespace HandBrake.ApplicationServices.Interop.Model
     public class RangeLimits\r
     {\r
         /// <summary>\r
-        /// Gets or sets a value indicating whether ascending.\r
+        /// Initializes a new instance of the <see cref="RangeLimits"/> class.\r
         /// </summary>\r
-        public bool Ascending { get; set; }\r
+        /// <param name="ascending">\r
+        /// The ascending.\r
+        /// </param>\r
+        /// <param name="granularity">\r
+        /// The granularity.\r
+        /// </param>\r
+        /// <param name="high">\r
+        /// The high.\r
+        /// </param>\r
+        /// <param name="low">\r
+        /// The low.\r
+        /// </param>\r
+        public RangeLimits(bool @ascending, float granularity, float high, float low)\r
+        {\r
+            this.Ascending = @ascending;\r
+            this.Granularity = granularity;\r
+            this.High = high;\r
+            this.Low = low;\r
+        }\r
 \r
         /// <summary>\r
-        /// Gets or sets the granularity.\r
+        /// Gets a value indicating whether ascending.\r
         /// </summary>\r
-        public float Granularity { get; set; }\r
+        public bool Ascending { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the high.\r
+        /// Gets the granularity.\r
         /// </summary>\r
-        public float High { get; set; }\r
+        public float Granularity { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the low.\r
+        /// Gets the high.\r
         /// </summary>\r
-        public float Low { get; set; }\r
+        public float High { get; private set; }\r
+\r
+        /// <summary>\r
+        /// Gets the low.\r
+        /// </summary>\r
+        public float Low { get; private set; }\r
     }\r
 }
\ No newline at end of file
index e6752042ccdbfb284ac95a95cd3d915be8c4680c..4a4e09d34348479444fb39bb544682b2d056add4 100644 (file)
@@ -30,14 +30,14 @@ namespace HandBrake.ApplicationServices.Interop.Model
         }\r
 \r
         /// <summary>\r
-        /// Gets or sets the height.\r
+        /// Gets the height.\r
         /// </summary>\r
-        public int Height { get; set; }\r
+        public int Height { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the width.\r
+        /// Gets the width.\r
         /// </summary>\r
-        public int Width { get; set; }\r
+        public int Width { get; private set; }\r
 \r
         /// <summary>\r
         /// Gets a value indicating whether is empty.\r
index 31b94ae106422b9c10097e9ad08287e61d06f3a0..4a0ffd2ec0e73a0088515cce47d6491f2afbba13 100644 (file)
@@ -30,13 +30,13 @@ namespace HandBrake.ApplicationServices.Interop.Model
         }\r
 \r
         /// <summary>\r
-        /// Gets or sets the resolution (width/height) of this Title\r
+        /// Gets the resolution (width/height) of this Title\r
         /// </summary>\r
-        public Size Resolution { get; set; }\r
+        public Size Resolution { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the pixel aspect ratio.\r
+        /// Gets the pixel aspect ratio.\r
         /// </summary>\r
-        public Size ParVal { get; set; }\r
+        public Size ParVal { get; private set; }\r
     }\r
 }\r
index bd9c1f5d478c2102011a3bf1671666d33bab9cf1..19a0755af2f9290a176b1d4db4f00cf518bef581 100644 (file)
@@ -15,23 +15,46 @@ namespace HandBrake.ApplicationServices.Interop.Model
     public class VideoQualityLimits\r
     {\r
         /// <summary>\r
-        /// Gets or sets the inclusive lower limit for the quality.\r
+        /// Initializes a new instance of the <see cref="VideoQualityLimits"/> class.\r
         /// </summary>\r
-        public float Low { get; set; }\r
+        /// <param name="low">\r
+        /// The low.\r
+        /// </param>\r
+        /// <param name="high">\r
+        /// The high.\r
+        /// </param>\r
+        /// <param name="granularity">\r
+        /// The granularity.\r
+        /// </param>\r
+        /// <param name="ascending">\r
+        /// The ascending.\r
+        /// </param>\r
+        public VideoQualityLimits(float low, float high, float granularity, bool @ascending)\r
+        {\r
+            this.Low = low;\r
+            this.High = high;\r
+            this.Granularity = granularity;\r
+            this.Ascending = @ascending;\r
+        }\r
 \r
         /// <summary>\r
-        /// Gets or sets the inclusive upper limit for the quality.\r
+        /// Gets the inclusive lower limit for the quality.\r
         /// </summary>\r
-        public float High { get; set; }\r
+        public float Low { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets the granularity for the quality.\r
+        /// Gets the inclusive upper limit for the quality.\r
         /// </summary>\r
-        public float Granularity { get; set; }\r
+        public float High { get; private set; }\r
 \r
         /// <summary>\r
-        /// Gets or sets a value indicating whether the quality increases as the number increases.\r
+        /// Gets the granularity for the quality.\r
         /// </summary>\r
-        public bool Ascending { get; set; }\r
+        public float Granularity { get; private set; }\r
+\r
+        /// <summary>\r
+        /// Gets a value indicating whether the quality increases as the number increases.\r
+        /// </summary>\r
+        public bool Ascending { get; private set; }\r
     }\r
 }\r