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

namespace MyTelegram.Schema;

///<summary>
/// See <a href="https://corefork.telegram.org/constructor/pendingSuggestion" />
///</summary>
[TlObject(0xe7e82e12)]
public sealed class TPendingSuggestion : IPendingSuggestion
{
    public uint ConstructorId => 0xe7e82e12;
    public string Suggestion { get; set; }
    public MyTelegram.Schema.ITextWithEntities Title { get; set; }
    public MyTelegram.Schema.ITextWithEntities Description { get; set; }
    public string Url { get; set; }

    public void ComputeFlag()
    {

    }

    public void Serialize(IBufferWriter<byte> writer)
    {
        ComputeFlag();
        writer.Write(ConstructorId);
        writer.Write(Suggestion);
        writer.Write(Title);
        writer.Write(Description);
        writer.Write(Url);
    }

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Suggestion = buffer.ReadString();
        Title = buffer.Read<MyTelegram.Schema.ITextWithEntities>();
        Description = buffer.Read<MyTelegram.Schema.ITextWithEntities>();
        Url = buffer.ReadString();
    }
}