// <auto-generated/>
// ReSharper disable All

namespace MyTelegram.Schema.Account;

///<summary>
/// Media autodownload settings
/// See <a href="https://corefork.telegram.org/constructor/account.autoDownloadSettings" />
///</summary>
[TlObject(0x63cacf26)]
public sealed class TAutoDownloadSettings : IAutoDownloadSettings
{
    public uint ConstructorId => 0x63cacf26;
    ///<summary>
    /// Low data usage preset
    /// See <a href="https://corefork.telegram.org/type/AutoDownloadSettings" />
    ///</summary>
    public MyTelegram.Schema.IAutoDownloadSettings Low { get; set; }

    ///<summary>
    /// Medium data usage preset
    /// See <a href="https://corefork.telegram.org/type/AutoDownloadSettings" />
    ///</summary>
    public MyTelegram.Schema.IAutoDownloadSettings Medium { get; set; }

    ///<summary>
    /// High data usage preset
    /// See <a href="https://corefork.telegram.org/type/AutoDownloadSettings" />
    ///</summary>
    public MyTelegram.Schema.IAutoDownloadSettings High { get; set; }

    public void ComputeFlag()
    {

    }

    public void Serialize(IBufferWriter<byte> writer)
    {
        ComputeFlag();
        writer.Write(ConstructorId);
        writer.Write(Low);
        writer.Write(Medium);
        writer.Write(High);
    }

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Low = buffer.Read<MyTelegram.Schema.IAutoDownloadSettings>();
        Medium = buffer.Read<MyTelegram.Schema.IAutoDownloadSettings>();
        High = buffer.Read<MyTelegram.Schema.IAutoDownloadSettings>();
    }
}