mirror of
https://github.com/sochix/TLSharp.git
synced 2026-04-07 23:45:09 +00:00
Layer-57
This commit is contained in:
parent
0752c60082
commit
23e647e81c
81 changed files with 2631 additions and 213 deletions
|
|
@ -7,47 +7,70 @@ using System.Threading.Tasks;
|
|||
using TeleSharp.TL;
|
||||
namespace TeleSharp.TL
|
||||
{
|
||||
[TLObject(-1500747636)]
|
||||
[TLObject(-415938591)]
|
||||
public class TLUpdateBotCallbackQuery : TLAbsUpdate
|
||||
{
|
||||
public override int Constructor
|
||||
{
|
||||
get
|
||||
{
|
||||
return -1500747636;
|
||||
return -415938591;
|
||||
}
|
||||
}
|
||||
|
||||
public long query_id {get;set;}
|
||||
public int flags {get;set;}
|
||||
public long query_id {get;set;}
|
||||
public int user_id {get;set;}
|
||||
public TLAbsPeer peer {get;set;}
|
||||
public int msg_id {get;set;}
|
||||
public long chat_instance {get;set;}
|
||||
public byte[] data {get;set;}
|
||||
public string game_short_name {get;set;}
|
||||
|
||||
|
||||
public void ComputeFlags()
|
||||
{
|
||||
|
||||
flags = 0;
|
||||
flags = data != null ? (flags | 1) : (flags & ~1);
|
||||
flags = game_short_name != null ? (flags | 2) : (flags & ~2);
|
||||
|
||||
}
|
||||
|
||||
public override void DeserializeBody(BinaryReader br)
|
||||
{
|
||||
query_id = br.ReadInt64();
|
||||
flags = br.ReadInt32();
|
||||
query_id = br.ReadInt64();
|
||||
user_id = br.ReadInt32();
|
||||
peer = (TLAbsPeer)ObjectUtils.DeserializeObject(br);
|
||||
msg_id = br.ReadInt32();
|
||||
chat_instance = br.ReadInt64();
|
||||
if ((flags & 1) != 0)
|
||||
data = BytesUtil.Deserialize(br);
|
||||
else
|
||||
data = null;
|
||||
|
||||
if ((flags & 2) != 0)
|
||||
game_short_name = StringUtil.Deserialize(br);
|
||||
else
|
||||
game_short_name = null;
|
||||
|
||||
|
||||
}
|
||||
|
||||
public override void SerializeBody(BinaryWriter bw)
|
||||
{
|
||||
bw.Write(Constructor);
|
||||
bw.Write(query_id);
|
||||
ComputeFlags();
|
||||
bw.Write(flags);
|
||||
bw.Write(query_id);
|
||||
bw.Write(user_id);
|
||||
ObjectUtils.SerializeObject(peer,bw);
|
||||
bw.Write(msg_id);
|
||||
bw.Write(chat_instance);
|
||||
if ((flags & 1) != 0)
|
||||
BytesUtil.Serialize(data,bw);
|
||||
if ((flags & 2) != 0)
|
||||
StringUtil.Serialize(game_short_name,bw);
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue