aboutsummaryrefslogtreecommitdiff
path: root/src/wixext/DependencyErrors.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/wixext/DependencyErrors.cs37
1 files changed, 37 insertions, 0 deletions
diff --git a/src/wixext/DependencyErrors.cs b/src/wixext/DependencyErrors.cs
new file mode 100644
index 00000000..83c0986a
--- /dev/null
+++ b/src/wixext/DependencyErrors.cs
@@ -0,0 +1,37 @@
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
3namespace WixToolset.Dependency
4{
5 using System;
6 using System.Resources;
7 using WixToolset.Data;
8
9 public static class DependencyErrors
10 {
11 public static Message IllegalCharactersInProvider(SourceLineNumber sourceLineNumbers, string attributeName, Char illegalChar, string illegalChars)
12 {
13 return Message(sourceLineNumbers, Ids.IllegalCharactersInProvider, "The provider key authored into the {0} attribute contains an illegal character, '{1}'. Please author the provider key without any of the following characters: {2}", attributeName, illegalChar, illegalChars);
14 }
15
16 public static Message ReservedValue(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string attributeValue)
17 {
18 return Message(sourceLineNumbers, Ids.ReservedValue, "The {0}/@{1} attribute value '{2}' is reserved and cannot be used here. Please choose a different value.", elementName, attributeName, attributeValue);
19 }
20
21 private static Message Message(SourceLineNumber sourceLineNumber, Ids id, string format, params object[] args)
22 {
23 return new Message(sourceLineNumber, MessageLevel.Error, (int)id, format, args);
24 }
25
26 private static Message Message(SourceLineNumber sourceLineNumber, Ids id, ResourceManager resourceManager, string resourceName, params object[] args)
27 {
28 return new Message(sourceLineNumber, MessageLevel.Error, (int)id, resourceManager, resourceName, args);
29 }
30
31 public enum Ids
32 {
33 IllegalCharactersInProvider = 5400,
34 ReservedValue = 5401,
35 }
36 }
37}