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

namespace MyTelegram.Schema;

///<summary>
/// Location of encrypted telegram <a href="https://corefork.telegram.org/passport">passport</a> file.
/// See <a href="https://corefork.telegram.org/constructor/inputSecureFileLocation" />
///</summary>
[TlObject(0xcbc7ee28)]
public sealed class TInputSecureFileLocation : IInputFileLocation
{
    public uint ConstructorId => 0xcbc7ee28;
    ///<summary>
    /// File ID, <strong>id</strong> parameter value from <a href="https://corefork.telegram.org/constructor/secureFile">secureFile</a>
    ///</summary>
    public long Id { get; set; }

    ///<summary>
    /// Checksum, <strong>access_hash</strong> parameter value from <a href="https://corefork.telegram.org/constructor/secureFile">secureFile</a>
    ///</summary>
    public long AccessHash { get; set; }

    public void ComputeFlag()
    {

    }

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

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Id = buffer.ReadInt64();
        AccessHash = buffer.ReadInt64();
    }
}