| 6 |
| * Copyright Nikolai Kudashov, 2015-2018. |
| 7 | */ |
| 8 |
| 9 | #ifndef APISCHEME_H |
| 10 | #define APISCHEME_H |
| 11 |
| 12 | #include <vector> |
| 13 | #include <memory> |
| 14 | #include "TLObject.h" |
| 15 |
| 16 | class ByteArray; |
| 17 | class NativeByteBuffer; |
| 18 |
| 19 | class Bool : public TLObject { |
| 20 |
| 21 | public: |
| 22 | static Bool *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 23 | }; |
| 24 |
| 25 | class TL_boolTrue : public Bool { |
| 26 |
| 27 | public: |
| 28 | static const uint32_t constructor = 0x997275b5; |
| 29 |
| 30 | void serializeToStream(NativeByteBuffer *stream); |
| 31 | }; |
| 32 |
| 33 | class TL_boolFalse : public Bool { |
| 34 |
| 35 | public: |
| 36 | static const uint32_t constructor = 0xbc799737; |
| 37 |
| 38 | void serializeToStream(NativeByteBuffer *stream); |
| 39 | }; |
| 40 |
| 41 | class TL_dcOption : public TLObject { |
| 42 |
| 43 | public: |
| 44 | static const uint32_t constructor = 0x18b7a10d; |
| 45 |
| 46 | int32_t flags; |
| 47 | bool ipv6; |
| 48 | bool media_only; |
| 49 | bool tcpo_only; |
| 50 | bool cdn; |
| 51 | bool isStatic; |
| 52 | bool thisPortOnly; |
| 53 | bool force_try_ipv6; |
| 54 | int32_t id; |
| 55 | std::string ip_address; |
| 56 | int32_t port; |
| 57 | std::unique_ptr<ByteArray> secret; |
| 58 |
| 59 | static TL_dcOption *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 60 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 61 | void serializeToStream(NativeByteBuffer *stream); |
| 62 | }; |
| 63 |
| 64 | class TL_cdnPublicKey : public TLObject { |
| 65 |
| 66 | public: |
| 67 | static const uint32_t constructor = 0xc982eaba; |
| 68 |
| 69 | int32_t dc_id; |
| 70 | std::string public_key; |
| 71 |
| 72 | static TL_cdnPublicKey *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 73 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 74 | void serializeToStream(NativeByteBuffer *stream); |
| 75 | }; |
| 76 |
| 77 | class TL_cdnConfig : public TLObject { |
| 78 |
| 79 | public: |
| 80 | static const uint32_t constructor = 0x5725e40a; |
| 81 |
| 82 | std::vector<std::unique_ptr<TL_cdnPublicKey>> public_keys; |
| 83 |
| 84 | static TL_cdnConfig *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 85 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 86 | void serializeToStream(NativeByteBuffer *stream); |
| 87 | }; |
| 88 |
| 89 | class TL_help_getCdnConfig : public TLObject { |
| 90 |
| 91 | public: |
| 92 | static const uint32_t constructor = 0x52029342; |
| 93 |
| 94 | bool isNeedLayer(); |
| 95 | TLObject *deserializeResponse(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 96 | void serializeToStream(NativeByteBuffer *stream); |
| 97 | }; |
| 98 |
| 99 | class Reaction : public TLObject { |
| 100 |
| 101 | public: |
| 102 | static Reaction *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 103 | }; |
| 104 |
| 105 |
| 106 | class TL_config : public TLObject { |
| 107 |
| 108 | public: |
| 109 | static const uint32_t constructor = 0xcc1a241e; |
| 110 |
| 111 | int32_t flags; |
| 112 | int32_t date; |
| 113 | int32_t expires; |
| 114 | bool test_mode; |
| 115 | int32_t this_dc; |
| 116 | std::vector<std::unique_ptr<TL_dcOption>> dc_options; |
| 117 | std::string dc_txt_domain_name; |
| 118 | int32_t chat_size_max; |
| 119 | int32_t megagroup_size_max; |
| 120 | int32_t forwarded_count_max; |
| 121 | int32_t online_update_period_ms; |
| 122 | int32_t offline_blur_timeout_ms; |
| 123 | int32_t offline_idle_timeout_ms; |
| 124 | int32_t online_cloud_timeout_ms; |
| 125 | int32_t notify_cloud_delay_ms; |
| 126 | int32_t notify_default_delay_ms; |
| 127 | int32_t push_chat_period_ms; |
| 128 | int32_t push_chat_limit; |
| 129 | // int32_t saved_gifs_limit; |
| 130 | int32_t edit_time_limit; |
| 131 | int32_t revoke_time_limit; |
| 132 | int32_t revoke_pm_time_limit; |
| 133 | int32_t rating_e_decay; |
| 134 | int32_t stickers_recent_limit; |
| 135 | // int32_t stickers_faved_limit; |
| 136 | int32_t channels_read_media_period; |
| 137 | int32_t tmp_sessions; |
| 138 | // int32_t pinned_dialogs_count_max; |
| 139 | // int32_t pinned_infolder_count_max; |
| 140 | int32_t call_receive_timeout_ms; |
| 141 | int32_t call_ring_timeout_ms; |
| 142 | int32_t call_connect_timeout_ms; |
| 143 | int32_t call_packet_timeout_ms; |
| 144 | std::string me_url_prefix; |
| 145 | std::string autoupdate_url_prefix; |
| 146 | std::string gif_search_username; |
| 147 | std::string venue_search_username; |
| 148 | std::string img_search_username; |
| 149 | std::string static_maps_provider; |
| 150 | int32_t caption_length_max; |
| 151 | int32_t message_length_max; |
| 152 | int32_t webfile_dc_id; |
| 153 | std::string suggested_lang_code; |
| 154 | int32_t lang_pack_version; |
| 155 | int32_t base_lang_pack_version; |
| 156 | std::unique_ptr<Reaction> reactions_default; |
| 157 | std::string autologin_token; |
| 158 |
| 159 | static TL_config *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 160 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 161 | void serializeToStream(NativeByteBuffer *stream); |
| 162 | }; |
| 163 |
| 164 | class TL_help_getConfig : public TLObject { |
| 165 |
| 166 | public: |
| 167 | static const uint32_t constructor = 0xc4f9186b; |
| 168 |
| 169 | bool isNeedLayer(); |
| 170 | TLObject *deserializeResponse(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 171 | void serializeToStream(NativeByteBuffer *stream); |
| 172 | }; |
| 173 |
| 174 | class TL_account_registerDevice : public TLObject { |
| 175 |
| 176 | public: |
| 177 | static const uint32_t constructor = 0x637ea878; |
| 178 |
| 179 | int32_t token_type; |
| 180 | std::string token; |
| 181 |
| 182 | bool isNeedLayer(); |
| 183 | TLObject *deserializeResponse(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 184 | void serializeToStream(NativeByteBuffer *stream); |
| 185 | }; |
| 186 |
| 187 | class UserStatus : public TLObject { |
| 188 |
| 189 | public: |
| 190 | int32_t expires; |
| 191 |
| 192 | static UserStatus *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 193 | }; |
| 194 |
| 195 | class TL_userStatusOffline : public UserStatus { |
| 196 |
| 197 | public: |
| 198 | static const uint32_t constructor = 0x8c703f; |
| 199 |
| 200 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 201 | void serializeToStream(NativeByteBuffer *stream); |
| 202 | }; |
| 203 |
| 204 | class TL_userStatusLastWeek : public UserStatus { |
| 205 |
| 206 | public: |
| 207 | static const uint32_t constructor = 0x7bf09fc; |
| 208 |
| 209 | void serializeToStream(NativeByteBuffer *stream); |
| 210 | }; |
| 211 |
| 212 | class TL_userStatusEmpty : public UserStatus { |
| 213 |
| 214 | public: |
| 215 | static const uint32_t constructor = 0x9d05049; |
| 216 |
| 217 | void serializeToStream(NativeByteBuffer *stream); |
| 218 | }; |
| 219 |
| 220 | class TL_userStatusLastMonth : public UserStatus { |
| 221 |
| 222 | public: |
| 223 | static const uint32_t constructor = 0x77ebc742; |
| 224 |
| 225 | void serializeToStream(NativeByteBuffer *stream); |
| 226 | }; |
| 227 |
| 228 | class TL_userStatusOnline : public UserStatus { |
| 229 |
| 230 | public: |
| 231 | static const uint32_t constructor = 0xedb93949; |
| 232 |
| 233 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 234 | void serializeToStream(NativeByteBuffer *stream); |
| 235 | }; |
| 236 |
| 237 | class TL_userStatusRecently : public UserStatus { |
| 238 |
| 239 | public: |
| 240 | static const uint32_t constructor = 0xe26f42f1; |
| 241 |
| 242 | void serializeToStream(NativeByteBuffer *stream); |
| 243 | }; |
| 244 |
| 245 | class FileLocation : public TLObject { |
| 246 |
| 247 | public: |
| 248 | int64_t volume_id; |
| 249 | int32_t local_id; |
| 250 |
| 251 | static FileLocation *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 252 | }; |
| 253 |
| 254 | class TL_fileLocationToBeDeprecated : public FileLocation { |
| 255 |
| 256 | public: |
| 257 | static const uint32_t constructor = 0xbc7fc6cd; |
| 258 |
| 259 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 260 | void serializeToStream(NativeByteBuffer *stream); |
| 261 | }; |
| 262 |
| 263 | class UserProfilePhoto : public TLObject { |
| 264 |
| 265 | public: |
| 266 | int32_t flags; |
| 267 | bool has_video; |
| 268 | int64_t photo_id; |
| 269 | std::unique_ptr<ByteArray> stripped_thumb; |
| 270 | int32_t dc_id; |
| 271 |
| 272 | static UserProfilePhoto *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 273 | }; |
| 274 |
| 275 | class TL_userProfilePhotoEmpty : public UserProfilePhoto { |
| 276 |
| 277 | public: |
| 278 | static const uint32_t constructor = 0x4f11bae1; |
| 279 |
| 280 | void serializeToStream(NativeByteBuffer *stream); |
| 281 | }; |
| 282 |
| 283 | class TL_userProfilePhoto : public UserProfilePhoto { |
| 284 |
| 285 | public: |
| 286 | static const uint32_t constructor = 0x82d1f706; |
| 287 |
| 288 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 289 | void serializeToStream(NativeByteBuffer *stream); |
| 290 | }; |
| 291 |
| 292 | class TL_restrictionReason : public TLObject { |
| 293 |
| 294 | public: |
| 295 | static const uint32_t constructor = 0xd072acb4; |
| 296 |
| 297 | std::string platform; |
| 298 | std::string reason; |
| 299 | std::string text; |
| 300 |
| 301 | static TL_restrictionReason *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 302 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 303 | void serializeToStream(NativeByteBuffer *stream); |
| 304 | }; |
| 305 |
| 306 | class TL_username : public TLObject { |
| 307 |
| 308 | public: |
| 309 | static const uint32_t constructor = 0xb4073647; |
| 310 | int32_t flags; |
| 311 | bool editable; |
| 312 | bool active; |
| 313 | std::string username; |
| 314 |
| 315 | static TL_username *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 316 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 317 | void serializeToStream(NativeByteBuffer *stream); |
| 318 | }; |
| 319 |
| 320 | class User : public TLObject { |
| 321 |
| 322 | public: |
| 323 | int64_t id; |
| 324 | std::string first_name; |
| 325 | std::string last_name; |
| 326 | std::string username; |
| 327 | int64_t access_hash; |
| 328 | std::string phone; |
| 329 | std::unique_ptr<UserProfilePhoto> photo; |
| 330 | std::unique_ptr<UserStatus> status; |
| 331 | int32_t flags; |
| 332 | int32_t flags2; |
| 333 | int32_t bot_info_version; |
| 334 | std::vector<std::unique_ptr<TL_restrictionReason>> restriction_reason; |
| 335 | std::string bot_inline_placeholder; |
| 336 | std::string lang_code; |
| 337 | std::vector<std::unique_ptr<TL_username>> usernames; |
| 338 | int32_t stories_max_id; |
| 339 |
| 340 | static User *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 341 | }; |
| 342 |
| 343 | class TL_userEmpty : public User { |
| 344 |
| 345 | public: |
| 346 | static const uint32_t constructor = 0xd3bc4b7a; |
| 347 |
| 348 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 349 | void serializeToStream(NativeByteBuffer *stream); |
| 350 | }; |
| 351 |
| 352 | class TL_user : public User { |
| 353 |
| 354 | public: |
| 355 | static const uint32_t constructor = 0xabb5f120; |
| 356 |
| 357 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 358 | void serializeToStream(NativeByteBuffer *stream); |
| 359 | }; |
| 360 |
| 361 | class InputPeer : public TLObject { |
| 362 |
| 363 | public: |
| 364 | int64_t user_id; |
| 365 | int64_t chat_id; |
| 366 | int64_t channel_id; |
| 367 | int64_t access_hash; |
| 368 |
| 369 | static InputPeer *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 370 | }; |
| 371 |
| 372 | class TL_inputPeerSelf : public InputPeer { |
| 373 |
| 374 | public: |
| 375 | static const uint32_t constructor = 0x7da07ec9; |
| 376 |
| 377 | void serializeToStream(NativeByteBuffer *stream); |
| 378 | }; |
| 379 |
| 380 | class TL_inputPeerUser : public InputPeer { |
| 381 |
| 382 | public: |
| 383 | static const uint32_t constructor = 0xdde8a54c; |
| 384 |
| 385 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 386 | void serializeToStream(NativeByteBuffer *stream); |
| 387 | }; |
| 388 |
| 389 | class TL_inputPeerChat : public InputPeer { |
| 390 |
| 391 | public: |
| 392 | static const uint32_t constructor = 0x35a95cb9; |
| 393 |
| 394 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 395 | void serializeToStream(NativeByteBuffer *stream); |
| 396 | }; |
| 397 |
| 398 | class TL_inputPeerUserFromMessage : public InputPeer { |
| 399 |
| 400 | public: |
| 401 | static const uint32_t constructor = 0xa87b0a1c; |
| 402 |
| 403 | std::unique_ptr<InputPeer> peer; |
| 404 | int32_t msg_id; |
| 405 |
| 406 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 407 | void serializeToStream(NativeByteBuffer *stream); |
| 408 | }; |
| 409 |
| 410 | class TL_inputPeerChannelFromMessage : public InputPeer { |
| 411 |
| 412 | public: |
| 413 | static const uint32_t constructor = 0xbd2a0840; |
| 414 |
| 415 | std::unique_ptr<InputPeer> peer; |
| 416 | int32_t msg_id; |
| 417 |
| 418 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 419 | void serializeToStream(NativeByteBuffer *stream); |
| 420 | }; |
| 421 |
| 422 | class TL_inputPeerChannel : public InputPeer { |
| 423 |
| 424 | public: |
| 425 | static const uint32_t constructor = 0x27bcbbfc; |
| 426 |
| 427 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 428 | void serializeToStream(NativeByteBuffer *stream); |
| 429 | }; |
| 430 |
| 431 | class TL_inputPeerEmpty : public InputPeer { |
| 432 |
| 433 | public: |
| 434 | static const uint32_t constructor = 0x7f3b18ea; |
| 435 |
| 436 | void serializeToStream(NativeByteBuffer *stream); |
| 437 | }; |
| 438 |
| 439 | class InputUser : public TLObject { |
| 440 |
| 441 | public: |
| 442 | int64_t user_id; |
| 443 | int64_t access_hash; |
| 444 |
| 445 | static InputUser *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 446 | }; |
| 447 |
| 448 | class TL_inputUserSelf : public InputUser { |
| 449 |
| 450 | public: |
| 451 | static const uint32_t constructor = 0xf7c1b13f; |
| 452 |
| 453 | void serializeToStream(NativeByteBuffer *stream); |
| 454 | }; |
| 455 |
| 456 | class TL_inputUser : public InputUser { |
| 457 |
| 458 | public: |
| 459 | static const uint32_t constructor = 0xf21158c6; |
| 460 |
| 461 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 462 | void serializeToStream(NativeByteBuffer *stream); |
| 463 | }; |
| 464 |
| 465 | class TL_inputUserEmpty : public InputUser { |
| 466 |
| 467 | public: |
| 468 | static const uint32_t constructor = 0xb98886cf; |
| 469 |
| 470 | void serializeToStream(NativeByteBuffer *stream); |
| 471 | }; |
| 472 |
| 473 | class TL_inputUserFromMessage : public InputUser { |
| 474 |
| 475 | public: |
| 476 | static const uint32_t constructor = 0x1da448e2; |
| 477 |
| 478 | std::unique_ptr<InputPeer> peer; |
| 479 | int32_t msg_id; |
| 480 |
| 481 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 482 | void serializeToStream(NativeByteBuffer *stream); |
| 483 | }; |
| 484 |
| 485 | class MessageEntity : public TLObject { |
| 486 |
| 487 | public: |
| 488 | int32_t offset; |
| 489 | int32_t length; |
| 490 | std::string url; |
| 491 | std::string language; |
| 492 |
| 493 | static MessageEntity *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 494 | }; |
| 495 |
| 496 | class TL_messageEntityTextUrl : public MessageEntity { |
| 497 |
| 498 | public: |
| 499 | static const uint32_t constructor = 0x76a6d327; |
| 500 |
| 501 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 502 | void serializeToStream(NativeByteBuffer *stream); |
| 503 | }; |
| 504 |
| 505 | class TL_messageEntityBotCommand : public MessageEntity { |
| 506 |
| 507 | public: |
| 508 | static const uint32_t constructor = 0x6cef8ac7; |
| 509 |
| 510 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 511 | void serializeToStream(NativeByteBuffer *stream); |
| 512 | }; |
| 513 |
| 514 | class TL_messageEntityEmail : public MessageEntity { |
| 515 |
| 516 | public: |
| 517 | static const uint32_t constructor = 0x64e475c2; |
| 518 |
| 519 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 520 | void serializeToStream(NativeByteBuffer *stream); |
| 521 | }; |
| 522 |
| 523 | class TL_messageEntityPre : public MessageEntity { |
| 524 |
| 525 | public: |
| 526 | static const uint32_t constructor = 0x73924be0; |
| 527 |
| 528 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 529 | void serializeToStream(NativeByteBuffer *stream); |
| 530 | }; |
| 531 |
| 532 | class TL_messageEntityUnknown : public MessageEntity { |
| 533 | public: |
| 534 | static const uint32_t constructor = 0xbb92ba95; |
| 535 |
| 536 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 537 | void serializeToStream(NativeByteBuffer *stream); |
| 538 | }; |
| 539 |
| 540 | class TL_messageEntityUrl : public MessageEntity { |
| 541 |
| 542 | public: |
| 543 | static const uint32_t constructor = 0x6ed02538; |
| 544 |
| 545 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 546 | void serializeToStream(NativeByteBuffer *stream); |
| 547 | }; |
| 548 |
| 549 | class TL_messageEntityItalic : public MessageEntity { |
| 550 |
| 551 | public: |
| 552 | static const uint32_t constructor = 0x826f8b60; |
| 553 |
| 554 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 555 | void serializeToStream(NativeByteBuffer *stream); |
| 556 | }; |
| 557 |
| 558 | class TL_messageEntityMention : public MessageEntity { |
| 559 |
| 560 | public: |
| 561 | static const uint32_t constructor = 0xfa04579d; |
| 562 |
| 563 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 564 | void serializeToStream(NativeByteBuffer *stream); |
| 565 | }; |
| 566 |
| 567 | class TL_messageEntityMentionName : public MessageEntity { |
| 568 |
| 569 | public: |
| 570 | static const uint32_t constructor = 0xdc7b1140; |
| 571 |
| 572 | int64_t user_id; |
| 573 |
| 574 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 575 | void serializeToStream(NativeByteBuffer *stream); |
| 576 | }; |
| 577 |
| 578 | class TL_inputMessageEntityMentionName : public MessageEntity { |
| 579 |
| 580 | public: |
| 581 | static const uint32_t constructor = 0x208e68c9; |
| 582 |
| 583 | std::unique_ptr<InputUser> user_id; |
| 584 |
| 585 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 586 | void serializeToStream(NativeByteBuffer *stream); |
| 587 | }; |
| 588 |
| 589 | class TL_messageEntityCashtag : public MessageEntity { |
| 590 |
| 591 | public: |
| 592 | static const uint32_t constructor = 0x4c4e743f; |
| 593 |
| 594 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 595 | void serializeToStream(NativeByteBuffer *stream); |
| 596 | }; |
| 597 |
| 598 | class TL_messageEntityBold : public MessageEntity { |
| 599 |
| 600 | public: |
| 601 | static const uint32_t constructor = 0xbd610bc9; |
| 602 |
| 603 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 604 | void serializeToStream(NativeByteBuffer *stream); |
| 605 | }; |
| 606 |
| 607 | class TL_messageEntityHashtag : public MessageEntity { |
| 608 |
| 609 | public: |
| 610 | static const uint32_t constructor = 0x6f635b0d; |
| 611 |
| 612 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 613 | void serializeToStream(NativeByteBuffer *stream); |
| 614 | }; |
| 615 |
| 616 | class TL_messageEntityCode : public MessageEntity { |
| 617 |
| 618 | public: |
| 619 | static const uint32_t constructor = 0x28a20571; |
| 620 |
| 621 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 622 | void serializeToStream(NativeByteBuffer *stream); |
| 623 | }; |
| 624 |
| 625 | class TL_messageEntityStrike : public MessageEntity { |
| 626 |
| 627 | public: |
| 628 | static const uint32_t constructor = 0xbf0693d4; |
| 629 |
| 630 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 631 | void serializeToStream(NativeByteBuffer *stream); |
| 632 | }; |
| 633 |
| 634 | class TL_messageEntityBlockquote : public MessageEntity { |
| 635 |
| 636 | public: |
| 637 | static const uint32_t constructor = 0x20df5d0; |
| 638 |
| 639 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 640 | void serializeToStream(NativeByteBuffer *stream); |
| 641 | }; |
| 642 |
| 643 | class TL_messageEntityUnderline : public MessageEntity { |
| 644 |
| 645 | public: |
| 646 | static const uint32_t constructor = 0x9c4e7e8b; |
| 647 |
| 648 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 649 | void serializeToStream(NativeByteBuffer *stream); |
| 650 | }; |
| 651 |
| 652 | class TL_messageEntityPhone : public MessageEntity { |
| 653 |
| 654 | public: |
| 655 | static const uint32_t constructor = 0x9b69e34b; |
| 656 |
| 657 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 658 | void serializeToStream(NativeByteBuffer *stream); |
| 659 | }; |
| 660 |
| 661 | class TL_dataJSON : public TLObject { |
| 662 |
| 663 | public: |
| 664 | static const uint32_t constructor = 0x7d748d04; |
| 665 |
| 666 | std::string data; |
| 667 |
| 668 | static TL_dataJSON *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 669 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 670 | void serializeToStream(NativeByteBuffer *stream); |
| 671 | }; |
| 672 |
| 673 | class TL_help_termsOfService : public TLObject { |
| 674 |
| 675 | public: |
| 676 | static const uint32_t constructor = 0x780a0310; |
| 677 |
| 678 | int32_t flags; |
| 679 | bool popup; |
| 680 | std::unique_ptr<TL_dataJSON> id; |
| 681 | std::string text; |
| 682 | std::vector<std::unique_ptr<MessageEntity>> entities; |
| 683 | int32_t min_age_confirm; |
| 684 |
| 685 | static TL_help_termsOfService *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 686 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 687 | void serializeToStream(NativeByteBuffer *stream); |
| 688 | }; |
| 689 |
| 690 | class auth_Authorization : public TLObject { |
| 691 |
| 692 | public: |
| 693 | static auth_Authorization *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 694 | }; |
| 695 |
| 696 | class TL_auth_authorizationSignUpRequired : public auth_Authorization { |
| 697 |
| 698 | public: |
| 699 | static const uint32_t constructor = 0x44747e9a; |
| 700 |
| 701 | int32_t flags; |
| 702 | std::unique_ptr<TL_help_termsOfService> terms_of_service; |
| 703 |
| 704 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 705 | void serializeToStream(NativeByteBuffer *stream); |
| 706 | }; |
| 707 |
| 708 | class TL_auth_authorization : public auth_Authorization { |
| 709 |
| 710 | public: |
| 711 | static const uint32_t constructor = 0x2ea2c0d4; |
| 712 |
| 713 | int32_t flags; |
| 714 | int32_t tmp_sessions; |
| 715 | int32_t otherwise_relogin_days; |
| 716 | std::unique_ptr<ByteArray> future_auth_token; |
| 717 | std::unique_ptr<User> user; |
| 718 |
| 719 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 720 | void serializeToStream(NativeByteBuffer *stream); |
| 721 | }; |
| 722 |
| 723 | class TL_auth_exportedAuthorization : public TLObject { |
| 724 |
| 725 | public: |
| 726 | static const uint32_t constructor = 0xb434e2b8; |
| 727 |
| 728 | int64_t id; |
| 729 | std::unique_ptr<ByteArray> bytes; |
| 730 |
| 731 | static TL_auth_exportedAuthorization *TLdeserialize(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 732 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 733 | }; |
| 734 |
| 735 | class TL_auth_exportAuthorization : public TLObject { |
| 736 |
| 737 | public: |
| 738 | static const uint32_t constructor = 0xe5bfffcd; |
| 739 |
| 740 | int32_t dc_id; |
| 741 |
| 742 | bool isNeedLayer(); |
| 743 | TLObject *deserializeResponse(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 744 | void serializeToStream(NativeByteBuffer *stream); |
| 745 | }; |
| 746 |
| 747 | class TL_auth_importAuthorization : public TLObject { |
| 748 |
| 749 | public: |
| 750 | static const uint32_t constructor = 0xa57a7dad; |
| 751 |
| 752 | int64_t id; |
| 753 | std::unique_ptr<ByteArray> bytes; |
| 754 |
| 755 | bool isNeedLayer(); |
| 756 | TLObject *deserializeResponse(NativeByteBuffer *stream, uint32_t constructor, int32_t instanceNum, bool &error); |
| 757 | void serializeToStream(NativeByteBuffer *stream); |
| 758 | }; |
| 759 |
| 760 | class TL_updatesTooLong : public TLObject { |
| 761 |
| 762 | public: |
| 763 | static const uint32_t constructor = 0xe317af7e; |
| 764 |
| 765 | void serializeToStream(NativeByteBuffer *stream); |
| 766 | }; |
| 767 |
| 768 |
| 769 | class TL_reactionCustomEmoji : public Reaction { |
| 770 |
| 771 | public: |
| 772 | static const uint32_t constructor = 0x8935fc73; |
| 773 | int64_t document_id; |
| 774 |
| 775 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 776 | void serializeToStream(NativeByteBuffer *stream); |
| 777 | }; |
| 778 |
| 779 |
| 780 | class TL_reactionEmoji : public Reaction { |
| 781 |
| 782 | public: |
| 783 | static const uint32_t constructor = 0x1b2286b8; |
| 784 | std::string emoticon; |
| 785 |
| 786 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 787 | void serializeToStream(NativeByteBuffer *stream); |
| 788 | }; |
| 789 |
| 790 |
| 791 |
| 792 | class TL_reactionEmpty : public Reaction { |
| 793 |
| 794 | public: |
| 795 | static const uint32_t constructor = 0x79f5d419; |
| 796 |
| 797 | void readParams(NativeByteBuffer *stream, int32_t instanceNum, bool &error); |
| 798 | void serializeToStream(NativeByteBuffer *stream); |
| 799 | }; |
| 800 |
| 801 | #endif |
| 802 |