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

namespace MyTelegram.Schema.Messages;

///<summary>
/// Found stickersets
/// See <a href="https://corefork.telegram.org/constructor/messages.foundStickerSets" />
///</summary>
[TlObject(0x8af09dd2)]
public sealed class TFoundStickerSets : IFoundStickerSets
{
    public uint ConstructorId => 0x8af09dd2;
    ///<summary>
    /// <a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a>
    ///</summary>
    public long Hash { get; set; }

    ///<summary>
    /// Found stickersets
    ///</summary>
    public TVector<MyTelegram.Schema.IStickerSetCovered> Sets { get; set; }

    public void ComputeFlag()
    {

    }

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

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Hash = buffer.ReadInt64();
        Sets = buffer.Read<TVector<MyTelegram.Schema.IStickerSetCovered>>();
    }
}