Move WixFileNotFoundException from Core back to Data
Rob Mensching committed
Jan 2, 2018 at 14:18 UTC
aa12ce344a305618c3b6a0723519c496c2c9f43c
1 file changed
+43
src/WixToolset.Data/WixFileNotFoundException.cs
new
+43
@@ -0,0 +1,43 @@
1
+// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
+
3
+namespace WixToolset.Data
4
+{
5
+ using System;
6
+
7
+ /// <summary>
8
+ /// WixException thrown when a file cannot be found.
9
+ /// </summary>
10
+ [Serializable]
11
+ public sealed class WixFileNotFoundException : WixException
12
+ {
13
+ /// <summary>
14
+ /// Instantiate a new WixFileNotFoundException.
15
+ /// </summary>
16
+ /// <param name="sourceLineNumbers">Source line information pertaining to the file that cannot be found.</param>
17
+ /// <param name="file">The file that could not be found.</param>
18
+ public WixFileNotFoundException(SourceLineNumber sourceLineNumbers, string file) :
19
+ base(ErrorMessages.FileNotFound(sourceLineNumbers, file))
20
+ {
21
+ }
22
+
23
+ /// <summary>
24
+ /// Instantiate a new WixFileNotFoundException.
25
+ /// </summary>
26
+ /// <param name="file">The file that could not be found.</param>
27
+ /// <param name="fileType">The type of file that cannot be found.</param>
28
+ public WixFileNotFoundException(string file, string fileType) : this(null, file, fileType)
29
+ {
30
+ }
31
+
32
+ /// <summary>
33
+ /// Instantiate a new WixFileNotFoundException.
34
+ /// </summary>
35
+ /// <param name="sourceLineNumbers">Source line information pertaining to the file that cannot be found.</param>
36
+ /// <param name="file">The file that could not be found.</param>
37
+ /// <param name="fileType">The type of file that cannot be found.</param>
38
+ public WixFileNotFoundException(SourceLineNumber sourceLineNumbers, string file, string fileType) :
39
+ base(ErrorMessages.FileNotFound(sourceLineNumbers, file, fileType))
40
+ {
41
+ }
42
+ }
43
+}