-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Expand file tree
/
Copy pathError.cs
More file actions
27 lines (24 loc) · 903 Bytes
/
Error.cs
File metadata and controls
27 lines (24 loc) · 903 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
using System;
using System.Globalization;
namespace ServiceStack.Html
{
internal static class Error
{
public static InvalidOperationException ViewDataDictionary_WrongTModelType(Type valueType, Type modelType)
{
string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ViewDataDictionary_WrongTModelType,
valueType, modelType);
return new InvalidOperationException(message);
}
public static InvalidOperationException ViewDataDictionary_ModelCannotBeNull(Type modelType)
{
string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ViewDataDictionary_ModelCannotBeNull,
modelType);
return new InvalidOperationException(message);
}
public static ArgumentException ParameterCannotBeNullOrEmpty(string parameterName)
{
return new ArgumentException(MvcResources.Common_NullOrEmpty, parameterName);
}
}
}