Updating resx designer file to use updated format

This commit is contained in:
Pranav K 2014-03-02 19:05:38 -08:00
parent 2688029682
commit 48738b91f4
11 changed files with 361 additions and 315 deletions

View File

@ -7,40 +7,18 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Internal
{
internal static ArgumentException ArgumentNull(string paramName)
{
throw new ArgumentNullException(paramName);
}
internal static Exception InvalidOperation(string message, params object[] args)
{
throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture, message, args));
}
internal static Exception InvalidOperation(Exception ex, string message, params object[] args)
{
throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture, message, args), ex);
}
/// <summary>
/// Creates an <see cref="ArgumentException"/> with the provided properties.
/// </summary>
/// <param name="messageFormat">A composite format string explaining the reason for the exception.</param>
/// <param name="messageArgs">An object array that contains zero or more objects to format.</param>
/// <returns>The logged <see cref="Exception"/>.</returns>
internal static ArgumentException Argument(string messageFormat, params object[] messageArgs)
{
return new ArgumentException(String.Format(CultureInfo.CurrentCulture, messageFormat, messageArgs));
return new ArgumentNullException(paramName);
}
/// <summary>
/// Creates an <see cref="ArgumentException"/> with the provided properties.
/// </summary>
/// <param name="parameterName">The name of the parameter that caused the current exception.</param>
/// <param name="messageFormat">A composite format string explaining the reason for the exception.</param>
/// <param name="messageArgs">An object array that contains zero or more objects to format.</param>
/// <param name="message">A composite message explaining the reason for the exception.</param>
/// <returns>The logged <see cref="Exception"/>.</returns>
internal static ArgumentException Argument(string parameterName, string messageFormat, params object[] messageArgs)
internal static ArgumentException Argument(string parameterName, string message)
{
return new ArgumentException(String.Format(CultureInfo.CurrentCulture, messageFormat, messageArgs), parameterName);
return new ArgumentException(message, parameterName);
}
/// <summary>
@ -50,7 +28,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Internal
/// <returns>The logged <see cref="Exception"/>.</returns>
internal static ArgumentException ArgumentNullOrEmpty(string parameterName)
{
return Error.Argument(parameterName, Resources.ArgumentNullOrEmpty, parameterName);
return Error.Argument(parameterName, Resources.FormatArgumentNullOrEmpty(parameterName));
}
}
}

View File

@ -72,17 +72,22 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Internal
if (bindingContext.ModelType != requiredType)
{
throw Error.Argument("bindingContext", Resources.ModelBinderUtil_ModelTypeIsWrong, bindingContext.ModelType, requiredType);
var message = Resources.FormatModelBinderUtil_ModelTypeIsWrong(bindingContext.ModelType, requiredType);
throw Error.Argument("bindingContext", message);
}
if (!allowNullModel && bindingContext.Model == null)
{
throw Error.Argument("bindingContext", Resources.ModelBinderUtil_ModelCannotBeNull, requiredType);
var message = Resources.FormatModelBinderUtil_ModelCannotBeNull(requiredType);
throw Error.Argument("bindingContext", message);
}
if (bindingContext.Model != null && !bindingContext.ModelType.GetTypeInfo().IsAssignableFrom(requiredType.GetTypeInfo()))
{
throw Error.Argument("bindingContext", Resources.ModelBinderUtil_ModelInstanceIsWrong, bindingContext.Model.GetType(), requiredType);
var message = Resources.FormatModelBinderUtil_ModelInstanceIsWrong(
bindingContext.Model.GetType(),
requiredType);
throw Error.Argument("bindingContext", message);
}
}
}

View File

@ -39,7 +39,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
PropertyInformation propertyInfo;
if (!typeInfo.Properties.TryGetValue(propertyName, out propertyInfo))
{
throw Error.Argument("propertyName", Resources.Common_PropertyNotFound, containerType, propertyName);
throw Error.Argument("propertyName", Resources.FormatCommon_PropertyNotFound(containerType, propertyName));
}
return CreateMetadataFromPrototype(propertyInfo.Prototype, modelAccessor);

View File

@ -106,7 +106,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
{
if (ModelMetadata == null)
{
throw Error.InvalidOperation(Resources.ModelBindingContext_ModelMetadataMustBeSet);
throw new InvalidOperationException(Resources.ModelBindingContext_ModelMetadataMustBeSet);
}
}
}

View File

@ -0,0 +1,254 @@
// <auto-generated />
namespace Microsoft.AspNet.Mvc.ModelBinding
{
using System.Globalization;
using System.Reflection;
using System.Resources;
internal static class Resources
{
private static readonly ResourceManager _resourceManager
= new ResourceManager("Microsoft.AspNet.Mvc.ModelBinding.Resources", typeof(Resources).GetTypeInfo().Assembly);
/// <summary>
/// The argument '{0}' is null or empty.
/// </summary>
internal static string ArgumentNullOrEmpty
{
get { return GetString("ArgumentNullOrEmpty"); }
}
/// <summary>
/// The argument '{0}' is null or empty.
/// </summary>
internal static string FormatArgumentNullOrEmpty(object p0)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ArgumentNullOrEmpty"), p0);
}
/// <summary>
/// The property {0}.{1} could not be found.
/// </summary>
internal static string Common_PropertyNotFound
{
get { return GetString("Common_PropertyNotFound"); }
}
/// <summary>
/// The property {0}.{1} could not be found.
/// </summary>
internal static string FormatCommon_PropertyNotFound(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("Common_PropertyNotFound"), p0, p1);
}
/// <summary>
/// The key is invalid JQuery syntax because it is missing a closing bracket.
/// </summary>
internal static string JQuerySyntaxMissingClosingBracket
{
get { return GetString("JQuerySyntaxMissingClosingBracket"); }
}
/// <summary>
/// The key is invalid JQuery syntax because it is missing a closing bracket.
/// </summary>
internal static string FormatJQuerySyntaxMissingClosingBracket()
{
return GetString("JQuerySyntaxMissingClosingBracket");
}
/// <summary>
/// The value '{0}' is not valid for {1}.
/// </summary>
internal static string ModelBinderConfig_ValueInvalid
{
get { return GetString("ModelBinderConfig_ValueInvalid"); }
}
/// <summary>
/// The value '{0}' is not valid for {1}.
/// </summary>
internal static string FormatModelBinderConfig_ValueInvalid(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ModelBinderConfig_ValueInvalid"), p0, p1);
}
/// <summary>
/// A value is required.
/// </summary>
internal static string ModelBinderConfig_ValueRequired
{
get { return GetString("ModelBinderConfig_ValueRequired"); }
}
/// <summary>
/// A value is required.
/// </summary>
internal static string FormatModelBinderConfig_ValueRequired()
{
return GetString("ModelBinderConfig_ValueRequired");
}
/// <summary>
/// The binding context has a null Model, but this binder requires a non-null model of type '{0}'.
/// </summary>
internal static string ModelBinderUtil_ModelCannotBeNull
{
get { return GetString("ModelBinderUtil_ModelCannotBeNull"); }
}
/// <summary>
/// The binding context has a null Model, but this binder requires a non-null model of type '{0}'.
/// </summary>
internal static string FormatModelBinderUtil_ModelCannotBeNull(object p0)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ModelBinderUtil_ModelCannotBeNull"), p0);
}
/// <summary>
/// The binding context has a Model of type '{0}', but this binder can only operate on models of type '{1}'.
/// </summary>
internal static string ModelBinderUtil_ModelInstanceIsWrong
{
get { return GetString("ModelBinderUtil_ModelInstanceIsWrong"); }
}
/// <summary>
/// The binding context has a Model of type '{0}', but this binder can only operate on models of type '{1}'.
/// </summary>
internal static string FormatModelBinderUtil_ModelInstanceIsWrong(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ModelBinderUtil_ModelInstanceIsWrong"), p0, p1);
}
/// <summary>
/// The binding context cannot have a null ModelMetadata.
/// </summary>
internal static string ModelBinderUtil_ModelMetadataCannotBeNull
{
get { return GetString("ModelBinderUtil_ModelMetadataCannotBeNull"); }
}
/// <summary>
/// The binding context cannot have a null ModelMetadata.
/// </summary>
internal static string FormatModelBinderUtil_ModelMetadataCannotBeNull()
{
return GetString("ModelBinderUtil_ModelMetadataCannotBeNull");
}
/// <summary>
/// The binding context has a ModelType of '{0}', but this binder can only operate on models of type '{1}'.
/// </summary>
internal static string ModelBinderUtil_ModelTypeIsWrong
{
get { return GetString("ModelBinderUtil_ModelTypeIsWrong"); }
}
/// <summary>
/// The binding context has a ModelType of '{0}', but this binder can only operate on models of type '{1}'.
/// </summary>
internal static string FormatModelBinderUtil_ModelTypeIsWrong(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ModelBinderUtil_ModelTypeIsWrong"), p0, p1);
}
/// <summary>
/// The ModelMetadata property must be set before accessing this property.
/// </summary>
internal static string ModelBindingContext_ModelMetadataMustBeSet
{
get { return GetString("ModelBindingContext_ModelMetadataMustBeSet"); }
}
/// <summary>
/// The ModelMetadata property must be set before accessing this property.
/// </summary>
internal static string FormatModelBindingContext_ModelMetadataMustBeSet()
{
return GetString("ModelBindingContext_ModelMetadataMustBeSet");
}
/// <summary>
/// The parameter conversion from type '{0}' to type '{1}' failed. See the inner exception for more information.
/// </summary>
internal static string ValueProviderResult_ConversionThrew
{
get { return GetString("ValueProviderResult_ConversionThrew"); }
}
/// <summary>
/// The parameter conversion from type '{0}' to type '{1}' failed. See the inner exception for more information.
/// </summary>
internal static string FormatValueProviderResult_ConversionThrew(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ValueProviderResult_ConversionThrew"), p0, p1);
}
/// <summary>
/// The parameter conversion from type '{0}' to type '{1}' failed because no type converter can convert between these types.
/// </summary>
internal static string ValueProviderResult_NoConverterExists
{
get { return GetString("ValueProviderResult_NoConverterExists"); }
}
/// <summary>
/// The parameter conversion from type '{0}' to type '{1}' failed because no type converter can convert between these types.
/// </summary>
internal static string FormatValueProviderResult_NoConverterExists(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ValueProviderResult_NoConverterExists"), p0, p1);
}
/// <summary>
/// The model item passed is null, but this ViewData instance requires a non-null model item of type '{0}'.
/// </summary>
internal static string ViewDataDictionary_ModelCannotBeNull
{
get { return GetString("ViewDataDictionary_ModelCannotBeNull"); }
}
/// <summary>
/// The model item passed is null, but this ViewData instance requires a non-null model item of type '{0}'.
/// </summary>
internal static string FormatViewDataDictionary_ModelCannotBeNull(object p0)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ViewDataDictionary_ModelCannotBeNull"), p0);
}
/// <summary>
/// The model item passed into the ViewData is of type '{0}', but this ViewData instance requires a model item of type '{1}'.
/// </summary>
internal static string ViewData_WrongTModelType
{
get { return GetString("ViewData_WrongTModelType"); }
}
/// <summary>
/// The model item passed into the ViewData is of type '{0}', but this ViewData instance requires a model item of type '{1}'.
/// </summary>
internal static string FormatViewData_WrongTModelType(object p0, object p1)
{
return string.Format(CultureInfo.CurrentCulture, GetString("ViewData_WrongTModelType"), p0, p1);
}
private static string GetString(string name, params string[] formatterNames)
{
var value = _resourceManager.GetString(name);
System.Diagnostics.Debug.Assert(value != null);
if (formatterNames != null)
{
for (var i = 0; i < formatterNames.Length; i++)
{
value = value.Replace("{" + formatterNames[i] + "}", "{" + i + "}");
}
}
return value;
}
}
}

View File

@ -1,189 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.34003
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Microsoft.AspNet.Mvc.ModelBinding {
using System;
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources() {
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager {
get {
if (object.ReferenceEquals(resourceMan, null)) {
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Microsoft.AspNet.Mvc.ModelBinding.Resources", System.Reflection.IntrospectionExtensions.GetTypeInfo(typeof(Resources)).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture {
get {
return resourceCulture;
}
set {
resourceCulture = value;
}
}
/// <summary>
/// Looks up a localized string similar to The argument &apos;{0}&apos; is null or empty..
/// </summary>
internal static string ArgumentNullOrEmpty {
get {
return ResourceManager.GetString("ArgumentNullOrEmpty", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The property {0}.{1} could not be found..
/// </summary>
internal static string Common_PropertyNotFound {
get {
return ResourceManager.GetString("Common_PropertyNotFound", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The key is invalid JQuery syntax because it is missing a closing bracket..
/// </summary>
internal static string JQuerySyntaxMissingClosingBracket {
get {
return ResourceManager.GetString("JQuerySyntaxMissingClosingBracket", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The value &apos;{0}&apos; is not valid for {1}..
/// </summary>
internal static string ModelBinderConfig_ValueInvalid {
get {
return ResourceManager.GetString("ModelBinderConfig_ValueInvalid", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to A value is required..
/// </summary>
internal static string ModelBinderConfig_ValueRequired {
get {
return ResourceManager.GetString("ModelBinderConfig_ValueRequired", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The binding context has a null Model, but this binder requires a non-null model of type &apos;{0}&apos;..
/// </summary>
internal static string ModelBinderUtil_ModelCannotBeNull {
get {
return ResourceManager.GetString("ModelBinderUtil_ModelCannotBeNull", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The binding context has a Model of type &apos;{0}&apos;, but this binder can only operate on models of type &apos;{1}&apos;..
/// </summary>
internal static string ModelBinderUtil_ModelInstanceIsWrong {
get {
return ResourceManager.GetString("ModelBinderUtil_ModelInstanceIsWrong", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The binding context cannot have a null ModelMetadata..
/// </summary>
internal static string ModelBinderUtil_ModelMetadataCannotBeNull {
get {
return ResourceManager.GetString("ModelBinderUtil_ModelMetadataCannotBeNull", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The binding context has a ModelType of &apos;{0}&apos;, but this binder can only operate on models of type &apos;{1}&apos;..
/// </summary>
internal static string ModelBinderUtil_ModelTypeIsWrong {
get {
return ResourceManager.GetString("ModelBinderUtil_ModelTypeIsWrong", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The ModelMetadata property must be set before accessing this property..
/// </summary>
internal static string ModelBindingContext_ModelMetadataMustBeSet {
get {
return ResourceManager.GetString("ModelBindingContext_ModelMetadataMustBeSet", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The parameter conversion from type &apos;{0}&apos; to type &apos;{1}&apos; failed. See the inner exception for more information..
/// </summary>
internal static string ValueProviderResult_ConversionThrew {
get {
return ResourceManager.GetString("ValueProviderResult_ConversionThrew", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The parameter conversion from type &apos;{0}&apos; to type &apos;{1}&apos; failed because no type converter can convert between these types..
/// </summary>
internal static string ValueProviderResult_NoConverterExists {
get {
return ResourceManager.GetString("ValueProviderResult_NoConverterExists", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The model item passed into the ViewData is of type &apos;{0}&apos;, but this ViewData instance requires a model item of type &apos;{1}&apos;..
/// </summary>
internal static string ViewData_WrongTModelType {
get {
return ResourceManager.GetString("ViewData_WrongTModelType", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The model item passed is null, but this ViewData instance requires a non-null model item of type &apos;{0}&apos;..
/// </summary>
internal static string ViewDataDictionary_ModelCannotBeNull {
get {
return ResourceManager.GetString("ViewDataDictionary_ModelCannotBeNull", resourceCulture);
}
}
}
}

View File

@ -96,7 +96,8 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
{
return Convert.ToString(value);
}
throw Error.InvalidOperation(Resources.ValueProviderResult_NoConverterExists, value.GetType(), destinationType);
string message = Resources.FormatValueProviderResult_NoConverterExists(value.GetType(), destinationType);
throw new InvalidOperationException(message);
// TODO: Revive once we get TypeConverters
//TypeConverter converter = TypeDescriptor.GetConverter(destinationType);

View File

@ -36,7 +36,8 @@ namespace Microsoft.AspNet.Mvc.Razor
{
if (_modelStatementFound && _endInheritsLocation.HasValue)
{
Context.OnError(_endInheritsLocation.Value, Resources.MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword(ModelKeyword));
Context.OnError(_endInheritsLocation.Value,
Resources.FormatMvcRazorCodeParser_CannotHaveModelAndInheritsKeyword(ModelKeyword));
}
}
@ -48,12 +49,13 @@ namespace Microsoft.AspNet.Mvc.Razor
SourceLocation endModelLocation = CurrentLocation;
BaseTypeDirective(Resources.MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName(ModelKeyword),
BaseTypeDirective(Resources.FormatMvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName(ModelKeyword),
CreateModelCodeGenerator);
if (_modelStatementFound)
{
Context.OnError(endModelLocation, Resources.MvcRazorCodeParser_OnlyOneModelStatementIsAllowed(ModelKeyword));
Context.OnError(endModelLocation,
Resources.FormatMvcRazorCodeParser_OnlyOneModelStatementIsAllowed(ModelKeyword));
}
_modelStatementFound = true;

View File

@ -1,6 +1,4 @@
// <auto-generated />
namespace Microsoft.AspNet.Mvc.Razor.Host
{
using System.Globalization;
@ -15,7 +13,15 @@ namespace Microsoft.AspNet.Mvc.Razor.Host
/// <summary>
/// The 'inherits' keyword is not allowed when a '{0}' keyword is used.
/// </summary>
internal static string MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword(object p0)
internal static string MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword
{
get { return GetString("MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword"); }
}
/// <summary>
/// The 'inherits' keyword is not allowed when a '{0}' keyword is used.
/// </summary>
internal static string FormatMvcRazorCodeParser_CannotHaveModelAndInheritsKeyword(object p0)
{
return string.Format(CultureInfo.CurrentCulture, GetString("MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword"), p0);
}
@ -23,7 +29,15 @@ namespace Microsoft.AspNet.Mvc.Razor.Host
/// <summary>
/// The '{0}' keyword must be followed by a type name on the same line.
/// </summary>
internal static string MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName(object p0)
internal static string MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName
{
get { return GetString("MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName"); }
}
/// <summary>
/// The '{0}' keyword must be followed by a type name on the same line.
/// </summary>
internal static string FormatMvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName(object p0)
{
return string.Format(CultureInfo.CurrentCulture, GetString("MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName"), p0);
}
@ -31,15 +45,33 @@ namespace Microsoft.AspNet.Mvc.Razor.Host
/// <summary>
/// Only one '{0}' statement is allowed in a file.
/// </summary>
internal static string MvcRazorCodeParser_OnlyOneModelStatementIsAllowed(object p0)
internal static string MvcRazorCodeParser_OnlyOneModelStatementIsAllowed
{
get { return GetString("MvcRazorCodeParser_OnlyOneModelStatementIsAllowed"); }
}
/// <summary>
/// Only one '{0}' statement is allowed in a file.
/// </summary>
internal static string FormatMvcRazorCodeParser_OnlyOneModelStatementIsAllowed(object p0)
{
return string.Format(CultureInfo.CurrentCulture, GetString("MvcRazorCodeParser_OnlyOneModelStatementIsAllowed"), p0);
}
private static string GetString(string name)
private static string GetString(string name, params string[] formatterNames)
{
string value = _resourceManager.GetString(name);
var value = _resourceManager.GetString(name);
System.Diagnostics.Debug.Assert(value != null);
if (formatterNames != null)
{
for (var i = 0; i < formatterNames.Length; i++)
{
value = value.Replace("{" + formatterNames[i] + "}", "{" + i + "}");
}
}
return value;
}
}

View File

@ -0,0 +1,46 @@
// <auto-generated />
namespace Microsoft.AspNet.Mvc.Razor
{
using System.Globalization;
using System.Reflection;
using System.Resources;
internal static class Resources
{
private static readonly ResourceManager _resourceManager
= new ResourceManager("Microsoft.AspNet.Mvc.Razor.Resources", typeof(Resources).GetTypeInfo().Assembly);
/// <summary>
/// Value cannot be null or empty.
/// </summary>
internal static string ArgumentCannotBeNullOrEmpty
{
get { return GetString("ArgumentCannotBeNullOrEmpty"); }
}
/// <summary>
/// Value cannot be null or empty.
/// </summary>
internal static string FormatArgumentCannotBeNullOrEmpty()
{
return GetString("ArgumentCannotBeNullOrEmpty");
}
private static string GetString(string name, params string[] formatterNames)
{
var value = _resourceManager.GetString(name);
System.Diagnostics.Debug.Assert(value != null);
if (formatterNames != null)
{
for (var i = 0; i < formatterNames.Length; i++)
{
value = value.Replace("{" + formatterNames[i] + "}", "{" + i + "}");
}
}
return value;
}
}
}

View File

@ -1,83 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.34003
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Microsoft.AspNet.Mvc.Razor
{
using System;
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources
{
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources()
{
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager
{
get
{
if (object.ReferenceEquals(resourceMan, null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Microsoft.AspNet.Mvc.Razor.Resources", System.Reflection.IntrospectionExtensions.GetTypeInfo(typeof(Resources)).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture
{
get
{
return resourceCulture;
}
set
{
resourceCulture = value;
}
}
/// <summary>
/// Looks up a localized string similar to Value cannot be null or empty..
/// </summary>
internal static string ArgumentCannotBeNullOrEmpty
{
get
{
return ResourceManager.GetString("ArgumentCannotBeNullOrEmpty", resourceCulture);
}
}
}
}