mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-17 06:23:03 +03:00
19 lines
468 B
C#
19 lines
468 B
C#
using System.Text;
|
|
using MediaBrowser.Model.TextEncoding;
|
|
|
|
namespace MediaBrowser.Server.Implementations.TextEncoding
|
|
{
|
|
public class TextEncoding : IEncoding
|
|
{
|
|
public byte[] GetASCIIBytes(string text)
|
|
{
|
|
return Encoding.ASCII.GetBytes(text);
|
|
}
|
|
|
|
public string GetASCIIString(byte[] bytes, int startIndex, int length)
|
|
{
|
|
return Encoding.ASCII.GetString(bytes, 0, bytes.Length);
|
|
}
|
|
}
|
|
}
|