Class: MTProto::TL::GetMessagesReactions

Inherits:
Object
  • Object
show all
Includes:
Binary
Defined in:
lib/mtproto/tl/objects/get_messages_reactions.rb

Constant Summary collapse

CONSTRUCTOR =
0x8bba90e6

Instance Method Summary collapse

Methods included from Binary

#b_u32, #b_u64, #u32_b, #u64_b

Constructor Details

#initialize(peer:, ids:) ⇒ GetMessagesReactions

Returns a new instance of GetMessagesReactions.



10
11
12
13
# File 'lib/mtproto/tl/objects/get_messages_reactions.rb', line 10

def initialize(peer:, ids:)
  @peer = peer
  @ids = ids
end

Instance Method Details

#serializeObject



15
16
17
18
19
20
21
# File 'lib/mtproto/tl/objects/get_messages_reactions.rb', line 15

def serialize
  result = u32_b(CONSTRUCTOR)
  result += serialize_input_peer
  result += u32_b(Constructors::VECTOR) + u32_b(@ids.length)
  @ids.each { |id| result += u32_b(id) }
  result
end