Class: MTProto::TL::ChannelsGetParticipant
- Inherits:
-
Object
- Object
- MTProto::TL::ChannelsGetParticipant
- Includes:
- Binary
- Defined in:
- lib/mtproto/tl/objects/channels_get_participant.rb
Constant Summary collapse
- CONSTRUCTOR =
0xa0ab6cc6
Instance Method Summary collapse
-
#initialize(channel:, participant:) ⇒ ChannelsGetParticipant
constructor
A new instance of ChannelsGetParticipant.
- #serialize ⇒ Object
Methods included from Binary
#b_u32, #b_u64, #u32_b, #u64_b
Constructor Details
#initialize(channel:, participant:) ⇒ ChannelsGetParticipant
Returns a new instance of ChannelsGetParticipant.
10 11 12 13 |
# File 'lib/mtproto/tl/objects/channels_get_participant.rb', line 10 def initialize(channel:, participant:) @channel = channel @participant = participant end |
Instance Method Details
#serialize ⇒ Object
15 16 17 18 19 20 |
# File 'lib/mtproto/tl/objects/channels_get_participant.rb', line 15 def serialize result = u32_b(CONSTRUCTOR) result += u32_b(Constructors::INPUT_CHANNEL) + u64_b(@channel[:id]) + u64_b(@channel[:access_hash]) result += serialize_input_peer(@participant) result end |