// Copyright (c) .NET Foundation. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Text; namespace Microsoft.AspNet.Mvc { internal static class Encodings { /// /// Returns UTF8 Encoding without BOM and throws on invalid bytes. /// public static readonly Encoding UTF8EncodingWithoutBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false, throwOnInvalidBytes: true); /// /// Returns UTF16 Encoding which uses littleEndian byte order with BOM and throws on invalid bytes. /// public static readonly Encoding UTF16EncodingLittleEndian = new UnicodeEncoding(bigEndian: false, byteOrderMark: true, throwOnInvalidBytes: true); } }