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

namespace MyTelegram.Schema;

///<summary>
/// The linked chat was changed
/// See <a href="https://corefork.telegram.org/constructor/channelAdminLogEventActionChangeLinkedChat" />
///</summary>
[TlObject(0x50c7ac8)]
public sealed class TChannelAdminLogEventActionChangeLinkedChat : IChannelAdminLogEventAction
{
    public uint ConstructorId => 0x50c7ac8;
    ///<summary>
    /// Previous linked chat
    ///</summary>
    public long PrevValue { get; set; }

    ///<summary>
    /// New linked chat
    ///</summary>
    public long NewValue { get; set; }

    public void ComputeFlag()
    {

    }

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

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