diff options
author | Scott <[email protected]> | 2015-09-26 21:29:34 +0100 |
---|---|---|
committer | Scott <[email protected]> | 2015-09-26 21:30:33 +0100 |
commit | c19ea798a23bfea7aba509309bef9168ece09836 (patch) | |
tree | 72c318fc971208bfcb0149bd98efef6a63f85926 /win/CS/HandBrakeWPF/Helpers/Validate.cs | |
parent | a6cf5c5fd4b4c23ad3998ff270162768ce9ae6e7 (diff) |
App Services Modelling Tidy Up
Making event objects immutable. Making Libhb constructs internal to the
library. We should expose this with a managed api if we need it outside
the library. (Part 1)
Diffstat (limited to 'win/CS/HandBrakeWPF/Helpers/Validate.cs')
-rw-r--r-- | win/CS/HandBrakeWPF/Helpers/Validate.cs | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/win/CS/HandBrakeWPF/Helpers/Validate.cs b/win/CS/HandBrakeWPF/Helpers/Validate.cs new file mode 100644 index 000000000..7d307dfbc --- /dev/null +++ b/win/CS/HandBrakeWPF/Helpers/Validate.cs @@ -0,0 +1,39 @@ +// -------------------------------------------------------------------------------------------------------------------- +// <copyright file="Validate.cs" company="HandBrake Project (http://handbrake.fr)"> +// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License. +// </copyright> +// <summary> +// The validate. +// </summary> +// -------------------------------------------------------------------------------------------------------------------- + +namespace HandBrakeWPF.Helpers +{ + using System; + + /// <summary> + /// The validate. + /// </summary> + public class Validate + { + /// <summary> + /// The not null. + /// </summary> + /// <param name="item"> + /// The item. + /// </param> + /// <param name="message"> + /// The message. + /// </param> + /// <exception cref="ArgumentException"> + /// Thrown when the input object is null + /// </exception> + public static void NotNull(object item, string message) + { + if (item == null) + { + throw new ArgumentException(message); + } + } + } +} |