// namespace Microsoft.AspNetCore.Authentication.Cookies { using System.Globalization; using System.Reflection; using System.Resources; internal static class Resources { private static readonly ResourceManager _resourceManager = new ResourceManager("Microsoft.AspNetCore.Authentication.Cookies.Resources", typeof(Resources).GetTypeInfo().Assembly); /// /// The cookie key and options are larger than ChunksSize, leaving no room for data. /// internal static string Exception_CookieLimitTooSmall { get { return GetString("Exception_CookieLimitTooSmall"); } } /// /// The cookie key and options are larger than ChunksSize, leaving no room for data. /// internal static string FormatException_CookieLimitTooSmall() { return GetString("Exception_CookieLimitTooSmall"); } /// /// The chunked cookie is incomplete. Only {0} of the expected {1} chunks were found, totaling {2} characters. A client size limit may have been exceeded. /// internal static string Exception_ImcompleteChunkedCookie { get { return GetString("Exception_ImcompleteChunkedCookie"); } } /// /// The chunked cookie is incomplete. Only {0} of the expected {1} chunks were found, totaling {2} characters. A client size limit may have been exceeded. /// internal static string FormatException_ImcompleteChunkedCookie(object p0, object p1, object p2) { return string.Format(CultureInfo.CurrentCulture, GetString("Exception_ImcompleteChunkedCookie"), p0, p1, p2); } 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; } } }