Class: MTProto::TL::ResolveUsername
- Inherits:
-
Object
- Object
- MTProto::TL::ResolveUsername
- Includes:
- Binary
- Defined in:
- lib/mtproto/tl/objects/resolve_username.rb
Constant Summary collapse
- CONSTRUCTOR =
0x725afbbc
Instance Method Summary collapse
-
#initialize(username:) ⇒ ResolveUsername
constructor
A new instance of ResolveUsername.
- #serialize ⇒ Object
Methods included from Binary
#b_u32, #b_u64, #u32_b, #u64_b
Constructor Details
#initialize(username:) ⇒ ResolveUsername
Returns a new instance of ResolveUsername.
10 11 12 |
# File 'lib/mtproto/tl/objects/resolve_username.rb', line 10 def initialize(username:) @username = username end |
Instance Method Details
#serialize ⇒ Object
14 15 16 17 18 19 |
# File 'lib/mtproto/tl/objects/resolve_username.rb', line 14 def serialize result = u32_b(CONSTRUCTOR) result += u32_b(0) # flags result += serialize_tl_string(@username) result end |