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

namespace MyTelegram.Schema;

///<summary>
/// Time to live in days of the current account
/// See <a href="https://corefork.telegram.org/constructor/accountDaysTTL" />
///</summary>
[TlObject(0xb8d0afdf)]
public sealed class TAccountDaysTTL : IAccountDaysTTL
{
    public uint ConstructorId => 0xb8d0afdf;
    ///<summary>
    /// This account will self-destruct in the specified number of days
    ///</summary>
    public int Days { get; set; }

    public void ComputeFlag()
    {

    }

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

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Days = buffer.ReadInt32();
    }
}