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

namespace MyTelegram.Schema.Auth;

///<summary>
/// The code was sent through the telegram app
/// See <a href="https://corefork.telegram.org/constructor/auth.sentCodeTypeApp" />
///</summary>
[TlObject(0x3dbb5986)]
public sealed class TSentCodeTypeApp : ISentCodeType
{
    public uint ConstructorId => 0x3dbb5986;
    ///<summary>
    /// Length of the code in bytes
    ///</summary>
    public int Length { get; set; }

    public void ComputeFlag()
    {

    }

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

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